jaic Posted November 12, 2007 Share Posted November 12, 2007 Hi All I have this site that uses inline frames for every content page that follows from the index.htm page I have a robots.txt file in place to stop all user-agents from crawling my site as if someone was to directly access a page other than the index.htm page, such as www.mydomain.com/page2.htm then they would only see the content on this page and not everything that goes around it (i.e. the main page with all the buttons, banner, adverts etc, etc. I know that using i-frames is not the best thing, but when the site involves a lot of updating on a day-to-day, week-to-week basis it is so much easier to have these inner pages to edit rather than editing and re-formating everything else. So, my question is... Is there a some code that can be added to each page so that if a user was to directly access my site to that specific page (/page2.htm) that they would end up on index.htm from outside of the site, such as from a link from another site or through google for example, if i was to open the web up fully to all user-agents by removing the robots.txt file? Peraps a script in the <head> section of each page would do it?? I have no idea where to start and it would be a great help if someone could show me the way! Thanks for your help in advance! Ja Quote Link to comment Share on other sites More sharing options...
Aureole Posted November 12, 2007 Share Posted November 12, 2007 You could probably do something like this with php but since this is posted here I dare not post any php, the moderators will have my head! Quote Link to comment Share on other sites More sharing options...
jaic Posted November 12, 2007 Author Share Posted November 12, 2007 anyone else got any ideas before i divulge into the world of php again, or maybe theres a .js i can use? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.