Solved

Simple SEO: domain url in title/page

Posted on 2006-10-23
2
196 Views
Last Modified: 2010-04-27
anyone know how to automatically insert the domain name into the <title></title> or the body of the index page
0
Comment
Question by:MasterMitch
  • 2
2 Comments
 
LVL 33

Expert Comment

by:humeniuk
ID: 17792426
This can probably be done with a server-side scripting language like PHP or ASP.  But since this is an SEO question, I have to ask why you would want to?  It seems like a waste of the title element, which is an important SEO factor.
0
 
LVL 33

Accepted Solution

by:
humeniuk earned 250 total points
ID: 17792545
I double-checked the PHP syntax ...

$_SERVER['SERVER_NAME'] refers to the host that the page is running on.
$_SERVER['PHP_SELF'] represents the current page relative to the document root.

For the title, you would use ...

<title><?php echo $_SERVER['SERVER_NAME'],$_SERVER['PHP_SELF']; ?></title>

Here's a little example: www.humeniuk.com/ee/Q_22034907.php.

Can't help you with the ASP, though.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Before we dive into the marketing strategies involved with creating an effective homepage, it’s crucial that EE members know what a homepage is. In essence, a homepage is the introductory, or default page, of a website that typically highlights the …
Marketers need statistics and metrics like everybody else needs oxygen. In this article we explain how to enable marketing campaign statistics for Microsoft Exchange mail.
Viewers will get an overview of the benefits and risks of using Bitcoin to accept payments. What Bitcoin is: Legality: Risks: Benefits: Which businesses are best suited?: Other things you should know: How to get started:
Learn how to set-up PayPal payment integration in your Wufoo form. Allow your users to remit payment through PayPal upon completion of your online form. This is helpful for collecting membership payments, customer payments, donations, and more.

895 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now