I have a Javascript function that creates a tabbed browsing section, for example, one tab is the most recently added news. How do I get the results from my sql query (recent news) in the Javascript. Here's how I would be able to do it in a perfect world... You should see what I am looking for...
var center_tabs = [
//first tab
[
'images/tabs/news.gif',
'images/tabs/news_selected.gif',
'
for($i=0; $i < $news_query; $i++)
{
$tag = $news_query[$i][2];
if($class != "tab_row1")
$class = "tab_row1";
else
$class = "tab_row2";
echo "
$tag
\n";
}
?>'],
//second tab
[
Thanks.
2007-03-26
10:05:17
·
4 answers
·
asked by
Duds331
5
in
Computers & Internet
➔ Programming & Design