如何在php中拆分字符串 [英] how to split the string in php

查看:64
本文介绍了如何在php中拆分字符串的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在php中拆分no

字符串是$ str =01022013​​;

i想得到字符串2的值和2的值和4的值。

输出1是$ a = 01;

输出2是$ b = 02;

输出3是$ c = 2013 ;

how to split the no in php
the string is $str="01022013";
i want to get the string 2 value and 2 value and 4 value.
the output 1st is $a=01;
the output 2nd is $b=02;
the output 3rd is $c=2013;

推荐答案

str =01022013​​;

i想得到字符串2的值和2的值和4的值。

输出1st是
str="01022013";
i want to get the string 2 value and 2 value and 4 value.
the output 1st is


a = 01;

输出2nd是
a=01;
the output 2nd is


b = 02;

输出3是
b=02;
the output 3rd is


这篇关于如何在php中拆分字符串的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆