gbudge Posted May 13, 2019 Share Posted May 13, 2019 (edited) Hi, firstly thank you to all on this forum who have provided assistance - I have used this extensively as a source for learning how to get things done in PS. Much appreciated (especially Vekia - legend!). I am trying to retrieve the mobile phone value of the logged-in customer from $cookie to pre-populate an input form. I currently have the following working: {$cookie->customer_firstname} {$cookie->customer_lastname} {$cookie->email} These all work perfectly. I have a value for mobile_phone stored on the shop_customer table (I added this field in order to have the mobile stored for customers who do not want to create an address record immediately - but I do need mobile number). How do I get this into the cookie as well, or alternatively how do I retrieve it in the script for the logged-customer? I tried to use the same code that works fine on the My Personal Information page (identity.tpl) to retrieve the correct mobile phone value {$smarty.post.mobile_phone}. But it does not return a value on the new page. Any guidance will be appreciated. EDIT: Resolved. Found the answer buried in the comments here: http://prestacraft.com/adding-new-fields-to-the-registration-form/#. I managed to add the mobile phone value to the cookie in AuthController.php and it worked perfectly! Edited May 13, 2019 by gbudge (see edit history) 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