Gowans007 Posted April 26, 2010 Share Posted April 26, 2010 At point of purchase I want to add six yes or no questions, preferably at the start of the checkout. I want to capture the answers and if no is selected for any of the options to not allow a purchase. How can I implement this? What is the best way? Link to comment Share on other sites More sharing options...
Guest Posted April 26, 2010 Share Posted April 26, 2010 Gowans, You really don't need to capture the answers to the database unless you have another purpose for the answers. But, you can create the yes/no radio buttons and use a form validation to put the conditions in place whether or not to proceed with the checkout. Chris Link to comment Share on other sites More sharing options...
Gowans007 Posted April 27, 2010 Author Share Posted April 27, 2010 How do I do this? Can you point me in the right place? Link to comment Share on other sites More sharing options...
Guest Posted April 27, 2010 Share Posted April 27, 2010 Gowans, There is no 'right place' to send you as this would be custom coding. I do not think there is a contribution currently available to this, or anything close that you might be able to modify. So, ya, this would be a custom code project. Chris Link to comment Share on other sites More sharing options...
chooch Posted April 27, 2010 Share Posted April 27, 2010 At point of purchase I want to add six yes or no questions, preferably at the start of the checkout. I want to capture the answers and if no is selected for any of the options to not allow a purchase. How can I implement this? What is the best way? You can install this contribution and make some modifications as it will mean you do not have to custom code the whole thing: Customer Extra Fields Now, from what I can see the way it works is by adding extra fields (radiosets, checkboxes, input fields) to the create account page but you can opt to add them to the checkout_shipping, checkout_payment or checkout_confirmation page if you wish. In a nutshell,as it stands it allows you to ask your 6 or 7 questions with a yes/no radioset but this is what you need to do: 1) When installing make sure you substitute the create account page with the page you wish you add the questions to 2) Also, when installing make sure you add those questions to in the admin area to the orders.php file instead of admin/customers so you can see the order, order status, order notes and your yes/no questions and answers on the same page I wish you success Upon receiving fixes and advice, too many people don't bother to post updates informing the forum of how it went. Until of course they need help again on other issues and they come running back! Why receive the information you require in good faith for free, only to then have the attitude to ignore the people who gave it to you? There's no harm in saying, 'Thanks, it worked'. On the contrary, it creates a better atmosphere. CHOOCH Link to comment Share on other sites More sharing options...
Gowans007 Posted April 27, 2010 Author Share Posted April 27, 2010 Thanks alot chooch, I'll try this in a few hours, it seems perfect for what I need. Link to comment Share on other sites More sharing options...
Gowans007 Posted April 28, 2010 Author Share Posted April 28, 2010 I'm getting there with this, I can add it to the New Customer and Customer update page but any ideas how I get it on the Shipping Page? Link to comment Share on other sites More sharing options...
chooch Posted April 28, 2010 Share Posted April 28, 2010 I'm getting there with this, I can add it to the New Customer and Customer update page but any ideas how I get it on the Shipping Page? Gowans007, it is not rocket science. You should copy/paste the text in various parts of the page and keep doing it until you find the location you want it for. Personally I cannot fathom why you feel the need to ask these questions at so many different places, but if anything, keep the questions in on your checkout_success page as customers would not need to re-enter the answers in case they go back and forth re-entering payment and shipping options and also because they are commenting 'after' the transaction has been confirmed. Upon receiving fixes and advice, too many people don't bother to post updates informing the forum of how it went. Until of course they need help again on other issues and they come running back! Why receive the information you require in good faith for free, only to then have the attitude to ignore the people who gave it to you? There's no harm in saying, 'Thanks, it worked'. On the contrary, it creates a better atmosphere. CHOOCH Link to comment Share on other sites More sharing options...
Gowans007 Posted April 28, 2010 Author Share Posted April 28, 2010 OK, I'll remove it from the customer side and see if I can paste the code into the shipping page, I was concerned it would not capture. I just need it there to add a few more options to the delivery of the product and to check they are eligible when ordering. Link to comment Share on other sites More sharing options...
burt Posted April 28, 2010 Share Posted April 28, 2010 If all that you need to do is not allow checkout if ny answer is no, then a simple bunch of radio buttons, with a javascript to remove the "continue" button is all that is needed. Would sugges that you ask these BEFORE someone creates an account, but AFTER they have started checkout. Which means one of these; 1. at the top of create_account.php (not good if you need to ask a person again, who may already have created an account. 2. shopping_cart.php 3. login.php My suggestion would be login.php. Don't show the login box, ot the new customer box, until AFTER they have answered those questions. If the questions have determined they cannot proceed, show a message. if they can proceed then load the rest of the page. Link to comment Share on other sites More sharing options...
chooch Posted April 29, 2010 Share Posted April 29, 2010 OK, I'll remove it from the customer side and see if I can paste the code into the shipping page, I was concerned it would not capture. I just need it there to add a few more options to the delivery of the product and to check they are eligible when ordering. I see. It would have helped if you stated this when starting the thread so advice and assistance can be given. If it makes life easier (and it probably would), remove the extra fields contribution and add this instead: Customer Must Accept Terms and Conditions What this does is place a checkbox with an "I agree to the Terms and Conditions" link. By default it goes in create_account under the password fields but again, you can add it in the checkout pages if necessary. You can use the language files to give the page whatever text you want including the 6 or 7 questions and you can use the filename file to re-name it to 'Shipping Confirmation' or 'Whatever Page You Want'. Give it a try and see if it meets your needs. Upon receiving fixes and advice, too many people don't bother to post updates informing the forum of how it went. Until of course they need help again on other issues and they come running back! Why receive the information you require in good faith for free, only to then have the attitude to ignore the people who gave it to you? There's no harm in saying, 'Thanks, it worked'. On the contrary, it creates a better atmosphere. CHOOCH Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.