» Quick Links
You can make money on these forums
We Share profits with you
Google
Google Adsense
Google Adwords
YPN
Yahoo
MSN Search
Web Directories
Web Hosting
Web Hosting Offers
Hosting News
Suggestions
Link Building
Domain Names
PHP Forums
MySQL Forums
» More Links
OSP News
Reseller Hosting
Shared Hosting
Dedicated Servers
Google Adsense
Search Engine Marketing
Link Development
Affiliate Marketing


» Advertising
Multiple DC PR Check

Free SEO Tools


Go Back   Webmaster Forums > Website Developement / Programming > PHP Programming and Tips

PHP Programming and Tips Discuss about PHP programming and Share Tips. Ask questions about Scripting and Errors.

Reply
 
Thread Tools Display Modes
  #1  
Old 08-08-2006, 02:36 PM
gypsy gypsy is offline
Junior Member
 
Join Date: Aug 2006
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
gypsy is on a distinguished road
Thumbs down works o 4.4.1 but not on 5.1.4

hello buddies, hru

I have a car loan calculator script that works fine on PHP Version 4.4.1 on FreeBSD. I just got an email from someone using the script saying it doesn't work on PHP 5.1.4 on Linux or Windows. Here is the script:



<form action=
PHP Code:
<?php echo $_SERVER["PHP_SELF"] ."#auto_loan" ?>
>
</td><td>

<br>
Vehicle Price : <input size=10 name="loan_amount" type="text"><br>
Trade In Amount : <input size=10 name="tradein" type="text"><br>
Interest Rate : <input size=2 name="interest" type="text"><br>
Years to Pay : <input size=2 name="years" type="text"><br>



PHP Code:
<?

if (isset($calculate))

{

-- This message may have been cut off and the rest will only be shown to members. To become a member, click here --
Reply With Quote
Revenue Sharing Ads ( ?):
  #2  
Old 08-08-2006, 02:39 PM
techguru techguru is offline
OSP Starters
 
Join Date: Jul 2006
Posts: 11
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
techguru is on a distinguished road
Default

  1. I suggest you to read about the 'register_global off' issues. I guess that the php version is not involved but this guy just have a well configured php which doesn't allowed accessing POST and GET variable without a proper indexing of the form $_POSt / $_GET
  2. be carefull with your "if (isset($calculate))" which should be "if (isset($_GET['calculate']))". When hitting the submit button with the "enter" key, the submit value is not send by several browser therefore it shouldn't be used to identify wether the form was submitted or not.
  3. Well formed HTML must have all parameter quoted value=Calculate => value="Calculate"
  4. That wouldn't solve your issue but it would be way better =)

cheers
good luck -- This message may have been cut off and the rest will only be shown to members. To become a member, click here --
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Web Site Success: What Works - Strategy or Blind Luck waqar Premium Webmaster Articles 0 10-30-2006 07:36 AM
PHP version 5.1.4... code upgrade pointers anyone? utseya PHP Programming and Tips 1 08-14-2006 04:05 PM
Query works on production but not on testing server parore MySQL Forums 1 07-31-2006 04:11 PM
301 redirect works with yahoo!! jake Yahoo 3 03-26-2006 06:51 AM
302 works!!!!!!! katelyn Google 3 03-25-2006 01:46 PM


All times are GMT. The time now is 09:04 PM.