vchris 3 Posted January 9, 2007 Report Share Posted January 9, 2007 So last night I was working on a website for a client. I didn't develop this site I'm only updating it. Unfortunately I don't have the code with me since I don't have access to it at work. My problem is I have a hidden field called colourcost which is used to add to the price of a specific item. There is an include file (left.php) before the content is included that will add the item to the cart upon form submit (buy button/add to cart button). In that included file (left.php) I was testing $_POST['colourcost'] and it seems like it's unable to get the value of the hidden field. I have checked this many times, the hidden field is there and the value is there. Why wouldn't $_POST['colourcost'] get the value from the hidden field? Could the includes be the problem? Has anyone had any issues like that before? Quote Link to post Share on other sites
aspnetguy 30 Posted January 9, 2007 Report Share Posted January 9, 2007 never had an issue like that before....whne you get home can you post the code? Quote Link to post Share on other sites
vchris 3 Posted January 9, 2007 Author Report Share Posted January 9, 2007 Sure np. It's even more complicated when you didn't build the app. I confused to why I can't get the value. If I set the $_POST['colourcost'] to a value then it's fine but that's not what I want. I want it to be dynamic.Also, the developer did the same thing for another section of items and it works. I've compared the 2 sections and they are both pretty much the same. I'll try and compare it in detail tonight, was getting late last night... Quote Link to post Share on other sites
Escee 0 Posted January 9, 2007 Report Share Posted January 9, 2007 Also.. hidden fields are great for hackers 'cause you can edit them with external PHP scripts that 'opens' your website and send these forms. Quote Link to post Share on other sites
vchris 3 Posted January 9, 2007 Author Report Share Posted January 9, 2007 That's too bad because I'm not the original web developer for this app so I will not do extensive work on it. A friend of mine which is gone for 1 year is the original web developer. I see some flaws in his scripting but I have enough work as it is. Quote Link to post Share on other sites
vchris 3 Posted January 10, 2007 Author Report Share Posted January 10, 2007 I resolved the issue. I compared the 2 different sections and mine was different just a bit. Quote Link to post Share on other sites
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.