I’ve noticed that a great deal of WordPress bloggers are starting to make use of ajax and css to reduce the amount of space available on their pages as well as keeping the site simple, neat and minimalist.
I’ve recently added an ajax menu system in my sidebar. It has saved me a great deal of space as well as being very visually pleasing and easy to use. The process of setting this up was quite a mission and there’s a fair amount to do, but don’t worry, I’m going to do my best to explain the process from start to finish. This is what we are aiming to achieve:

Let’s get started:
Download, Unrar and Upload these files to the shown locations:
- jquery.rar | Theme Folder in wp-content
- menu-bullet.rar | Images folder in Theme Folder in wp-content
- sidebar-archive.rar | Theme Folder in wp-content
- visionary.rar | Theme Folder in wp-content
Next step is to add the css required for all of this:
- css.rar | amend to style.css file
Download the css.rar file and extract the .txt file located inside. Copy and paste all the code inside the .txt file into your style.css file. This can be done manually or by using the WordPress built-in Theme Editor under Presentation > Theme Editor.
You will now need to edit your header.php file to include the javascript files you uploaded. Simply click on ‘Presentation’, followed by ‘Theme Editor’ and then click on ‘Header’ located on the right side of your dashboard inside WordPress Admin of course. Once you are at this point, you need to insert the two lines of code below anywhere between <head> and </head>:
<script type=”text/javascript” src=”<?php echo bloginfo(stylesheet_directory) .’/jquery.js’; ?>”></script>
<script type=”text/javascript” src=”<?php echo bloginfo(stylesheet_directory) .’/visionary.js’; ?>”></script>
Once you have completed the above tasks, the last step is to initiate the sidebar menu system using one line of code, which must be pasted into your sidebar.php file. Once again, this can be done manually or via the WordPress Theme Editor. Here is the code:
<?php include (TEMPLATEPATH . ‘/sidebar-archive.php’); ?>
And that’s it.
Things to note:
- You will have to play around with your colours using the code you added to your style.css file
- You will have to double check widths to ensure the menu fits correctly on your blog
- With a little php/wordpress knowledge, you can adapt the sidebar-archive.php file to display anything you require.
Best of luck, please feel free to trackback to this article or leave a comment!





Don’t know if you can really call it ajax. Looks more like hidden divs that are set display:block when being clicked. Unless I am missing something.
But yes, it is good to see themese and add ons for wordpress catching up to what can be done with a little css and js magic.
Darryl, that’s a good point actually, it’s not ajax, that’s my bad!
JS and CSS are great tools for WordPress, ones which I’m sure we’re going to see tons of in the near future!
thank you :)
Sure thing :)
Thank you goçum benim ya :P
My pleasure Dizi :)
hi ya do you know any examples of these so called ajax menus that are scrolling down instead of going next to each other when they are opened.
Have you looked through my site for other Ajax articles?
The files can´t be downloaded anymore? :(
Oh darn it!
Are you fixing it? : P
If I can find a fixed link, I’ll definitely share it, promise!
Great! Have been looking for a loong time for this sollution! :)
I did some research and found these links, which I hope will help:
http://www.wppro.org/2008/01/19/anatomy-of-a-magazine-style-premium-wordpress-theme-part-2-domtab-tabber-more/
http://onlinetools.org/tools/domtabdata/
http://www.maverickwebcreations.com/2008/10/20/how-to-add-mootabs-to-your-wordpress-theme.html
http://justintadlock.com/archives/2007/11/07/how-to-create-tabs-using-jquery
Justin Tadlock is very well known, so I’d definitely look at his example first.
I hope that helps, sorry the other files are no longer available, not quite sure how that happened :(
Thx! You just saved me hours of googling.
And Justin Tadlock worked the best! Thx!
Fantastic!!!