Poldar Posted September 24, 2008 Share Posted September 24, 2008 Hey all..I just made my first modification..but I dont know if it is right.. So if you could help me out..and point out some big mistakes.. Dont be to harsh please.I just started getting into PHP like a week ago.. Thanks much Mod is supposed to do a little pop ip box... and ad $1 to the users money You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Thanks much Quote Link to comment Share on other sites More sharing options...
Haunted Dawg Posted September 24, 2008 Share Posted September 24, 2008 Re: My First MOD EVER!!! Need help..think there is big time mistakes... You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Quote Link to comment Share on other sites More sharing options...
Poldar Posted September 24, 2008 Author Share Posted September 24, 2008 Re: My First MOD EVER!!! Need help..think there is big time mistakes... Wow... I was WAY off... I learned what I know so far off of w3schools.com So...Yea it was fine on how I did it.. Quote Link to comment Share on other sites More sharing options...
Uridium Posted September 24, 2008 Share Posted September 24, 2008 Re: My First MOD EVER!!! Need help..think there is big time mistakes... Your getting there POLDER :) havent tested the script but by looking at it, the script puts money into an account when a button is pressed on a thursday.. Few pointer though.. just to keep you on the right track... :) Always put HTML at the end of a script as sometimes you will find it conflicting with the global_func.php When closing out a php the ?php> is not needed just a simple ?> will do.. The table for your USER should be USERS i make that mistake quite alot as well... But for a first attempt your doing Okies.... What i usualy do is look at already coded scripts and just alter things on trial and error to see the outcome if it dont work just revert it bak to how it was and have another go.. You will start to pick it up quite fast that way. Quote Link to comment Share on other sites More sharing options...
Haunted Dawg Posted September 24, 2008 Share Posted September 24, 2008 Re: My First MOD EVER!!! Need help..think there is big time mistakes... You werent way off, you arnt familiar with mixing php / html / javascript into one. And the mccode base + querys. Lol in my script i misses a s in the query: You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Should be: You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. Quote Link to comment Share on other sites More sharing options...
Poldar Posted September 24, 2008 Author Share Posted September 24, 2008 Re: My First MOD EVER!!! Need help..think there is big time mistakes... Thanks! Ill keep studying..and for now..Ill stick to very simple mods :D Thanks again! Quote Link to comment Share on other sites More sharing options...
Zero-Affect Posted September 24, 2008 Share Posted September 24, 2008 Re: My First MOD EVER!!! Need help..think there is big time mistakes... or you could use You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. but not at your level research sprintf it may come in handy when securing scripts Quote Link to comment Share on other sites More sharing options...
Zero-Affect Posted September 24, 2008 Share Posted September 24, 2008 Re: My First MOD EVER!!! Need help..think there is big time mistakes... i thought that preset digits didn't need %u and yeah it was about 4am when i posted lol Quote Link to comment Share on other sites More sharing options...
Poldar Posted September 24, 2008 Author Share Posted September 24, 2008 Re: My First MOD EVER!!! Need help..think there is big time mistakes... You're unable to view this code. Viewing code within this forum requires registration, you can register here for free. I see what you did..you added variables so that you could randomize the script when ever you want... How would we randomize the money given? something like ran. money_give >100? or something? Quote Link to comment Share on other sites More sharing options...
War_Hero Posted September 24, 2008 Share Posted September 24, 2008 Re: My First MOD EVER!!! Need help..think there is big time mistakes... To randomise the money give out, change: $money_give = 900; to $money_give = rand(600,900); :) Nice little mod here. +1 from me for the effort. You'll get the hang of PHP quite quickly. I've been coding for around 1-2 months now and have grasped all of the basics. :) Quote Link to comment Share on other sites More sharing options...
Poldar Posted September 24, 2008 Author Share Posted September 24, 2008 Re: My First MOD EVER!!! Need help..think there is big time mistakes... Thanks all for the support :lol: Quote Link to comment Share on other sites More sharing options...
Zero-Affect Posted September 24, 2008 Share Posted September 24, 2008 Re: My First MOD EVER!!! Need help..think there is big time mistakes... No problem, good luck Quote Link to comment Share on other sites More sharing options...
Poldar Posted September 26, 2008 Author Share Posted September 26, 2008 Re: My First MOD EVER!!! Need help..think there is big time mistakes... I'll make another one here soon.. :mrgreen: Quote Link to comment Share on other sites More sharing options...
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.