Question

suppose we have strings like "adjkadahsdjashd##kjhkhkjhkjhs" . and I want to cut them to for example adjkadahsdjashd and kjhkhkjhkjhs

so I wrote this on my computer :

<?php
$s="508462170##dfsfgdfggf";
echo substr($s,strpos($s,"#")+2)."</br>";
echo substr($s,0,strpos($s,"#"));
?>

and the result is okay , but when I upload this to server , it returns me nothing .

server php version is 5.2.17

:(

No correct solution

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top