Kevin M Posted January 3, 2007 Share Posted January 3, 2007 I was wondering, is it possible to use an Include in the <title> </title> area of the document? So if I changed the name or slogan of my site, I wouldn't have to go through and edit the title of each page, I could do it by editing the title.txt or whatever I called it file.Eg: <html><head><title><?php include("title.txt"); ?></title></head><body></body></html> And then have the title.txt file contain something like : W3Schools Online Web Tutorials (Not that title though)Thanks,Kevin Link to comment Share on other sites More sharing options...
real_illusions Posted January 3, 2007 Share Posted January 3, 2007 i tested it out, and it seemed to work for mehowever..google and search engines in general dont like the same title on several pages, they like different titles for different pages, it also tells the user (to some extent) whats on the page, especially if they click on a search result, as the title is the main text you see in a search engine result, and the bit you click on. Link to comment Share on other sites More sharing options...
Kevin M Posted January 3, 2007 Author Share Posted January 3, 2007 I know. I mean have something after the Include too, like what was on the page. I forgot to add that in my first post. Link to comment Share on other sites More sharing options...
justsomeguy Posted January 3, 2007 Share Posted January 3, 2007 Just for the record, you can put PHP anywhere in the document. You can echo each individual character out if you really want to. All that matters is that the browser sees HTML. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now