Danny696 Posted February 25, 2010 Posted February 25, 2010 Well, i was trying to learn javascript, in the book, it had jQuery, talked about $.get and $.post so i thought could it be usefull for equiping/unequipping quicker. So ive re-coded it and im thinking of re-coding others with parts of jQuery, i pull it from google, uses less stress on sever load. but anyway, 4 re-coded files, no tables, great mod! inv/inventory.php: You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Equip_armor.php: You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. equip_weapon.php: You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Unequip.php: You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Simplez Quote
Danny696 Posted February 25, 2010 Author Posted February 25, 2010 Imagine this, a table with 3 headings, and the name of an item in the box below, with unequip below 3 coloums. Quote
CJ - Twitch Posted February 25, 2010 Posted February 25, 2010 Lmao Danny. But I have a crap imagination ... :| Quote
rulerofzu Posted February 26, 2010 Posted February 26, 2010 Works fine. The only problem I can see is that FF users who love to run noscript run immediately into problems due to the script being called from an external url. Running a min js file on a server (721kb) isnt that much of a server load. Well as long as your on a decent server :D For the screenshot lovers out there....here is one for you :D Nice job though jquery :D Quote
Jordan Palmer Posted February 26, 2010 Posted February 26, 2010 Works fine. The only problem I can see is that FF users who love to run noscript run immediately into problems due to the script being called from an external url. Running a min js file on a server (721kb) isnt that much of a server load. Well as long as your on a decent server :D For the screenshot lovers out there....here is one for you :D Nice job though jquery :D Thanks for adding screenie Quote
CJ - Twitch Posted February 26, 2010 Posted February 26, 2010 looks the same to me... What does it do? xD Quote
Danny696 Posted February 26, 2010 Author Posted February 26, 2010 uses jquery, test it and find out Quote
rulerofzu Posted February 26, 2010 Posted February 26, 2010 in laymans terms the jquery will equip/unequip on the page rather than you going back n forth between other pages. I only tested the unequip but im sure the equip will work in the same way. Quote
Djkanna Posted February 27, 2010 Posted February 27, 2010 Argh, Why the '@' operator??!? Come on Danny don't you think if there was no globals.php file the game wouldn't work so you wouldn't be able to sign in, so you wouldn't be available to use the inventory so your script wouldn't work so it wouldn't need the @ there anyway.. Inconclusion: @ = useless ;) Other than that good job buddy Meh EDIT: Thanks to Nickson (pointed out that you use it elsewhere also) I didn't notice this so the above applies to the operator on the include ;) Quote
Zero-Affect Posted February 27, 2010 Posted February 27, 2010 good point Djkanna. in laymans terms Always wondered how you spell that but sadly i believe it's layman terms mate (i did once believe it was 'lamens' from lame + men) The sheep are among us run for your life! Quote
rulerofzu Posted February 28, 2010 Posted February 28, 2010 lmao never used that before so didnt think to look it up....but hey kudos to you for pulling me up for it Quote
virtualshogun Posted March 2, 2010 Posted March 2, 2010 one other approach to this is meta refresh or did i miss this totally its 6:00 Am and im running on little sleep lol but here item_remove($userid, $r['itmid'], 1); $db->query("UPDATE users SET {$_GET['type']} = {$r['itmid']} WHERE userid={$userid}"); print "Item {$r['itmname']} equipped successfully. <meta http-equiv='Refresh' content='1;url=inventory.php'>"; so after they equip they will see item x equipped successfully then a moment later it kicks you back to the inventory, and it works with i.e or f.f with no-script on :D Quote
03laceys Posted December 2, 2010 Posted December 2, 2010 Thought i would test the modification out. Unfortunatly this mod dosn't work. I have uploaded it to a fresh copy of mccodes v2. Upon clicking equip/unequip it goes to the index page (but does actually perform the action) I know nothing about ajax/jquery to be honest so cannot help fixing it. Not mocking you just pointed out my findings. Nice Idea for a little bit of Jquery on the inventory. Quote
The Spirit Posted December 2, 2010 Posted December 2, 2010 Thought i would test the modification out. Unfortunatly this mod dosn't work. I have uploaded it to a fresh copy of mccodes v2. Upon clicking equip/unequip it goes to the index page (but does actually perform the action) I know nothing about ajax/jquery to be honest so cannot help fixing it. Not mocking you just pointed out my findings. Nice Idea for a little bit of Jquery on the inventory. Works for me Quote
Danny696 Posted December 2, 2010 Author Posted December 2, 2010 Strange, seems to work fine for everyone else :/ Quote
03laceys Posted December 2, 2010 Posted December 2, 2010 Mmm does seem a bit strange i will try again, but there isn't much you can do wrong with this modification lol. Quote
The Spirit Posted December 2, 2010 Posted December 2, 2010 I added this before along time ago and it didnt work. Added it the other day to test it out and worked fine :) Quote
03laceys Posted December 2, 2010 Posted December 2, 2010 Mmm strange still not working my end :/ I am using IE Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.