By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
431,871 Members | 2,418 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 431,871 IT Pros & Developers. It's quick & easy.

Showing image stored on server...

P: 19
Hello again all,

I am trying to show team images instead of team names in a standings page that i have created. Images are stored on the server but i am unable to come up with the code that prints the image of the team. Here is my code.


Expand|Select|Wrap|Line Numbers
  1.  <?php
  2.  
  3.  
  4. function ConferenceStandings ($conference)
  5. {
  6.  
  7.   include 'connect.php';
  8.  
  9.   $teamid = $_REQUEST["id"];
  10.  
  11.   // Connects to your Database
  12.  
  13.   $sql = "select *from season12 join teams WHERE season12 . team =teams . teamnameseason AND teams . conference ='$conference' ORDER BY `season12` . `P` DESC";
  14.   $data = mysql_query($sql) or die(mysql_error());
  15.   Print "<table width = 300>";
  16.   Print "<th bgcolor=#C10000>&nbsp;&nbsp;&nbsp;#&nbsp;&nbsp;&nbsp;</th>";
  17.   Print "<th bgcolor=#C10000>&nbsp;&nbsp;&nbsp;&nbsp;Team&nbsp;&nbsp;&nbsp;&nbsp;</th>";
  18.   Print "<th bgcolor=#C10000>&nbsp;&nbsp;&nbsp;&nbsp;GP&nbsp;&nbsp;&nbsp;&nbsp;</th>";
  19.   Print "<th bgcolor=#C10000>&nbsp;&nbsp;&nbsp;&nbsp;Pts&nbsp;&nbsp;&nbsp;&nbsp;</th>";
  20.  
  21.   $count++;
  22.   while($info = mysql_fetch_array( $data ))
  23.   {
  24.     $wcount=$wcount+1;
  25.     $teamnameseason = $info['teamnameseason'];
  26.     Print "<tr>";
  27.     if ($wcount == 9)
  28.     {
  29.       Print "<td>"?>
  30. <hr align="center" width="100%" size="1" color="#C10000" />
  31. <?php "</td> ";
  32.       Print "<td>"?>
  33. <hr align="center" width="100%" size="1" color="#C10000" />
  34. <?php "</td> ";
  35.       Print "<td>"?>
  36. <hr align="center" width="100%" size="1" color="#C10000" />
  37. <?php "</td> ";
  38.       Print "<td>"?>
  39. <hr align="center" width="100%" size="1" color="#C10000" />
  40. <?php "</td> ";
  41.       Print "<tr>";
  42.     }
  43.  
  44.     Print "<td align = center>".$wcount. "</td> ";
  45.     Print "<td align = center>".$info['teamnameseason'] . "</td> ";
  46.     Print "<td align = center>".$info['GP'] . "</td> ";
  47.     Print "<td align = center>".$info['P'] . "</td> ";
  48.   }
  49.  
  50.   Print "</table>";
  51.   include 'closedb.php';
  52. }
  53.  
  54. print "<img src='images/logoest.gif' />";
  55. print "<br />";
  56. ConferenceStandings ("East");
  57.  
  58. print "<br><br><br><br />";
  59.  
  60. print "<img src='images/logowest.gif' />";
  61. ConferenceStandings ("West");
  62. ?> 

As you can see teamnameseason is what is printing but i am looking for the image of the team that i have stored the link in a BLOB on the db...

Anyone able to give some advice?

Thanks in advance...
Oct 27 '11 #1
Share this Question
Share on Google+
1 Reply


P: 19
Anyone able to help here?
Oct 29 '11 #2

Post your reply

Sign in to post your reply or Sign up for a free account.