-2

When someone loads this page, 'http://www.mydomainname.com/abcdefghijklmnopqrstuvwxyz'

I want to seperate the 'abcdef......wxyz' part from the link and display it in the page. How could i do it? Thanks in advance

PoomaniGP
  • 80
  • 1
  • 1
  • 11

2 Answers2

0

I would start with

$_SERVER['REQUEST_URI'];

You may have to do a bit of work on it though, like removing some stuff / But I would have to look at it to be sure.

ArtisticPhoenix
  • 21,464
  • 2
  • 24
  • 38
0

you can try something like

$strExplode = explode('/',$_SERVER['REQUEST_URI']);
$strWanted = $strExplode[sizeOf($strExplode) -1];
echo $strWanted // will print 'abcdef......wxyz'
Leeroy_Wonkledge
  • 341
  • 2
  • 11