I am using the code from http://www.dynamicdrive.com/dynamici...jaxcontent.htm so the user can click on a nav link on the left side div and it will load, via Javascript, an external HTML page in the right-side div. All works perfectly. But I find that the back/next links of the right-side page open up in the full window, obscuring the nav links at left.
How do I make the back/next links open only within that div, or at least on that half of the screen?
I'd like the same external html page content to be used for both iPhone and iPad screens. I have the detection code to switch between the two devices, so I'm hoping I don't need to open every page to make a change to the links! Or if I must include it in every page, I want the iPhone version to work, letting the Javascript degrade gracefully.
I'm not sure what you mean by the 'back/next' links on the right-hand side ... I can't see any links like that on the demo page, so if you're talking about something you've done on your own page then you'll need to give us a link.
Words of warning – before you get too carried away with Ajax for navigation, bear this in mind. It completely destroys the way hypertext navigation is supposed to work. Go to that demo page, click on an Ajax link, and then click the 'back' button. Do you go back to where you were before? No, because the browser doesn't recognise it as a change. Bookmark the page, or give a link to it, and you can only go to the original state of the page. Search engines can only find the home state, and may not even crawl the extra content. Right-click and open in new tab, and you just get an error message.
The method they have used is absolutely awful for site navigation, and I would very strongly advise against using it.
Any posts I write in Arial are on my mobile phone, so please excuse typos etc. Any posts I write in Verdana are on a PC, so feel free to berate me mercilessly for any mistakes
This will be used in the iPhone and iPad, and there is no bookmarking of pages.
The next/back buttons appear on the page that is called to populate the right div. It is one of my own pages, and has no Javascript. The back/next buttons are simple <a href=""> tags.
Bookmarks