Jump to content

Recommended Posts

I want to create a tabbed menu where a click on the tab loads new content, but doesn't make a new page to refresh. This can be found on Yahoo's frontpage.

 

How can I do this? Ajax?... >:(

 

I was hoping for a non-ajax solution. I read something about hidden divs. I hope you can help! Thanks.

 

I'm using php, css, and html if that helps... ???

Link to comment
https://forums.phpfreaks.com/topic/61313-tabbed-menu/
Share on other sites

you could use ajax or just plain js to do this.

 

JS would simply either change a z-index on elements or toggle divs. Ajax could be used to make everything faster by only loading up the content needed to display each tab...

 

From an accessibility point of view though you should code you scripts so that this would work without js (a new page request using url paramerters to dsiplay approrpiate content) and then simply apply ajax wfterwards to make it nicer for the user....

Link to comment
https://forums.phpfreaks.com/topic/61313-tabbed-menu/#findComment-305258
Share on other sites

http://nontroppo.org/test/tab1.html is just one of many ...

 

He said he didn't want the page to refresh.

 

Stu Nicholls has a few css-only tabbed pages that require no refresh.

 

http://www.cssplay.co.uk/menu/one_page

http://www.cssplay.co.uk/menus/page_menu.html

http://www.cssplay.co.uk/menus/page_menu2.html

 

Best to use something like what AndyB linked to above...it's not practical to create a whole website using css or js to avoid a page refresh. For starters it isn't going to help with SEO.

Link to comment
https://forums.phpfreaks.com/topic/61313-tabbed-menu/#findComment-305837
Share on other sites

Best to use something like what AndyB linked to above...it's not practical to create a whole website using css or js to avoid a page refresh. For starters it isn't going to help with SEO.

 

It will only be used for a small part in a webpage. Not for page navigation, but to increase user friendly search of content. - A neat feature, but nothing that will hurt SEO dramatically.

 

Thanks for the links though! Helps a lot!!

Link to comment
https://forums.phpfreaks.com/topic/61313-tabbed-menu/#findComment-305920
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.