Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

PHP Forum


You are currently viewing our PHP Forum as a guest. Please register to participate.
Login



Freelance Jobs

Reply
Old 03-15-2005, 07:50 PM ok, another question
mikeroq's Avatar
Skilled Talker

Posts: 92
Name: Mike Roq
Location: Lakewood, CO
Trades: 1
ok im trying to ouput the data so its like
bgcolor = red
bgcolor = green

but if it is a odd number is just outputs the last twice
code:
Code:
$showlist="SELECT * from alumni_list where year='$year' and validated='1' order by name ASC";
$showlist2=mysql_query($showlist) or die(mysql_error());
while($showlist3=mysql_fetch_array($showlist2))
{ 
echo "
<table border=0 width=90%>
<tr>
<td width=50% bgcolor=#FF0000>Name: $showlist3[name]</td>
<td width=50% align=right bgcolor=#FF0000>Email: <A href='mailto:$showlist3[email]'>$showlist3[email]</a></td>
</tr>
<tr>
<td colspan=2 bgcolor=#e5e5e5>Message: $showlist3[message]</td>
</tr>
</table><p>";

echo "
<table border=0 width=90%>
<tr>
<td width=50% bgcolor=#880000>Name: $showlist3[name]</td>
<td width=50% align=right bgcolor=#FF0000>Email: <A href='mailto:$showlist3[email]'>$showlist3[email]</a></td>
</tr>
<tr>
<td colspan=2 bgcolor=#e5e5e5>Message: $showlist3[message]</td>
</tr>
</table><p>";
}
thanks
__________________
CodingHub.com
mikeroquemore.com
mikeroq is offline
Reply With Quote
View Public Profile Visit mikeroq's homepage!
 
 
Register now for full access!
Old 03-16-2005, 06:04 AM Alternate row colours
Phobz's Avatar
Novice Talker

Posts: 8
Trades: 0
Hi

This code might help you on this website

http://codewalkers.com/tutorials/6/2.html



Hope this helps

Regards
Paul
Phobz is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to ok, another question
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.93885 seconds with 12 queries