Webmaster Forum

Go Back   Webmaster Forum > Web Development > Coding Forum

Coding Forum Problems with your code? Discuss coding issues, including JavaScript, PHP & MySQL, HTML & CSS, Flash & ActionScript, and more.


Reply
 
Thread Tools Display Modes
Share |
  #1  
Old 02-23-2018, 08:04 AM
102tube 102tube is offline
Junior Member
 
Join Date: 02-23-18
Posts: 11
iTrader: 0 / 0%
Red face Get the full URL in PHP

I use this code to get the full URL:
The problem is that I use some masks in my .htaccess, so what we see in the URL is not always the real path of the file.

What I need is to get the URL, what is written in the URL, nothing more and nothing less—the full URL.

I need to get how it appears in the Navigation Bar in the web browser, and not the real path of the file on the server.
 
Reply With Quote

Advertisement

Advertisement

  #2  
Old 03-23-2018, 06:51 AM
wmtips's Avatar
wmtips wmtips is offline
Junior Member
 
Join Date: 01-14-08
Posts: 9
iTrader: 0 / 0%
You've posted a blank code. But if you use PHP, you can try

PHP Code:
echo $_SERVER['REQUEST_URI']; 
 
Reply With Quote
  #3  
Old 04-01-2018, 09:14 PM
linux7802's Avatar
linux7802 linux7802 is offline
Contributing Member
 
Join Date: 11-26-09
Posts: 158
iTrader: 0 / 0%
The best example for your issue is

Quote:
<?php
echo $_SERVER['SERVER_NAME'];
?>
It will display, your domain name in output, for more detailed explanation kindly visit http://php.net/manual/en/reserved.variables.server.php
 
Reply With Quote
Go Back   Webmaster Forum > Web Development > Coding Forum

Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Change URL of already created blog post annb Blogging Forum 3 02-07-2018 12:16 AM
Shared: inventivehosting.co.uk (25% OFF Recurring) inventive Web Hosting 0 01-05-2018 04:12 PM
URL Canonicalization for url params SEO Forum 6 10-04-2017 06:19 AM
PHP /Magento developer who has a passion for developing complex solutions rjtexas17 Sell Web Services 0 07-12-2017 04:58 AM
Shared: inventivehosting.co.uk (25% OFF Recurring) inventive Web Hosting 0 03-21-2017 05:18 AM


V7N Network
Get exposure! V7N I Love Photography V7N SEO Blog V7N Directory


All times are GMT -7. The time now is 04:49 PM.
Powered by vBulletin
Copyright © 2000-2014 Jelsoft Enterprises Limited.
Copyright © 2003 - 2018 VIX-WomensForum LLC