September 5, 2020
Category : PHP
How to get current page url in PHP?
Whenever you need to get actual page url in Native PHP then you can do using this post. I give you the example that way you can get easily current URL in PHP. following PHP code through you can get:
Example:
$currentLink = "http://$_SERVER[HTTP_HOST]$_SERVER[REQUEST_URI]";
print_r($currentLink);

Hardik Savani
I'm a full-stack developer, entrepreneur and owner of Aatman Infotech. I live in India and I love to write tutorials and tips that can help to other artisan. I am a big fan of PHP, Laravel, Angular, Vue, Node, Javascript, JQuery, Codeigniter and Bootstrap from the early stage. I believe in Hardworking and Consistency.