Posted By


ishkur on 07/22/08

Tagged


Statistics


Viewed 586 times
Favorited by 1 user(s)

substring_between


/ Published in: PHP
Save to your folder(s)



Copy this code and paste it in your HTML
  1. function substring_between($haystack,$start,$end) {
  2. $start_position = strpos($haystack,$start)+strlen($start);
  3. $end_position = strpos($haystack,$end);
  4. return substr($haystack,$start_position,$end_position-$start_position);
  5. }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.