vchris Posted January 9, 2007 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? Link to comment Share on other sites More sharing options...
aspnetguy Posted January 9, 2007 Share Posted January 9, 2007 never had an issue like that before....whne you get home can you post the code? Link to comment Share on other sites More sharing options...
vchris Posted January 9, 2007 Author 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... Link to comment Share on other sites More sharing options...
Escee Posted January 9, 2007 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. Link to comment Share on other sites More sharing options...
vchris Posted January 9, 2007 Author 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. Link to comment Share on other sites More sharing options...
vchris Posted January 10, 2007 Author Share Posted January 10, 2007 I resolved the issue. I compared the 2 different sections and mine was different just a bit. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now