mojtabam Posted May 24, 2013 Share Posted May 24, 2013 Hi, I am using prestashop 1.5.4.1 on a remote server and using send to a friend module v. 1.2. This module do not work and do not send any email. Does anybody know how can I fix it? Best Regards, Mojtaba Link to comment Share on other sites More sharing options...
vekia Posted May 25, 2013 Share Posted May 25, 2013 hello have you got an access to the php error log? If so, you should check this file for module errors. YOu can also turn error reporting in your store, then try to use this module - then if some php error occur - you will see it Link to comment Share on other sites More sharing options...
mojtabam Posted May 25, 2013 Author Share Posted May 25, 2013 (edited) Hi, I checked in my cpanel error log this line: [25-May-2013 13:53:49 America/Toronto] PHP Notice: Undefined property: stdClass::$value in /home5/supersj5/public_html/shop/modules/sendtoafriend/sendtoafriend_ajax.php on line 43 I checked that file, it is here: foreach ($friend_infos as $entry) { if ($entry->key == "friend_name") $friendName = $entry->value; (line 43) else if ($entry->key == "friend_email") $friendMail = $entry->value; else if ($entry->key == "id_product") $id_product = $entry->value; } if (!$friendName || !$friendMail || !$id_product) die('0'); By the way, I do not know why my first post here is marked yellow and some words are misplaced! Could you please let me know what should I do now for the next step? Thanks a lot, Mojtaba Edited May 25, 2013 by mojtabam (see edit history) Link to comment Share on other sites More sharing options...
Bers Posted May 28, 2013 Share Posted May 28, 2013 Hi! You can fix this bug in file modules/sendtoafriend/sendtoafriend-extra.tpl replace line 48 data: {action: 'sendToMyFriend', secure_key: '{/literal}{$stf_secure_key}{literal}', friend: unescape(JSON.stringify(datas).replace(/u/g, '%u'))},{/literal}{literal} with data: {action: 'sendToMyFriend', secure_key: '{/literal}{$stf_secure_key}{literal}', friend: JSON.stringify(datas)},{/literal}{literal} 1 Link to comment Share on other sites More sharing options...
vekia Posted May 28, 2013 Share Posted May 28, 2013 looks fine, @mojtabam can you please check it? And let us know if this works work you Link to comment Share on other sites More sharing options...
mojtabam Posted May 28, 2013 Author Share Posted May 28, 2013 Hi, I changed it, but still it is not working. I entered the name of the friend in the site and his email. But I did not received any email!! Could you please take a look at it again? Thanks, Mojtaba Link to comment Share on other sites More sharing options...
Japanas Posted May 29, 2013 Share Posted May 29, 2013 Hello, I'm using PrestaShop v1.5.4.1 French translation and I'm facing same issue : email is not sent. Link to comment Share on other sites More sharing options...
YanK1973 Posted May 29, 2013 Share Posted May 29, 2013 Just checked mine too, version 1.5.4.1, not working too. Link to comment Share on other sites More sharing options...
vekia Posted May 29, 2013 Share Posted May 29, 2013 please after apply changes mentioned by Bers above, make sure that you've got force compilation turned to on in your store Link to comment Share on other sites More sharing options...
mojtabam Posted May 30, 2013 Author Share Posted May 30, 2013 Thanks vekia, I checked it. It is enabled and grey out! Link to comment Share on other sites More sharing options...
Japanas Posted May 30, 2013 Share Posted May 30, 2013 Thank you, it works now after replacing line 48. Link to comment Share on other sites More sharing options...
YanK1973 Posted May 30, 2013 Share Posted May 30, 2013 Hi! You can fix this bug in file modules/sendtoafriend/sendtoafriend-extra.tpl replace line 48 data: {action: 'sendToMyFriend', secure_key: '{/literal}{$stf_secure_key}{literal}', friend: unescape(JSON.stringify(datas).replace(/u/g, '%u'))},{/literal}{literal} with data: {action: 'sendToMyFriend', secure_key: '{/literal}{$stf_secure_key}{literal}', friend: JSON.stringify(datas)},{/literal}{literal} Thank you, it works, just, after you replace line 48, disable cache and force compilation as Vekia said! Link to comment Share on other sites More sharing options...
vekia Posted May 30, 2013 Share Posted May 30, 2013 thanks all for informations, im really glad that module now works for you okay, so im going to mark this thread as [solved] if you've got any questions related to this case - feel free to continue discussion here regards Link to comment Share on other sites More sharing options...
mojtabam Posted May 30, 2013 Author Share Posted May 30, 2013 Thanks, mine is working too! Link to comment Share on other sites More sharing options...
anukku Posted June 9, 2013 Share Posted June 9, 2013 I did what you all said, but for me is still not working...I even deactivated/reactivated the module, unistalled it the reinstalled it again. ...All other mail are working fine... Link to comment Share on other sites More sharing options...
vekia Posted June 9, 2013 Share Posted June 9, 2013 I did what you all said, but for me is still not working...I even deactivated/reactivated the module, unistalled it the reinstalled it again. ...All other mail are working fine... the same ps version as others here? Link to comment Share on other sites More sharing options...
Piotr Kaczor Posted June 17, 2013 Share Posted June 17, 2013 Hello I've got the same problem. Here is probably the best solution: https://github.com/PrestaShop/PrestaShop/commit/f43da83d80aebcf6065b77a1db5d0e7d66e45263 Link to comment Share on other sites More sharing options...
anukku Posted June 18, 2013 Share Posted June 18, 2013 the same ps version as others here? Yes same version 1.5.4.1. I'll try the solution of Piotr later this day. Link to comment Share on other sites More sharing options...
anukku Posted June 18, 2013 Share Posted June 18, 2013 Ok so thanx to Piotr now it send mail, but i discovered there is no link atached to product...On mail translation on file send_to_a_friend.html i have on line 27: <td align="left"><b>Click aici pentru a vizualiza acest produs: </b>{product}</td> Link to comment Share on other sites More sharing options...
ediaime Posted July 10, 2013 Share Posted July 10, 2013 Hi the solution you provided is excellent, thank you very much, on the other hand, you could look out on this unit: http://www.prestashop.com/forums/topic/179143-module-product-question/page__st__40 has the same function and also fails to send the message, thanks again. Link to comment Share on other sites More sharing options...
klausjulius Posted August 15, 2013 Share Posted August 15, 2013 Thank you, it works, just, after you replace line 48, disable cache and force compilation as Vekia said! thanks alot. this works great for me!!!! Link to comment Share on other sites More sharing options...
Gasperus Posted August 25, 2013 Share Posted August 25, 2013 Perfect. Thanks. Link to comment Share on other sites More sharing options...
jahyax Posted September 17, 2013 Share Posted September 17, 2013 Good day! I don't know what I did wrong? I follow all the steps and mods above.. but I can't seem to make the send to friend work I am using version: 1.5.4 Link to comment Share on other sites More sharing options...
vekia Posted September 17, 2013 Share Posted September 17, 2013 in browser console you see some javascript / ajax query errors? Link to comment Share on other sites More sharing options...
jahyax Posted September 17, 2013 Share Posted September 17, 2013 there are no javascript / ajax query errors.. and when I check on the network, the response is 'mail sent 0' Link to comment Share on other sites More sharing options...
vekia Posted September 17, 2013 Share Posted September 17, 2013 other email messages from your store works? like order confirmation, account creation etc? what mail method you use? simple mail() or SMTP ? Link to comment Share on other sites More sharing options...
jahyax Posted September 17, 2013 Share Posted September 17, 2013 (edited) Other email messages from my store is working fine, like 'order confirmation' ..everything(mails) seems to be working fine.. except for "send to a friend" I am using the simple mail() .. Edited September 17, 2013 by jahyax (see edit history) Link to comment Share on other sites More sharing options...
luber_panda Posted September 26, 2013 Share Posted September 26, 2013 thanks. works ! Link to comment Share on other sites More sharing options...
benjamin utterback Posted September 27, 2013 Share Posted September 27, 2013 Just letting you guys know that the module has been updated. Take a look at this Github fix. Only use this if you are having problems with the module. https://github.com/PrestaShop/PrestaShop/commit/9d94337c9b6d1c808381f8181de1efc58e6c14e7 Thank you! Link to comment Share on other sites More sharing options...
rhleite Posted October 14, 2013 Share Posted October 14, 2013 Hi, I'm having problems with "Send to Friend" I am very new to PrestaShop and coding and I don't understand half of what is going on. However I did replace line 48 in the sendtofriend.txt thing in the file manger in my hosting page. Then I made sure Force compilation was on in the Performance thing. But it still doesn't work. I contacted the developer of my Theme but he said "please switch to default prestashop theme and check this issue in it" I don't know what he means by that... I don't understand what to do with what Benjamin Utterback posted either. Can someone explain to me in lay man terms please. However I'm not so dumb, I just need to be pointed in a right direction with a bit of some good explanation. Thank you Link to comment Share on other sites More sharing options...
vekia Posted October 14, 2013 Share Posted October 14, 2013 please describe what kind of problems with this addon you've got. in addition, please share information about prestashop version that you use and also about your template if it is possible - please share also url to your website Link to comment Share on other sites More sharing options...
rhleite Posted October 15, 2013 Share Posted October 15, 2013 (edited) Right, so first off, I am using the current version of prestashop 1.5.6.0. The theme I'm using is ClassicStore. And my website is: www.sinnersskincouture.com When I click on one of the products, where I can view all the the size,add to wish list, favourites etc...I click on Send To Friend, and a pop up appears with the pic and the fields to enter friends name and email, when i put name and email and click on "send" nothing happens. So I asked the theme developer what was up, and he said " "please switch to default prestashop theme and check this issue in it" Again, I wouldn't even know where to begin. I tried doing what was reccomended by others on this form but it's still not working. thank you Edited October 15, 2013 by rhleite (see edit history) Link to comment Share on other sites More sharing options...
vekia Posted October 15, 2013 Share Posted October 15, 2013 i inspected code of your website there is no "form" so it isn't possible to use "send" button. i think that you should follow your dev suggestion. switch for test purposes theme to default under preferneces > themes tab in your back office Link to comment Share on other sites More sharing options...
rhleite Posted October 15, 2013 Share Posted October 15, 2013 (edited) Okay, I switched to Theme Default...But what do I do now after I switch? Will I lose all my work when I switch to the default theme? Hi hmm, my friend is coming round at 2 pm to see the site and how it's coming along, so I'm gonna have to switch back to the Classic Store theme to show her...will that be possible?? Hi again well i had to switch back to the classic store theme as my friend is an hour earlier. I'll switch back to default theme but it'd be great to know what i need to do once im there...thanks Edited October 15, 2013 by rhleite (see edit history) Link to comment Share on other sites More sharing options...
benjamin utterback Posted October 15, 2013 Share Posted October 15, 2013 You really shouldnt be testing your live production store. Have you considered making a duplicate store and install it on a test domain? That way you can use that to switch themes and it would act the same as your live store because it is a duplicate copy. When you switch to the default theme, simply try and send to a friend as if normal. Let us know what happens then. Thank you! Link to comment Share on other sites More sharing options...
rhleite Posted October 15, 2013 Share Posted October 15, 2013 Hello, Oh I didn't even know I could do that, and honestly I wouldn't even know how to duplicate the store. But anyway, I switched to the Default store and went to the Product and selected Send to Friend and the pop up comes out, i type in name and email, and i click on send but nothing happens.... Link to comment Share on other sites More sharing options...
rhleite Posted October 16, 2013 Share Posted October 16, 2013 Hi again, can anyone help me with this?? This bug is the last one I have, everything else in the site is running good. I am only waiting on this to be solved so I can go ahead and open my store, please any help?? Link to comment Share on other sites More sharing options...
UnclaspMe Posted November 16, 2013 Share Posted November 16, 2013 Can't seem to get this to work get error "Your e-mail could not be sent. Please check the e-mail address and try again." have tried everything in this threads (with force complition) and few others, looked at many templates and most have this module disabled(all other emails work).I've only found it working on one template (Prestashop's most popular for sale).My website www.unclaspme.com any ideas how to fix???thanks for any help Declan Link to comment Share on other sites More sharing options...
UnclaspMe Posted November 17, 2013 Share Posted November 17, 2013 Can't seem to get this to work get error "Your e-mail could not be sent. Please check the e-mail address and try again." have tried everything in this threads (with force complition) and few others, looked at many templates and most have this module disabled(all other emails work). I've only found it working on one template (Prestashop's most popular for sale). My website www.unclaspme.com any ideas how to fix??? thanks for any help Declan managed to get a different Free version working link here http://www.prestashop.com/forums/topic/42609-amelioration-module-sendtoafriend-nouvelle-version-module-sendtomyfriend-v12/page-7?do=findComment&comment=1459470 Link to comment Share on other sites More sharing options...
WebUp Posted November 26, 2013 Share Posted November 26, 2013 Hey, I tried all three solutions (all with enebled force compile) First, the change of code from page one. Second the cange of code from presta team update(2nd page of this thread) And third, downloaded this french Send to my friend module, and still doesn't work. Can anyone help??? Link to comment Share on other sites More sharing options...
ysco Posted December 8, 2013 Share Posted December 8, 2013 I also have the same problem as above. Did replace module files with the new ones from github but i still got the message "Your e-mail could not be sent. Please check the e-mail address and try again." So what can be done more to fix this issue ?? Regards, ysco.. Link to comment Share on other sites More sharing options...
ysco Posted December 9, 2013 Share Posted December 9, 2013 Anyone?? ysco.. Link to comment Share on other sites More sharing options...
Pedro Henrique Posted December 21, 2013 Share Posted December 21, 2013 Atenção ao mover este módulo. Caso você mova-o a um hook que esteja dentro de uma tag <form></form>, o e-mail não será enviado. O hook "actionProductOutOfStock" é um exemplo.Boa sorte. __________________________________________________________________________________________________ Attention to move this module. If you move it to a hook that is inside a tag <form></ form>, the email is not sent. The hook "actionProductOutOfStock" is an example.Good luck. Link to comment Share on other sites More sharing options...
marcis Posted April 7, 2014 Share Posted April 7, 2014 Does this module save info about sent messages? I mean, being able to see which products were recommended and who to. Link to comment Share on other sites More sharing options...
thelaptopdude Posted February 16, 2015 Share Posted February 16, 2015 (edited) Hello I am having the same issue with the send to a friend module, I keep getting this error message: Your e-mail could not be sent. Please check the e-mail address and try again. www.thelaptopdude.com Please Help Thank You PrestaShop™ 1.6.0.11 Theme default-bootstrap Edited February 16, 2015 by thelaptopdude (see edit history) Link to comment Share on other sites More sharing options...
NemoPS Posted February 18, 2015 Share Posted February 18, 2015 Are you using custom smtp settings? Link to comment Share on other sites More sharing options...
thelaptopdude Posted February 18, 2015 Share Posted February 18, 2015 I Use PHP's mail() function (recommended; works in most cases) PS_MODE_DEV is now set to true www.thelaptopdude.com Thanks Nemo Link to comment Share on other sites More sharing options...
thelaptopdude Posted February 19, 2015 Share Posted February 19, 2015 Hello I had to set my PS_MODE_DEV back to false Link to comment Share on other sites More sharing options...
NemoPS Posted February 20, 2015 Share Posted February 20, 2015 Did you get any new error when it was enabled? Link to comment Share on other sites More sharing options...
thelaptopdude Posted February 20, 2015 Share Posted February 20, 2015 yes i did when I click the send button nothing happens, the popup page just stays there. Link to comment Share on other sites More sharing options...
NemoPS Posted February 21, 2015 Share Posted February 21, 2015 Yeah I mean, opening the debug console, checking the ajax response, you might get a specific error there Link to comment Share on other sites More sharing options...
ZMR Posted July 9, 2016 Share Posted July 9, 2016 Hello, This module is not working, it works without signing in, but when try to send email after signing in, I get this error- Your e-mail could not be sent. Please check the e-mail address and try again. I'm using latest version of the module. Please HELP!! Thank you so much in advance. Best Regards ZM Link to comment Share on other sites More sharing options...
NemoPS Posted July 29, 2016 Share Posted July 29, 2016 Turn on dev mode, see if you get any specific error in the network tab 1 Link to comment Share on other sites More sharing options...
ZMR Posted July 29, 2016 Share Posted July 29, 2016 Thanks for your reply! I'm a total newbie, could you please tell me how to turn on the dev mode? and where to look for the network tab? Thank you so much for your help! Link to comment Share on other sites More sharing options...
ZMR Posted August 5, 2016 Share Posted August 5, 2016 Thank you so much for your reply I've enabled the module, but nothing happened when I change settings in the Dashboard Goal module, no error is displayed after changing the settings, and the Dashboard Goal Module is still not showing any data for current year, and not saving any changes in the settings, just reset all values to 0 Link to comment Share on other sites More sharing options...
africanodama Posted October 16, 2016 Share Posted October 16, 2016 Hi. In my case "send to a friend" module send email when customer in NOT logged. When Log in module dont send email. Anybody? Link to comment Share on other sites More sharing options...
jodancer Posted October 31, 2016 Share Posted October 31, 2016 I also have a problem with this. Been 2 days of searching and applying suggested changes in numerous threads. I have tried also with the default theme and the same happens - Your e-mail could not be sent. Please check the e-mail address and try again. Maybe there is something in the server that is causing this, although I have a dedicated server with many sites sending form mails with no issues. If anyone could take a look, I'd be very grateful. mobiliariodecocinabarcelona.com/test/70cm-altura/27-morbi-turpis-metus.html Link to comment Share on other sites More sharing options...
Recommended Posts