Answer Posted / puneet bhatt
explode function:-it breaks a string into array.
<?php
$str="hello world.it's a beautiful day.":
print_r(explode(" ",$str):
?>
ans-ARRAY
[0]=>hello
[1]=>world.
[2]=>it's
[3]=>a
[4]=>beautiful
[5]=>day.
implode:-returns a string from elements of an array.
<?php
$arr=array('hello','world!',beautiful,'day!');
echo implode(" ",$arr);
?>
ans-hello world! beautiful day!
| Is This Answer Correct ? | 36 Yes | 5 No |
Post New Answer View All Answers
What should we do to be able to export data into an excel file?
discuss the issue of software theft in ghana and how it has affected the economy
Is empty function c++?
Are sessions stateless?
How to Retrieve the Session ID of the Current Session?
Explain about require and include function?
What are the data types in php?
What language is similar to php?
Which php mvc framework is best?
What does $globals mean?
What does the php error 'parse error in php - unexpected t_variable at line x' means?
Can we use include ("xyz.php") two times in a php page "index.php"?
What is the difference between $argv and $argc? Give example?
What is $_ files in php?
What is escape data in php?