lulucious Posted December 5, 2011 Share Posted December 5, 2011 Hello everyone, I am looking for a way to : 1. Add a field product_id to the contact form (potentially filled by a GET query directly from the product page!) 2. Modify contact-form.php to save in db the product_id of the message 3. Display the corresponding product in the admin when reading the employees > customer service tab Someone has done this before? Any short tutorial on the changes i have to do on contact-form.php? Thanks you all for your help All the best, Link to comment Share on other sites More sharing options...
Fabien Serny Posted December 6, 2011 Share Posted December 6, 2011 Hi, I'm not sure what your problem is. It does not seem too hard. 1) Fill the link to the contact form with the get var 2) Fill an hidden field with the id_product value (please secure it to avoid XSS security breach) 3) Add a field in the message table in the database to save the product_id 4) Overload the contact form controller to save the post hidden value in db 5) You can't overload in PS 1.4 (you will be able to do it in 1.5), so you will have to edit the admin message tab to display the name and link to the product page. 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