In split() function you can use regular expressions to split a string. and explode() splits a string with a string.
split() and explode() both are php function used to explode a string. split() almost was used in older php version and now availble version of php is higher than ten and its also support explode().
Ex. explode (" this", "this is a string"); will return “Is a string”
explode(","$abc);
here in the above function first argument is a sign to explode your string.and second if a array.
Ex. Split (" + ", "This+ is a string");
0 comments:
Post a Comment