Jump to content
MakeWebGames

thebobby

Members
  • Posts

    171
  • Joined

  • Last visited

thebobby's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. $checkjail = mysql_query("SELECT jail FROM `grpgusers` WHERE `jail` > '0'"); $nummsgs = mysql_num_rows($checkjail); $jail = "[".$nummsgs."]"; if (mysql_num_rows($checkjail) != 0){ $jail = "[".$nummsgs."]"; }This is in html section <?= ($jail >= 1) ? ' "<----error is here $jail"<li><a href="jail.php"> <!_-jail-_!></a></li> ' : "" ?>this will not work for some reasonthis does <?= ($user_class->jail == 2) ? '<li><a href="city1.php"> <!_-cityname-_!></a></li> ' : "" ?>but i want to pull from jail table which $jail does
  2. I am looking to redirect a domain to another domain can anybody help me
  3. looking for a new in game layout
  4. this make page refresh i want this gangmail to post message when a new message is posted with out refreshing page manually   ?> <script type="text/JavaScript"> function timedRefresh(timeoutPeriod) { setTimeout("location.reload(true);",timeoutPeriod) ; } </script> </head> <body onload="JavaScript<b></b>:timedRefresh(10000);" <tr> <td class="contentcontent"><table width='100%'> <tr> <td width='25%' align='center' class='highlight'><img src="<?= $user_ads->avatar ?>" width='100' height='100' border='0'></a> <?= $user_ads->formattedname ?> <?= ($row['date']) ?> </td> <td width='75%' colspan='4' class='highlight'><?= $bbcode->parse($row['message']) ?> </span></td> </tr> </table></td> </tr></body> <? } ?>
  5. <? error_reporting('0'); include 'header.php'; include 'bbcodes.php'; $newgmail = "0"; $result = mysql_query("UPDATE `grpgusers` SET `gmail` = '".$newgmail."' WHERE `id`='".$_SESSION['id']."'"); if($user_class->gangmail > 0){ $resulte = mysql_query("UPDATE `grpgusers` SET `gangmail`='0' WHERE `id`='".$user_class->id."'"); } if($user_class->gang < 1) { echo Message("You are not in a gang.");include 'footer.php'; die(); } if ($user_class->gang != 0) { $gang_class = New Gang($user_class->gang); } if (isset($_POST['submit'])) { $error = ($_POST['message'] == "") ? "You need to have a message!" : $error; if($error == ""){ $_POST['title'] = str_replace ('"', '"', $_POST['title']); $_POST['title'] = str_replace ("'", "'", $_POST['title']); $_POST['message'] = str_replace ('"', '"', $_POST['message']); $_POST['message'] = str_replace ("'", "'", $_POST['message']); $clock = date("d M H:i:s"); $time = time(); $result = mysql_query("INSERT INTO `gangmail` (`when`, `poster`,`date`, `title`, `message`, `gangid`)VALUES"." ('".$time."', '$user_class->id','$clock', '".strip_tags($_POST['title'])."', '".strip_tags($_POST['message'])."', '".$gang_class->id."')"); $resultbb = mysql_query("UPDATE `grpgusers` SET `gmail` = `gmail` + 1 WHERE `gang` = '{$gang_class->id}'"); } else { echo Message($error); } } ?> <script language="JavaScript" type="text/javascript"> <!-- function emoticon(myValue) { var myField = document.getElementById('msgtext'); //IE support if (document.selection) { var temp; myField.focus(); sel = document.selection.createRange(); temp = sel.text.lenght; sel.text = myValue; if (myValue.length == 0) { sel.moveStart('character', myValue.length); sel.moveEnd('character', myValue.length); } else { sel.moveStart('character', -myValue.length + temp); } sel.select(); } //MOZILLA/NETSCAPE support else if (myField.selectionStart || myField.selectionStart == '0') { var startPos = myField.selectionStart; var endPos = myField.selectionEnd; myField.value = myField.value.substring(0, startPos) + myValue + myField.value.substring(endPos, myField.value.length); myField.focus(); myField.selectionStart = startPos + myValue.length; myField.selectionEnd = startPos + myValue.length; } else { myField.value += myValue; myField.focus(); } } </script> <? ?> <tr> <td class="contentcontent"><form method='post'> <table width='100%'> <center> <? echo bbcode_popup(); ?> </center> <tr> <td width='25%'>Message:</td> <td width='75%'><textarea name='message' cols='70' rows='4' ></textarea></td> </tr> <tr> <td width='25%'>Submit:</td> <td width='75%'><center> <input type='submit' name='submit' class='button' value='Post'> </center></td> </tr> </table> </form></td> </tr> <? $date = mysql_query("SELECT * from `gangmail` WHERE `gangid` = '".$gang_class->id."' ORDER BY `when` DESC LIMIT 40"); $result = mysql_query("SELECT * from `gangmail` WHERE `gangid` = '".$gang_class->id."' ORDER BY `when` DESC LIMIT 40"); while ($row = mysql_fetch_array($result, MYSQL_ASSOC)) { $user_ads = New User($row['poster']); ?> <script type="text/JavaScript"> function timedRefresh(timeoutPeriod) { setTimeout("location.reload(true);",timeoutPeriod); } </script> </head> <body onload="JavaScript:timedRefresh(10000);" <tr> <td class="contentcontent"><table width='100%'> <tr> <td width='25%' align='center' class='highlight'><img src="<?= $user_ads->avatar ?>" width='100' height='100' border='0'></a><br> <?= $user_ads->formattedname ?> <br> <?= ($row['date']) ?> <br></td> <td width='75%' colspan='4' class='highlight'><?= $bbcode->parse($row['message']) ?> </span></td> </tr> </table></td> </tr></body> <? } ?> <? include 'footer.php'; ?>
  6. Apply wat line 88 mysql_query("INSERT INTO game_topic (gang, cat_id, forum_type, topic, date, date2, date2_year, origin, origin_userid) line 89 VALUES (\"$user_class->gang\", \"$cat_id\", \"$forum\", \"$topic\", \"$clock\", \"$clock2\", \"$clock2_year\", \"$user_class->username\", \"$user_class->id\") "); line 91 $maxtopic_id = mysql($db_name, "SELECT topicid FROM game_topic WHERE date2=\"$clock2\""); line 92 $mtid = mysql_result($maxtopic_id,$mtid); line 94 mysql_query("INSERT INTO game_posts (cat_id,topicid, message, date, date2, poster, poster_userid) line 95 VALUES ('$cat_id','$mtid', \"$message\", '$clock', '$clock2', \"$user_class->username\", \"$user_class->id\") "); $notice = "The topic has been posted.";
  7. Deprecated: mysql() [function.mysql]: This function is deprecated; use mysql_query() instead in /home/mafiacri/public_html/forum.php on line 91 Warning: mysql_query() expects parameter 2 to be resource, string given in /home/mafiacri/public_html/forumil.php on line 91 Warning: mysql_result() expects parameter 1 to be resource, null given in /home/mafiacri/public_html/forum.php on line 92 get these error when i change line 91 $maxtopic_id = mysql_query($db_name, "SELECT topicid FROM game_topic WHERE date2=\"$clock2\""); beforeline 91 $maxtopic_id = mysql($db_name, "SELECT topicid FROM game_topic WHERE date2=\"$clock2\"");
  8. line 88 mysql_query("INSERT INTO game_topic (gang, cat_id, forum_type, topic, date, date2, date2_year, origin, origin_userid) line 89 VALUES (\"$user_class->gang\", \"$cat_id\", \"$forum\", \"$topic\", \"$clock\", \"$clock2\", \"$clock2_year\", \"$user_class->username\", \"$user_class->id\") "); line 91 $maxtopic_id = mysql($db_name, "SELECT topicid FROM game_topic WHERE date2=\"$clock2\""); line 92 $mtid = mysql_result($maxtopic_id,$mtid); line 94 mysql_query("INSERT INTO game_posts (cat_id,topicid, message, date, date2, poster, poster_userid) line 95 VALUES ('$cat_id','$mtid', \"$message\", '$clock', '$clock2', \"$user_class->username\", \"$user_class->id\") "); $notice = "The topic has been posted.";
  9. line 91 $maxtopic_id = mysql_query ( 'SELECT `topicid` FROM `game_topic` WHERE (`date2` = "'.$clock2.'")' ); line92 //Should check there is rows first... line 93 $mtid = mysql_result ( $maxtopic_id ); line 94 echo $mtid;   Warning: mysql_result() expects at least 2 parameters, 1 given in /home/mafiacri/public_html/forum.php on line 93 every file with this code shows same error but all works. this started when host went to php 5.3
  10. Same error for both code it is php 5.3 this all worked before the upgrade to php 5.3. Lol hate upgrades lol its for mass mail and it works fine i am only one to see error but i just hate errors
  11. Warning: mysql_query() expects parameter 2 to be resource, string given in /home/mafiacri/public_html/massmail.php on line 44 line 45 error gone
  12. Warning: mysql_query() expects parameter 2 to be resource, string given in /home/mafiacri/public_html/massmail.php on line 44 Warning: mysql_result() expects parameter 1 to be resource, null given in /home/mafiacri/public_html/massmail.php on line 45
  13. line 44 $maxtopic_id = mysql($db_name, "SELECT topicid FROM game_topic WHERE date2=\"$clock2\""); line 45 $mtid = mysql_result($maxtopic_id,"mtid"); Deprecated: mysql() [function.mysql]: This function is deprecated; use mysql_query() instead in /home/mafiacri/public_html/massmail.php on line 44 Warning: mysql_result() expects parameter 2 to be long, string given in /home/mafiacri/public_html/massmail.php on line 45
  14. these suck i am lost lol
  15. function validateInput($info) { $original = $info; $info = eregi_replace("\'", "", $info); $info = preg_match("\"", "", $info); $info = ereg_replace("\/", "", $info); $info = ereg_replace("\=", "", $info); $info = stripslashes($info);
×
×
  • Create New...