Rainrays Profiles
   Pregnancy & Care | Submit Your Free Ads | Tours & Travel India

Home rainrays profile world Contact Us Online Free Marketing Aadhaar Card Online Free Marketing Pregnancy & Care Online Free Marketing Tour n Travel Free Ads with rainrays Festivals  Tourist Attraction India Pincode India  Tourist Attraction India Tourist Attraction India Jobs Recipes Jobs Select Babies Name

Custom Search
More Topics...
  Pregnancy tips and care  Pregnancy tips and care
 YouTube Videos YouTube Videos
  Hospitals & clinics in India Hospitals & clinics in India
  Hospitals & clinics in India World Travel Tips
 Kitchen Dictionary Kitchen Dictionary
 Recipes Recipes
 Personality Personality
 Institute/Colleges Institute/Colleges
 Indian Festivals Indian Festivals
 University University
 Restaurant Restaurant
 Districts List in India Districts List in India
 Districts Profile of India Districts Profile of India
 Hotels Hotels
 Love dating and Romance Love dating and Romance
 Baby name list Baby name list
 Jobs by location Jobs by location
 Jobs by Keyword Jobs by Keyword
 Jobs by Function Jobs by Function
 Jobs Part Time Jobs Part Time
 Shayari Shayari

Best Indian Tours
 Week End Tours  Week End Tours
 Wildlife tours Wildlife tours
 Honeymoon  Honeymoon Tours
 Religious Tours Religious Tours
 Religious Tours International Tours
 Religious Tours Indian Tours for Overseas

explode() Split a string into Array

  Topic » Language » PHP » String
Post By : Rainrays At 0000-00-00 00:00:00

 explode() Split a string into Array

array explode ( [string $delimiter] , [string $string] , [int $limit]  )
$strng = 'a|bb|ccc|dddd';
print_r(explode('|', $strng));
echo "
print_r(explode('|', $strng, 1));
echo "
print_r(explode('|', $strng, 2));
echo "
print_r(explode('|', $strng, 3));
echo "
// negative limit (since PHP 5.1)
print_r(explode('|', $strng, -1));
Array ( [0] => a [1] => bb [2] => ccc [3] => dddd ) 
Array ( [0] => a|bb|ccc|dddd ) 
Array ( [0] => a [1] => bb|ccc|dddd ) 
Array ( [0] => a [1] => bb [2] => ccc|dddd ) 
Array ( [0] => a [1] => bb [2] => ccc )

substr_replace(): Replaces text within a portion of a string

Replacing Substrings string substr_replace ( string str, string replacmnt, int start [, int len] ) replace the entire instance (say, by changing the ever-so-clichéd "Hello World!" into the more "l33t" phrase "H3110 W0r1d!" and hence proving your "l33t" status), you could simply invoke the substr_replace() function as shown in the following example



Refer to Friend

  Rainryas information World

Share Info/View About Profile Or Any Comment

Your Name:*  
Other Topic
Grand Residency ,Bandra Mumbai
Framework jobs in India
Pincode Siwan District Bihar
Chennai :: A.M.S. College of Engineering
Create Your Profile in Category » String
Related Content..
 24  substr_replace(): Replaces text within a portion of a string
 28  crc32(),md5(),sha1()
 40  strpos() and stripos()
 39  strip_tags()
 32  htmlspecialchars():Convert special characters to HTML entities
 23  strstr():Finds the first occurrence of a string
 25  chr(): Return a specific character
 26  chunk_split():Split a string into smaller chunks
 30  htmlentities():Convert all applicable characters to HTML entities
 35  String Formating Functions
Special Tours Type India
 Week End Tours  Week End Tours
 Wildlife tours Wildlife tours
 Honeymoon  Honeymoon Tours
 Religious Tours Religious Tours
 International Tours International Tours
 Tours for Overseas Indian Tours for Overseas
More on rainrays.com
Top Links : Contact us | About us | Privacy & Policy | Terms & Condition | Extract Email | Submit URL to Search Engine
Jobs : Jobs by Location | Part Time Jobs | Jobs by Function | Jobs by Keyword | Jobs Out of india | Jobs Search Engine
Other Links
    Girl baby Names | Boy baby Names | Love dating and Romance | University | Restaurants in India | Hotels in India | Hospitals & clinic | Pregnancy & Care
    Coaching Institute | Educational Institution | School/Colleges by Loaction | Recipes | Std Code | PHP | Products | Links | PHP Interview Question

Copyright © 2010 --- All Rights Reserved