Hey, welcome to ZBCode, the premier coding forum for ZB. Here you fill find some of the best Invisionfree and Zetaboards Codes on the network! Unfortunately, you're sorta hovering around in guest mode at the moment; why not join in on the fun? Register an account and you can start accessing the wealth of resources we have available here. Enjoy your stay at ZBCode, and remember to tell all your friends about us; the more members, the more codes available. ![]() Interested in joining? Click here. If you are already a member of ZBCode, feel free to login right here: |
| Attempting a calc | |
|---|---|
| Tweet Topic Started: Jul 2 2009, 02:17 AM (212 Views) | |
| Hiddenzbu | Jul 2 2009, 02:17 AM Post #1 |
![]() ![]()
|
Well, its not about IF or ZB, but its about coding in general so I believe this topic is still allowed. Anyway, I'm "attempting" to create an online calculator for my site in order to process a certain formula that is found in the Pokemon Games, namely the amount of experience you gain from being a particular foe. I know very some (very limited) PHP but when I started I thought it didn't sound too hard to make. I was horribly wrong, I now feel like I have no idea what I'm doing. I've gone over the W3 pages on PHP several times and can't seem to find exactly what I'm looking here so I'll just concede to look like a doofus and post it here. Basically I want it to process this equation when certain things in the form are selected from the drop down, inputted, or check marked. EXP = (a x b x L)/ 7 (Note: There are some more stipulations with A but I'm hoping to get help without having to bore you guys about the mechanics of the Pokemon games) Here is what I have so far, but I'm obviously doing something wrong because I can't even get the thing to process when I hit submit. Spoiler: click to toggle
|
| |
![]() |
|
| Garath531. | Jul 2 2009, 09:28 PM Post #2 |
![]()
|
Try using either of these two codes: Spoiler: click to toggle Edited by Garath531., Jul 2 2009, 09:28 PM.
|
I'm back after an unexpected hiatus. If I've forgotten about a code I was working on for you, just drop me a PM and let me know.
| |
![]() |
|
| HolySavior | Jul 2 2009, 10:04 PM Post #3 |
![]()
Modifying The World Around You
![]()
|
if your doing this on the page itself and not submiting any info to a database. just use JavaScript to run the form. |
![]() |
|
| Choco | Jul 3 2009, 09:13 AM Post #4 |
|
¡ʎɹoʇɔɐɟ ʎʇıʌɐɹƃ ɐ uı pǝddɐɹʇ ɯ,ı 'dןǝɥ
![]()
|
I can confirm that the second one works -- aquate.us/poke.php.
|
It's a magical world, Hobbes, ol'd buddy... ...let's go exploring!In progress: Something Special ;) | |
![]() |
|
| Hiddenzbu | Jul 3 2009, 02:29 PM Post #5 |
![]() ![]()
|
Oh wow thank you very much. But if you don't mind could you give me a brief rundown of the things that you changed, just so I don't have to keep bothering you guys for my future coding endeavors. And @ holy, I would but even though I barely have any PHP knowledge I have about zero javascript knowledge. |
| |
![]() |
|
| 1 user reading this topic (1 Guest and 0 Anonymous) | |
| « Previous Topic · Code University · Next Topic » |




















7:46 PM Jul 10