Jump to content

[solved] send to a friend module is not working!


Recommended Posts

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

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 by mojtabam (see edit history)
Link to comment
Share on other sites

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}

  • Like 1
Link to comment
Share on other sites

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

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

  • 2 weeks later...

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

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

  • 3 weeks later...
  • 1 month later...
  • 2 weeks later...
  • 4 weeks later...
  • 2 weeks later...
  • 3 weeks later...

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

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

post-716409-0-68764400-1381830635_thumb.png

Edited by rhleite (see edit history)
Link to comment
Share on other sites

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

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 by rhleite (see edit history)
Link to comment
Share on other sites

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

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

  • 5 weeks later...

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

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

  • 2 weeks later...

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

  • 2 weeks later...

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

  • 2 weeks later...

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

  • 3 months later...
  • 10 months later...

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

 

post-470042-0-83948300-1424117456_thumb.jpg

 

Edited by thelaptopdude (see edit history)
Link to comment
Share on other sites

  • 1 year later...

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

  • 3 weeks later...

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

  • 2 months later...
  • 2 weeks later...

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

×
×
  • Create New...