Answer Posted / jhon
Implode and Explode are function sthat are opposite in working
Explode converts a string into array where as implode
coverts an array in string
explode example
<?php
$str = "test explode in php";
print_r (explode(" ",$str));
?>
output will be:
Array
(
[0] => test
[1] => explode
[2] => in
[3] => php
)
implode example
<?php
$arr = array('hi','hello');
echo implode(" ",$arr);
?>
output will be:
hi hello
Is This Answer Correct ? | 6 Yes | 1 No |
Post New Answer View All Answers
How we get ip address of client, previous reference page etc?
How to check your php installation?
What is the difference between single quoted string and double quoted string?
Tell me what is the difference between ereg_replace() and eregi_replace()?
What is in a cookie?
How do you measure variables?
Why does sql injection happen?
what the new feature add in php 7.2?
Is learning php easy?
Does php need to be installed?
Tell me how can we check the value of a given variable is alphanumeric?
What is difference between count or sizeof function in php?
How do I escape data before storing it in the database?
Tell me what sized websites have you worked on in the past?
What is cms php?