0

hi

how i can let echo like in image

http://img52.imageshack.us/img52/5373/gggpr.jpg

first article with image and title

after come title only for other articles

this is my code

$querypub = "SELECT * FROM art_publish where 

category='$bnrow[1]' ORDER BY id DESC limit 3";
			$qrypub = @mysql_query($querypub,$connect) or die ("Wrong 
Query");
			while ($pub = mysql_fetch_array ($qrypub)) {
			echo "
			<tr>
			  <td>
			  			  <div class=\"news_title\"><a href=\"art.php?

show=art&id=$pub[id]\">$pub[title]</a></div>
              <div class=\"newssubtitle\">$pub[subtitle]</div>
			  <div class=\"newsdate\">$pub[sdate]</div>";
			  if ($pub[pq]==1) {
			  echo "<a href=\"art.php?go=art&id=$pub[id]\"><img 

src=\"/image/$pub[photo]\" alt=\"\" border=\"0\" width=\"100\" align=\"left\" vspace=\"5\" 

hspace=\"5\" style=\"border: 3px double #C0C0C0\"></a>

";
			  } else {
			  }
			  echo "
			  $pub[intro] <p style=\"height:1px;border-width: 1px 0 0 0;border-style: dashed;border-color: #CCCCCC;\">
			  <br />

		    </tr>";
			}
				echo"<br/>
				</td>
							  			  
			  </tr>
			</table>

		  </td>";

..sorry about my english :icon_wink:

2
Contributors
2
Replies
3
Views
7 Years
Discussion Span
Last Post by sajed
0
$querypub = "SELECT * FROM art_publish where 

category='$bnrow[1]' ORDER BY id DESC limit 3";
			$qrypub = @mysql_query($querypub,$connect) or die ("Wrong 
Query");$f = "1";
			while ($pub = mysql_fetch_array ($qrypub)) {if($f == "1"){$f++;echo "only image showwn";} else{echo "dont echo image";} 
			echo "
			<tr>
			  <td>
			  			  <div class=\"news_title\"><a href=\"art.php?

show=art&id=$pub[id]\">$pub[title]</a></div>
              <div class=\"newssubtitle\">$pub[subtitle]</div>
			  <div class=\"newsdate\">$pub[sdate]</div>";
			  if ($pub[pq]==1) {
			  echo "<a href=\"art.php?go=art&id=$pub[id]\"><img 

src=\"/image/$pub[photo]\" alt=\"\" border=\"0\" width=\"100\" align=\"left\" vspace=\"5\" 

hspace=\"5\" style=\"border: 3px double #C0C0C0\"></a>

";
			  } else {
			  }
			  echo "
			  $pub[intro] <p style=\"height:1px;border-width: 1px 0 0 0;border-style: dashed;border-color: #CCCCCC;\">
			  <br />

		    </tr>";
			}
				echo"<br/>
				</td>
							  			  
			  </tr>
			</table>

		  </td>";
This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.