Page 2 of 3 FirstFirst 123 LastLast
Results 11 to 20 of 25
  1. #11
    Join Date
    May 2006
    Location
    Gardiner, Maine
    Posts
    2,296
    Plugin Contributions
    22

    Default Re: JSON & TrustPilot

    i got we are in the conditional first and then no extra again when I changed the second.
    The full-time Zen Cart Guru. WizTech4ZC.com

  2. #12
    Join Date
    Nov 2005
    Location
    los angeles
    Posts
    2,684
    Plugin Contributions
    9

    Default Re: JSON & TrustPilot

    Quote Originally Posted by delia View Post
    i got we are in the conditional first and then no extra again when I changed the second.
    i'm sorry. i do not understand what you are saying here.

    as i wrote in a since deleted blog post, email is hard.

    i have tested the code above, and based on my tests, assuming we get inside the conditional, this does code work on my server.

    one thing i have noticed, is that if your bcc is the same as your to, in gmail, it looks like they will only deliver 1 email.

    if you want to test using my email address in the bcc, feel free. i will pm you my email address.

    if it does not work, we would have to look at the email logs on the server; as well as the version of phpMailer you are running. ZC156 looks to be running phpMailer 6.0.7. while ZC157 looks to be running 6.3.

    best.
    author of square Webpay.
    mxWorks has premium plugins. donations: venmo or paypal accepted.
    premium consistent excellent support. available for hire.

  3. #13
    Join Date
    May 2006
    Location
    Gardiner, Maine
    Posts
    2,296
    Plugin Contributions
    22

    Default Re: JSON & TrustPilot

    The first conditional did display in the logs - "we are in the conditional" but second did not.

    I just upgraded the phpmailer - lastest is 6.5. Still no joy

    And yes using a separate email address.
    The full-time Zen Cart Guru. WizTech4ZC.com

  4. #14
    Join Date
    Jul 2012
    Posts
    16,732
    Plugin Contributions
    17

    Default Re: JSON & TrustPilot

    Quote Originally Posted by delia View Post
    The first conditional did display in the logs - "we are in the conditional" but second did not.

    I just upgraded the phpmailer - lastest is 6.5. Still no joy

    And yes using a separate email address.
    For the email received/sent, what is the content in the subject of the email?
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  5. #15
    Join Date
    Nov 2005
    Location
    los angeles
    Posts
    2,684
    Plugin Contributions
    9

    Default Re: JSON & TrustPilot

    Quote Originally Posted by mc12345678 View Post
    For the email received/sent, what is the content in the subject of the email?
    hi mc,
    i'm currently exploring this problem further. to start with, this is a v156c install. the notifier parms have changed:

    looked at the includes/functions/functions_email.php. if we look at this line in v157:

    https://github.com/zencart/zencart/b...email.php#L283

    and compare it to the v156 version,

    https://github.com/zencart/zencart/b...email.php#L274

    you can see the v157 has 2 extra parameters added to it. one of which is the parameter we need.

    i think that's the only problem.

    best.
    author of square Webpay.
    mxWorks has premium plugins. donations: venmo or paypal accepted.
    premium consistent excellent support. available for hire.

  6. #16
    Join Date
    Jul 2012
    Posts
    16,732
    Plugin Contributions
    17

    Default Re: JSON & TrustPilot

    Quote Originally Posted by carlwhat View Post
    hi mc,
    i'm currently exploring this problem further. to start with, this is a v156c install. the notifier parms have changed:

    looked at the includes/functions/functions_email.php. if we look at this line in v157:

    https://github.com/zencart/zencart/b...email.php#L283

    and compare it to the v156 version,

    https://github.com/zencart/zencart/b...email.php#L274

    you can see the v157 has 2 extra parameters added to it. one of which is the parameter we need.

    i think that's the only problem.

    best.
    I was just going to identify based on similar review that likely need to be considering the notifier: NOTIFY_EMAIL_READY_TO_SEND
    As it is the first notifier that has $mail available for edit. Though the other question becomes does the vendor need the customer provided email only or does it need to receive the additional information that the admin can/does receive.

    While here, might as well update the earlier post about using the auto-loading observer. That option was added and has been available since and including Zen Cart 1.5.3. So the observer class used here could be of the auto-loading variety for this 1.5.6 site.
    Last edited by mc12345678; 2 Jul 2021 at 07:50 PM.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  7. #17
    Join Date
    Nov 2005
    Location
    los angeles
    Posts
    2,684
    Plugin Contributions
    9

    Default Re: JSON & TrustPilot

    Quote Originally Posted by mc12345678 View Post
    While here, might as well update the earlier post about using the auto-loading observer. That option was added and has been available since and including Zen Cart 1.5.3. So the observer class used here could be of the auto-loading variety for this 1.5.6 site.
    you are correct. i was thinking about the admin side of the autoloading observers. apparently that started in v157.

    i did not realize they started at different times.

    thanks for pointing that out.
    author of square Webpay.
    mxWorks has premium plugins. donations: venmo or paypal accepted.
    premium consistent excellent support. available for hire.

  8. #18
    Join Date
    Nov 2005
    Location
    los angeles
    Posts
    2,684
    Plugin Contributions
    9

    Default Re: JSON & TrustPilot

    Quote Originally Posted by mc12345678 View Post
    For the email received/sent, what is the content in the subject of the email?
    mc,
    i changed it to the other observer; i like that one and should have looked at that a little closer.

    in addition, this code needs to be changed:

    PHP Code:
    // from:
    if ((strpos($p2->subject'Order Confirmation') !== false) && (strpos($p2->subject'NEW ORDER') === false)) {
    //to:
    if ((strpos($p2->Subject'Order Confirmation') !== false) && (strpos($p2->Subject'NEW ORDER') === false)) { 
    capital S in Subject.

    surprised you missed that one!
    author of square Webpay.
    mxWorks has premium plugins. donations: venmo or paypal accepted.
    premium consistent excellent support. available for hire.

  9. #19
    Join Date
    Jul 2012
    Posts
    16,732
    Plugin Contributions
    17

    Default Re: JSON & TrustPilot

    Quote Originally Posted by carlwhat View Post
    mc,
    i changed it to the other observer; i like that one and should have looked at that a little closer.

    in addition, this code needs to be changed:

    PHP Code:
    // from:
    if ((strpos($p2->subject'Order Confirmation') !== false) && (strpos($p2->subject'NEW ORDER') === false)) {
    //to:
    if ((strpos($p2->Subject'Order Confirmation') !== false) && (strpos($p2->Subject'NEW ORDER') === false)) { 
    capital S in Subject.

    surprised you missed that one!
    I'm not :) I was still back on the what the subject line was expected to contain. :) wouldn't it be "better" to use or obtain the define that provides that text rather than entering the text specifically? (now thinking also of multi-language situation) of course would also want to try to account for the empty define condition, but in reality seems like would probably want to observe some other upstream action, set an internal observer variable and then check for that variable being set, take the action and possibly clear that variable if it is possible/desired to do the action again.

    In this way the above code is not dependent on content but intent. Just a thought. :) Would offer up a notifier if I had a better understanding of the action(s)/condition(s) expected to trigger this bcc condition and took a moment to look through the code.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  10. #20
    Join Date
    Nov 2005
    Location
    los angeles
    Posts
    2,684
    Plugin Contributions
    9

    Default Re: JSON & TrustPilot

    Quote Originally Posted by mc12345678 View Post
    I'm not :) I was still back on the what the subject line was expected to contain. :) wouldn't it be "better" to use or obtain the define that provides that text rather than entering the text specifically? (now thinking also of multi-language situation) of course would also want to try to account for the empty define condition, but in reality seems like would probably want to observe some other upstream action, set an internal observer variable and then check for that variable being set, take the action and possibly clear that variable if it is possible/desired to do the action again.

    In this way the above code is not dependent on content but intent. Just a thought. :) Would offer up a notifier if I had a better understanding of the action(s)/condition(s) expected to trigger this bcc condition and took a moment to look through the code.
    i thought about it.... but i was unsure if the define would be available (obviously i think it would be); but it is a 1 off, and i think hard coding in this situation is fine.

    setting an upstream internal observer var and then clearing it seems like a lot of work with potential for problems. but an interesting idea none-the-less. in fact, i did something similar here:

    https://www.zen-cart.com/downloads.php?do=file&id=2292

    so maybe not so much work. but interesting to think about.
    author of square Webpay.
    mxWorks has premium plugins. donations: venmo or paypal accepted.
    premium consistent excellent support. available for hire.

 

 
Page 2 of 3 FirstFirst 123 LastLast

Similar Threads

  1. v155 Did myISP upgraded my VPS and forgot to install json?
    By chibipaw in forum General Questions
    Replies: 2
    Last Post: 6 Jan 2020, 05:07 PM
  2. Unexpected token m in JSON at position 0
    By larrynhien in forum Templates, Stylesheets, Page Layout
    Replies: 8
    Last Post: 14 Sep 2016, 02:06 AM
  3. v155 JSON syntax error on shopping cart page
    By sports guy in forum General Questions
    Replies: 7
    Last Post: 9 Sep 2016, 10:17 PM
  4. json error with zc 1.5 eventhough json installed
    By bangsters in forum General Questions
    Replies: 4
    Last Post: 29 Feb 2012, 08:28 PM
  5. JSON undefined in internet explorer 6 and 7
    By lindanewbie in forum General Questions
    Replies: 1
    Last Post: 10 Mar 2011, 11:27 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR