Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

How do i explode this string '||25||34||73||94||116||128' i
need to have a array like this

array (
0 => '25',
1 => '34',
2 => '73',
3 => '94',
4 => '116',
5 => '128'
)

explode("||", $array); didnt work for me i get this array

array (
0 => '',
1 => '25',
2 => '34',
3 => '73',
4 => '94',
5 => '116',
6 => '128',
)

Answer Posted / nilsoft

<?php
$string = '||25||34||73||94||116||128';
$require_array =
explode("||",substr($string,2,strlen($string)-2));
print_r($require_array);
?>

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

hello all, I need some sample placement papers in lion bridge.. can anyone help me?

2164


What sized websites have you worked on in the past?

1075


What is the current stable version of php? What advance thing in php7?

1082


How to calculate the difference between two dates using php?

1126


how to detect a mobile device using php

1166


Which variable declarations within a class is invalid in php?

1042


Tell me what kind of things have you done on the social side?

1054


What is the current stable version of php?

1106


Write a program using while loop?

1104


Name and explain five of the PHP error constants?

1022


Explain me is it possible to destroy a cookie?

1015


What is difference between static and final in php?

1080


sort term descripttion form, report and uery

2252


if you run the app program all vendor open items are cleared but is it possible to reverse the again again open items please tell me the answer

1979


What does $_files means?

1151