PHP - Código extraño

 
Vista:

Código extraño

Publicado por Raymond J Sutil Delgado (1 intervención) el 04/09/2006 01:10:32
Saludos Amigos, estoy trabajando en el Chat de PHP121, para personalizarlom ahora me encuentro en este código:

require_once("php121.php");

global $db_usertable, $dbf_uid, $dbf_uname, $dbf_upassword, $dbf_passwordtype, $dbf_uemail;
global $dbf_user_chatting, $dbf_smilies, $dbf_level, $dbf_showrequest, $php121_prefix;

$uname = $sess_username;
$to_user = makedbsafe($_GET['to']);
$now = time();
$uid = $sess_uid;

//get user ids I have blocked
$sql = "select b_block from " . $php121_prefix . "_blocks where b_user='$uid'";
$result = mysql_query($sql, $php121db);
$myblocks = "";
while ($row = mysql_fetch_row($result)) {
$myblocks[] = $row[0];
}
if ($myblocks == "") {
$myblocks[] = "";
}

//are we being blocked by the to_user?
$sql = "select b_id from " . $php121_prefix . "_blocks where b_block='$uid' and b_user='$to_user'";
$result = mysql_query($sql, $php121db);
$row = mysql_num_rows($result);
if ($row > 0) {
$blocked = 1;
}

if ($uid == $to_user) {
//numpty
echo $opentable;
echo "<b>" . _ERROR . _CANT_IM_SELF . "!</b><p><a href=\"javascript:window.close();\">" . _CLOSE . "</a>";
echo $closetable;
} else if (in_array($to_user, $myblocks)) {
//numpty
echo $opentable;
echo "<b>" . _ERROR . _USER_IS_BLOCKED . "<p><a href=\"javascript:window.close();\">" . _CLOSE . "</a>";
echo $closetable;
} else if ($blocked == 1) {
//user has blocked us
echo $opentable;
echo "<b>" . _ERROR . _YOU_ARE_BLOCKED . "<p><a href=\"javascript:window.close();\">" . _CLOSE . "</a>";
echo $closetable;
} else {
//find out if theres already a request sent, if not, send it
$sqla = "select r_id,r_time,r_result from " . $php121_prefix . "_requests where r_to='$to_user' and r_from='$uid' and r_time>$now-20";
$resulta = mysql_query($sqla, $php121db);
$numrows = mysql_num_rows($resulta);
$rowa = mysql_fetch_row($resulta);
$r_id = $rowa[0];
if ($numrows == 0) {
$sql = "insert into " . $php121_prefix . "_requests (r_id, roomid, r_to, r_from, r_time, r_result, r_update_time, r_type) values('','','$to_user','$uid','$now','0','$now','1')";
$result = mysql_query($sql, $php121db);
$sql = "select r_id from " . $php121_prefix . "_requests where r_to='$to_user' and r_from='$uid' and r_time='$now'";
$result = mysql_query($sql, $php121db);
$row = mysql_fetch_row($result);
$r_id = $row[0];
$sql = "update " . $php121_prefix . "_requests set roomid='$r_id' where r_id='$r_id'";
$result = mysql_query($sql, $php121db);
} else {
//request already sent, but we are still trying, so update the time of request update
$sql = "update " . $php121_prefix . "_requests set r_update_time='$now' where r_to='$to_user' and r_from='$uid' and r_id='$r_id'";
$result = mysql_query($sql, $php121db);
}
//see if we've been accepted and that the receipiant is already in room
$sql3 = "select roomid from " . $php121_prefix . "_rooms where roomid='$r_id'";
$result3 = mysql_query($sql3, $php121db);
$row3 = mysql_num_rows($result3);
if ($row3 > 0 && $rowa[2] == 1) {
//accepted
$url = "Location: php121chat.php?id=" . $r_id . "&type=1";
Header($url);
}

//see if we've been waiting too long or been rejected
if ($numrows != 0 && (time() - $rowa[1] > 60 ) && $rowa[2] == 0 ) {
//delete request and stop refreshing
$sql = "delete from " . $php121_prefix . "_requests where r_to='$to_user' and r_from='$uid'";
$result = mysql_query($sql, $php121db);
Header("Location: php121im-timeout.php");
} else if ($rowa[2] == 2 ) {
$sql = "delete from " . $php121_prefix . "_requests where r_to='$to_user' and r_from='$uid'";
$result = mysql_query($sql, $php121db);
Header("Location: php121im-na.php");
} else {
echo "<html><meta http-equiv=\"refresh\" content=\"3\">

<body>
<font style=\"FONT-FAMILY: Verdana,Helvetica; FONT-SIZE: 12px\">";
$sql = "select $dbf_uname from $db_usertable where $dbf_uid='$to_user'";
$result = mysql_query($sql, $php121db);
$row = mysql_fetch_row($result);
echo $opentable;

echo _REQUEST_SENT_TO . " " . $row[0] . " " . _WAITING . "<br><br>
<img border=0 scr=\"c2.jpg\">
<form action=\"php121cancelim.php\" method=\"POST\">
<input type=\"hidden\" name=\"to\" value=$to_user>
<input type=\"submit\" name=\"cancel\" style=\"FONT-FAMILY: Verdana,Helvetica; FONT-SIZE: 12px\" value=\"" . _CANCEL . "\"></form>";
echo $closetable;
echo "</font></body></html>";
}
}
?>
<head>
<body background="module_top_name.jpg">
<meta http-equiv=\"refresh\" content=\"3\">
<title>PHP121 - <?php echo _SEND_IM; ?></title>
</head>

El problema es que le quiero añadir una imagen y no la quiere mostrar, ya he realizado todo lo que está a mi alcance pero no sale, a ver si me pueden ayudar. La imágen que quiero poner está en esta línea <img border=0 scr=\"c2.jpg\">, el chat lo pueden descargar de http://www.php121.com

Gracias por adelantado
Valora esta pregunta
Me gusta: Está pregunta es útil y esta claraNo me gusta: Está pregunta no esta clara o no es útil
0
Responder