Hi I am currently testing my CMS, and making changes so that way template designers have more options and can make ajax themes.
demo -
http://www.designvisa.com/index.php - ALL AJAX!
There are a few things I want to do, put cant figure out how.
I have a mod in mods/
That I want to show on the home page. (Tab1)
I want to do the following.
I need to send a request to another javascript
This is the code that gets the content.
Code:
function maincontent(tab)
{
document.getElementById("tab1").className = "";
document.getElementById("tab2").className = "";
document.getElementById("tab3").className = "";
document.getElementById("tab"+tab).className = "current";
callAjax('content.php?content= '+tab, 'content', '<center><img src="template/basic/images/ajax-loader.gif" title="Loading..."/></center>', 'Error');
}
This is the code for the mods javascript
Let me explain how it works.
The user in the admin area tells the system that mod YouTube is to show on the home page
also known as Tab1.
I need to send a ajax request to the following to let it know if it is tab1 or tab3
Code:
function user1(tab)
{
callAjaxMods('mods.php?page= '+tab, 'content', '', '');
}
I know it may not be the best javascript code to get Ajax working. But I need to be able to get information about what tab the user is on so that I can show or hide a div.
Thanks
Russell Harrower