Jump to content
MakeWebGames

rockwood

Members
  • Posts

    416
  • Joined

  • Last visited

  • Days Won

    10

Everything posted by rockwood

  1. i am not bad in all required skills but communication is my barrier
  2. 1. one more point need notice, are you facing this problem from starting or after add any modification (like after add any new mod in your current game ). 2. please check properly mysql database (i am talking about your cpanel phpmyadmin). it will be miner problem so please check by cool mind. if you need my more help then you can PM me or contact me on Skype .
  3. You Are Awesome Mate
  4. which engine you are using ?
  5. GL is grpg ???
  6. what is his game url ?
  7. Parse error: syntax error, unexpected end of file in /home/pokemo44/public_html/login.php on line 83
  8. i think MWG chat room is helpful in this case
  9. you are raising a valid point , and i am fully agree with you.
  10. what kind of service you have shared or VPS ? you are using which version of mccode ?? in v2   function disconnect() { if($this->connection_id) { mysql_close($this->connection_id); $this->connection_id=0; return 1; } else { return 0; } } hint for version 2:- (header.php) just in endpage() at very end line of code call disconnect() hint for mysql :- MAX USER_CONNECTIONS make sure it is By default 0 (unlimited) (in setting of pphpmyadmin) hope it may help you other wise your queries are not optimized
  11. http://www.vbulletin.org/forum/showthread.php?t=137238 //------------------------------------------------------------------------------------ Check the MAX USER_CONNECTIONS setting on your MySQL server for the user. In PHPMyAdmin go to the server page (Click on the Server:<>) and in the sub-menu click on priviledges. Edit the user and the MAX USER_CONNECTIONS will be on the right side. By default I believe it is set to 0 (unlimited), yours maybe restricted depending on who setup the server. //----------------------------------------------------------------------------------- 5 down vote   First of all, try to know from your hosting server administrator about the max consecutive active connections available to the MySQL database. This is the most basic & primary information to have knowledge about. If your page(s) load in a decent amount of time and release the connection once the page is loaded, it should be fine. The problem occurs when your script takes some long time to retrieve information from the database or maintains the connections. Since you are executing INSERT and / or UPDATE operations of millions of rows, so you may have some problem. Additionally, if you fail to close connections in your script(s), it is possible that someone will load a page and instead of closing the connection when the page is loaded, it is left open. No one else can then use that connection. So please make sure that at the end of execution of all the MySQL / SQL queries, the database connection is closed. Also please make sure that your server provides more than 250 connections, since 100 connections is available in almost all the servers generally. Also make sure that you are not using the persistent connections (which is available when using the built-in function "mysql_pconnect()"), since this will lock up the user until the connection is manually closed. Hope it helps.
  12. okay, show me good PDO example
  13. http://picpaste.com/pics/samplework-KKwzbIQu.1375969217.jpg <?php include("includes/header.php"); print "<h3>Equipped Items</h3><hr />"; $equip = array(); $sql = "SELECT * FROM items WHERE itmid IN(:equip_primary,:equip_secondary,:equip_armor)"; $stmt = $db->prepare($sql); $stmt->bindValue(":equip_primary", $row['equip_primary'], PDO::PARAM_INT); $stmt->bindValue(":equip_secondary", $row['equip_secondary'], PDO::PARAM_INT); $stmt->bindValue(":equip_armor", $row['equip_armor'], PDO::PARAM_INT); $stmt->execute(); while ($r = $stmt->fetch()) { $equip[$r['itmid']] = $r; } print "<table width='75%' cellspacing='1' class='uprofcontdisp'> <tr> <th width='33%'>Primary Weapon</th> <td>"; if (isset($equip[$row['equip_primary']]['itmid'])) { print htmlentities($equip[$row['equip_primary']]['itmname']) . "</td><td><a href='unequip.php?type=equip_primary'>Unequip Item</a></td></tr></table>"; } else { print "None equipped.</td><td>Equip Primary</td></tr></table>"; } print"<table width='75%' cellspacing='1' class='uprofcontdisp'><tr><th width='33%'>Secondary Weapon</th><td>"; if (isset($equip[$row['equip_secondary']]['itmid'])) { print htmlentities($equip[$row['equip_secondary']]['itmname']) . "</td><td><a href='unequip.php?type=equip_secondary'>Unequip Item</a></td></tr></table>"; } else { print "None equipped.</td><td>Equip Secondary</td></tr></table>"; } print "<table width='75%' cellspacing='1' class='uprofcontdisp'><tr><th width='33%'>Armor</th><td>"; if (isset($equip[$row['equip_armor']]['itmid'])) { print htmlentities($equip[$row['equip_armor']]['itmname']) . "</td><td><a href='unequip.php?type=equip_armor'>Unequip Item</a></td></tr></table>"; } else { print "None equipped.</td><td>Equip Armor</td></tr></table>"; } print "</tr> </table>"; if (isset($equip[$row['equip_primary']]['itmtype']) && $equip[$row['equip_primary']]['itmtype'] == 4) { echo "<hr>"; ?> <a href='ammo.php'>Ammo Locker</a> <?php } print"<hr /> <h3>Inventory</h3><hr />"; $sql1 = "SELECT iv.*,i.*,it.* FROM inventory as iv LEFT JOIN items as i ON iv.inv_itemid=i.itmid LEFT JOIN itemtypes it ON i.itmtype=it.itmtypeid WHERE iv.inv_userid = :inv_userid ORDER BY i.itmtype ASC, i.itmname ASC"; $stmt = $db->prepare($sql1); $stmt->bindValue(":inv_userid", $row['id'], PDO::PARAM_INT); $stmt->execute(); if ($stmt->rowCount() == 0) { print "<b>You have no items!</b>"; } else { print "<b>Your items are listed below.</b><br /> <table class='uprofcontdisp' cellspacing='1'> <tr> <td hidden=''></td> <td width='25%'>Item</td> <td width='15%'>Value</td> <td width='20%'>Total Value</td> <td width='40%'>Links</td> </tr>"; $lt = ""; while ($v = $stmt->fetch()) { if ($lt != $v['itmtypename']) { $lt = $v['itmtypename']; print "\n<tr><td colspan=4><b> " . htmlentities($lt) . " </b></td></tr>"; } print "<tr><td>" . htmlentities($v['itmname']); if ($v['inv_qty'] > 1) { print " x" . $v['inv_qty']; } print "</td><td>$" . $v['itmsellprice'] . "</td><td>"; print "$" . ($v['itmsellprice'] * $v['inv_qty']); print "</td><td>"; ?> <a href="iteminfo.php?ID=<?php echo $v['itmid'] ?>">Info</a> <a href="itemsend.php?ID=<?php echo $v['inv_id'] ?>">Send</a> <a href="itemsell.php?ID=<?php echo $v['inv_id'] ?>">Sell</a> <a href="imadd.php?ID=<?php echo $v['inv_id'] ?>">Market</a> <?php if ($v['effect1_on'] || $v['effect2_on'] || $v['effect3_on'] || $v['effect4_on']) { ?> <a href="itemuse.php?ID=<?php echo $v['inv_id'] ?>">Use</a> <?php } if ($lt == "Melee Weapon" || $lt == "Gun" || $lt == "Armour") { ?> <a href="equip_weapon.php?ID=<?php echo $v['inv_id'] ?>">Equip</a> <?php } print "</td></tr>"; } echo "</table>"; } include("includes/footer.php"); ?>
  14. i will clear, why i said these words
  15. i will make new thread and explain why i said this and i will prove my posted words are perfect
  16. come on help him instead making jokes
  17. pointless we have to think how to grow this community instead of teasing anybody
  18. we have to think about attack system, because which are old those are so outdated and out of fashion(i am specifying more that what i want to say "support attack system")
  19. hint:- bcz you are interacting $_GET directly with query
  20. more better is possible by payment lol - - - Updated - - -   yes my friend Escapes special characters in the unescaped_string , taking into account the current character set of the connection so that it is safe to place it in a mysql_query(). If binary data is to be inserted, this function must be used.
  21. <?php include "globals.php"; $_GET['u'] = abs((int) $_GET['u']); if(!$_GET['u']) { print "Invalid use of file"; } else { // suggestion :- you can remove userstats ,cities, fed and gang from the query bcz you are not using em $_GET['u'] = mysql_real_escape_string($_GET['u'], $link) $q=$db->query("SELECT u.*,us.*,c.*,h.*,g.*,f.* FROM users u LEFT JOIN userstats us ON u.userid=us.userid LEFT JOIN cities c ON u.location=c.cityid LEFT JOIN houses h ON u.maxwill=h.hWILL LEFT JOIN gangs g ON g.gangID=u.gang LEFT JOIN fedjail f ON f.fed_userid=u.userid WHERE u.userid={$_GET['u']}"); if($db->num_rows($q) == 0) { print "Sorry, we could not find a user with that ID, check your source."; } else { if($ir['DailyVote'] == False) { $r = mysql_fetch_array($q); $db->query("UPDATE `users` SET DailyVote = 'True' WHERE `userid` = &ir['userid']"); $db->query("UPDATE `users` SET upvotes=upvotes+1 WHERE `userid` = &r['userid']"); print "You have up voted the player!"; } else { print "You may only vote once per day."; } } } $h->endpage(); ?> hope it will help you
  22. good job but i can make much best
  23. sure why not, even not far NWE
  24. good work mate
  25. i can configure on any engine this registration script so engine doesn't make difference here
×
×
  • Create New...