Yes. If the attribute being filled in is a Text attribute, it can be forced to be required by selecting the required flag within the attributes controller... See the following FAQs:
http://www.zen-cart.com/content.php?...to-my-products
and:
http://www.zen-cart.com/content.php?...e-causing-this (The first line applies only for this situation..)
There are other ways as well to do data validation after submitting, but the above should address your immediate concerns/issues.
ZC Installation/Maintenance Support <- Site
Contribution for contributions welcome...
thanks for the reply, but served me because this is already created and donot where access it, is when the user is doing the buying asking these mandatory fields I want to add
Sorry, I guess I misunderstood the original request/expectation. Thank you for clarifying.
Although it probably is more preferred to put the attribute in the product itself, you could do validation in the header_php.php file that follows (or an observer) to kick back to the previous or designated page... Would check for the post data of the field to validate that it is not blank, and if it is blank to take the action necessary to 1) post a message about the need to enter the data and to return back (forward) to that page..
ZC Installation/Maintenance Support <- Site
Contribution for contributions welcome...
If a dropdown of options would work (and it looks like it would) re-working this mod might be easier: http://www.zen-cart.com/downloads.php?do=file&id=90
You could also customize the file:
/includes/modules/pages/checkout_configuration/header_php.php
and add the code in RED:
Now, if they try to submit the order on the checkout_confirmation page without a comment, they will be returned to the checkout_payment and they will see a red message telling them to include a comment ...Code:if (isset($_POST['payment'])) $_SESSION['payment'] = $_POST['payment']; $_SESSION['comments'] = $_POST['comments']; // bof: force comment if (trim($_SESSION['comments']) == '') { $messageStack->add_session('checkout_payment', 'Please enter order comments before proceeding.', 'error'); zen_redirect(zen_href_link(FILENAME_CHECKOUT_PAYMENT, '', 'SSL')); } // eof: force comment //'checkout_payment_discounts' //zen_redirect(zen_href_link(FILENAME_CHECKOUT_PAYMENT, '', 'SSL'));
Linda McGrath
If you have to think ... you haven't been zenned ...
Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!
Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
Officially PayPal-Certified! Just click here
Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!
thank for the reply mc12345678 and stevesh; stevesh I have the version 1.53 that is a module and then lets me add a option value?
pd: products database with this module are removed?
mc12345678 I did not understand your answer
it worked thanks RED, but is possible to make a option value in here?
It appeared from your image that you want the customer to choose from a number of companies the order would be shipped from. If that isn't correct, post again.
that is correct as you say
Bookmarks