Register | Login
Views: 19364387
Main | Memberlist | Active users | ACS | Commons | Calendar | Online users
Ranks | FAQ | Color Chart | Photo album | IRC Chat
11-02-05 12:59 PM
0 user currently in Programming. | 3 guests
Acmlm's Board - I2 Archive - Programming - php/mysql help needed | |
Add to favorites | "RSS" Feed | Next newer thread | Next older thread
User Post
spiroth10

Octorok
Level: 9

Posts: 9/21
EXP: 2302
For next: 860

Since: 04-09-04

Since last post: 43 days
Last activity: 36 days
Posted on 03-27-05 11:12 AM Link | Quote
Update: hmm... another browsing through the php.net manual revealed that all I needed was to add in the word and...
I'll post the code, because no on seemed to know what to do anyway (no replies):

new code([ instead of < again...):
$db="spiroth_fakedb";
$link = mysql_connect('localhost', 'fakename', 'fakepass');
if (! $link)
die("Couldn't connect to MySQL");
mysql_select_db($db , $link)
or die("Couldn't open $db: ".mysql_error());
$result = mysql_query( "SELECT gname FROM ginfo" )
or die("SELECT Error: ".mysql_error());
$link2 = mysql_query( "SELECT glink FROM ginfo" )
or dies("SELECT Error: ".mysql_error());
print "[table width=200 border=1][h3 align=left][div id=head2]Game Info: [/h3][/div][br]\n";
while ($get_info = mysql_fetch_row($result) and $get_link = mysql_fetch_row($link2)){
print "[tr]\n";
$num_rows = mysql_num_rows($result);
$num_rows2 = mysql_num_rows($link2);
foreach ($get_link as $field2);
foreach ($get_info as $field);
print "\t[td][font face=arial size=3/][li][a href=$field2]$field[/a][/li][/a][/font][/td]\n";
print "[/tr]\n";
}

all I did differently here (other than the and operator) was rearrange the code a beat to clean it up, add a URL to $field, and give it a cool bullet... hope this will help someone...


(edited by spiroth10 on 03-27-05 01:12 AM)
(edited by spiroth10 on 03-27-05 01:13 AM)
(edited by spiroth10 on 03-27-05 01:15 AM)
(edited by spiroth10 on 03-27-05 04:42 PM)
(edited by spiroth10 on 03-27-05 04:43 PM)
(edited by spiroth10 on 03-27-05 04:44 PM)
Add to favorites | "RSS" Feed | Next newer thread | Next older thread
Acmlm's Board - I2 Archive - Programming - php/mysql help needed | |


ABII


AcmlmBoard vl.ol (11-01-05)
© 2000-2005 Acmlm, Emuz, et al



Page rendered in 0.004 seconds.