Fix screenshot link text, it wasn't fixed correctly with the last change

This commit is contained in:
Chris Morgan
2005-06-23 00:30:20 +00:00
committed by WineHQ
parent bcfd89e6f6
commit ebade0ce2d

View File

@@ -329,15 +329,18 @@ function get_screenshot_img($iAppId = null, $iVersionId = null)
} }
$sImg = html_frame_start("",'128','',2); $sImg = html_frame_start("",'128','',2);
/* we have screenshots */
if(mysql_num_rows($hResult)) if(mysql_num_rows($hResult))
{ {
/* if we are displaying a screenshot for a particular version, display text to indicate that */
/* the user may click to submit a screenshot */
if($iVersionId) if($iVersionId)
$sImg .= "<a href='screenshots.php?appId=$iAppId&amp;versionId=$iVersionId'>$sImgFile<br /><center>Submit&nbsp;Screenshot</center></a>"; $sImg .= "<a href='screenshots.php?appId=$iAppId&amp;versionId=$iVersionId'>$sImgFile<br /><center>View/Submit&nbsp;Screenshot</center></a>";
else else
$sImg .= "<a href='screenshots.php?appId=$iAppId&amp;versionId=$iVersionId'>$sImgFile</a>"; $sImg .= "<a href='screenshots.php?appId=$iAppId&amp;versionId=$iVersionId'>$sImgFile<br /><center>View&nbsp;Screenshot</center></a>";
} else // no link for adding app screenshot as screenshots are linked to versions } else if($iVersionId) /* we are asking for a specific app version but it has no screenshots */
{
$sImg .= "<a href='screenshots.php?appId=$iAppId&amp;versionId=$iVersionId'>$sImgFile<br /><center>Submit&nbsp;Screenshot</center></a>";
} else /* we have no screenshots and we aren't a specific version, we don't allow adding screenshots for an app */
{ {
$sImg .= $sImgFile; $sImg .= $sImgFile;
} }