> join() in php ~ Online tutorial

join() in php

join() function in php
The join()returns the string from the elements of an array.The join() function is an alias of the implode function
Syntax
join(separator,array)
Example


<?php
$str='hello india';
// it is breaks the string into an array
$exp_str=explode("",$str);
print_r($exp_str);
// it returns the string from the elements of an array
echo join("",$exp_str);
?>
Output:

Array([0]=>hello
[1]=>india)

hello india

Please Give Us Your 1 Minute In Sharing This Post!
Please Give Us Your 1 Minute In Sharing This Post!
SOCIALIZE IT →
FOLLOW US →
SHARE IT →
Powered By: BloggerYard.Com

0 comments: