January 29, 200818 yr Ok, here goes I've been recoding this site to get around different issues with SEO and outdated standards. It's a general product site where there is a list in a <div> on one side of the page and another <DIV> next to it on which i've ID'd as "content" I then wanted to build each product on it's own little html page just to make it quick and easy - and intentionally faster as it's only changing the content on one area of the apge. I intiailly used the dreaded "<iframe>" and got no shortage of issues. so went looking about to externally load html into divs I then found innerHTML which of course works nice for the initial loading, but I cant figure out how to code it so when I click on the link on the left, it changed the content on the right. That's problem one. Problem 2 - As everyone knows (and I found out) Firefox does not support innerHTML - so now i'm back where I started. Suggestions? The page is posted at : dev.toraenergy.com/wind2.html Any help suggestions PLEASE? Thanks in advance.
January 29, 200818 yr Why don't you use SSI's to include common page elements like header, menu and footer? It's a lot lot easier! You could call the content in using AJAX but then you don't get any SEO benefits because essentially you only have one "page"
January 29, 200818 yr If your server has PHP installed, you could use PHP includes to add other HTML files inside your main HTML file. Simple and should always work, without depending on what the client has or doesn't have. And to make it vary automatically, you could make if-statements that select the correct includes to be used.
January 29, 200818 yr Author current code: <body bgcolor="#FFFFFF" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" onload="target.innerHTML=content.document.body.innerHTML"> <iframe id="content" src="iselect_Wind.html" style="display:none"></iframe> <div id="target" style="width: 26.75em; height: 21.81em; overflow: auto></div> href for link to new content <a href="xxxxxx.html" target="content">XXX,/a> ok we know this isn't working... Stand at end of runway... watch plane fly over head, watch wheels not touch head.... really lost here
Create an account or sign in to comment