PHP extract just a specific number from a string -


how possible extract number after last = symbol in string this:

/neuroscan/analysis/admin/listo_aoi_list.php?mastertable=listo_pages&masterkey1=11 

the number 1,11,345,888888 etc, if possible int variable.

thanks

you can try this:

$url = $_server['request_uri']; $val = (explode("=",$url)); echo $val[1]; 

$val[1] getting second value after explode text after "="


Comments

Popular posts from this blog

java - UnknownEntityTypeException: Unable to locate persister (Hibernate 5.0) -

python - ValueError: empty vocabulary; perhaps the documents only contain stop words -

ubuntu - collect2: fatal error: ld terminated with signal 9 [Killed] -