I have two divs. One on the left and one on the right.
The one on the left will display links and whenever clicked, the content will appear on the right div.
I’ve been trying to do it with Iframe and javascript but I can’t seem to get it right. I’m still a beginner and I have been searching all over the internet sigh.
Any ideas?!
Thanks
You have a couple choices in order to achieve this.
The easiest way is to have all the content separated in divs with an id in the right div. Hide all but the first link. The links on the left would have these ids linking to the corresponding content. When a link is clicked hide all, to clear the right div, and show the id that was clicked.
The other choice is AJAX which isn’t as accessible as the first choice since if Javascript is off it won’t work. For the first choice if Javascript is off the content will just be displayed and upon clicking the links it will scroll to the content.