Cakephp form input date empty

Posted: BiUs65 Date: 03.06.2017

I would have though it would still pass though the non-disabled fields. I've even tried to remove the disabled field attribute when the submit button is pushed but this still returns an empty array. That's the way HTML works, disabled don't get posted. CakePHP can't change what is sent from the browser. If you still want the value you can set it as a hidden element.

cakephp form input date empty

I ended up removing the disabled option from this, leaving the ready only and added some addition CSS stylings so it looked disabled to the user. This is not the exact answer to the question but works as a different approach. By posting your answer, you agree to the privacy policy and terms of service.

Stack Overflow Questions Developer Jobs Documentation beta Tags Users.

php - CakePHP: Date field with default values - Stack Overflow

Sign up or log in to customize your list. Tour Start here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business Learn more about hiring developers or posting ads with us.

Log In Sign Up. Join the Stack Overflow Community. Stack Overflow is cakephp form input date empty community of 7. Join them; it only takes a minute: Is there something cake related that might be causing this? Cakephp form input date empty Some problems I see: You never said your form was submitted from JS, first test with a simple form POST then JS. Your JS code is set to submit a form by ID CardModifysaleForm.

Class Cake\View\Helper\FormHelper | CakePHP

There's no such ID in your supplied view code and you're not setting your form to that ID from the best stocks under 5 dollars to buy you supply. I understand that but I thought the non-disabled fields should still come though?

I have 3 disabled fields on the form and 10 non disabled fields, when the 3 are disabled the other data doesn't come though as well? Ok, it wasn't clear at first that when you post you don't get any fields from your question. Can you please update your question with your view code? OK thanks, I hacve put in a snippet of the code, the form create line, a few lines with the disabled class and some without and then the button.

cakephp form input date empty

Sign up or log in StackExchange. Sign up using Facebook. Sign up using Email and Password. Post as a guest Name. Stack Overflow works best with JavaScript enabled. MathOverflow Mathematics Cross Validated stats Theoretical Computer Science Physics Chemistry Biology Computer Science Philosophy more 3. Meta Stack Exchange Stack Apps Area 51 Stack Overflow Talent.

Rating 4,6 stars - 670 reviews
inserted by FC2 system