Loading and refreshing div every 2 seconds from a file that is passing variables..
I am developing a script to work along side my joomla website and i am wanting to develop a script that connects to my database and refresh's certain divs every 2 seconds without the user noticing this,
only issue is that joomla isnt wanting to work with me on this,
since when i do that i get nothing on my navagation where user information is displayed and displays the enter layout in the div right_contenta So can jquery does this or shud i use ajax to help me out to what i want to achieve?
How can i fix this and get my right_contenta div refreshing every 2 seconds with my joomla layout
in otherwords i want my ajax to load and refresh the information located at profile2.php?user=admin which has all user information coming fom database and refreshs every 2 second
how can i do this and achieve this
can anyone help me out here?
I haven't used joomla much so I can't help there much, but one thing I would suggest you think about, if you haven't already done so, is consider sending a sychronous and not an asychronous ajax request to your database since your interval is only 2 seconds. Or make sure your code checks that an ajax request is completed before sending off another one.
If a second ajax request is sent before the first one is completed you could run into problems.