The Foxy forums are on the move!

We're in the process of moving our forums over to a new system, and so these forums are now read-only.
If you have a question about your store in the meantime, please don't hesitate to reach out to us via email.

Modx & HMAC

2»
Comments
  • Absolutely works!

    Just create a plugin bound to OnWebPagePrerender event:
    <?php

    $e = &$modx->event;
    switch ($e->name) {
    case 'OnWebPagePrerender':
    include 'path/to/foxycart.cart_validation.php';
    $modx->resource->_output = FoxyCart_Helper::fc_hash_html($modx->resource->_output);
    break;
    }

    return;
    If you want, you can even check MODX Template or Resource IDs, etc, to ensure output is only parsed on necessary pages.
  • fc_adamfc_adam FoxyCart Team
    edited February 2016
    @ysanmiguel,

    Unfortunately I'm not aware of anyone having developed an integration for ModX Revo - but I'll check in with the team and see if someone else is aware of one. Or hopefully someone in the community will chime in too!

    [edit] @pixelchutes - thanks for posting that! Didn't see your post when I added mine.
  • @ysanmiguel can you provide a little more information. What version of MODX Revo and what version of Foxycart are you using? We recently inherited a site running on MODX Revo using Foxycart 1.1 that was using HMAC setup by the previous development team. I think we left the code alone, but the site is now running on Foxycart 2.0 and we're not using the HMAC approach anymore.
  • ysanmiguelysanmiguel Member
    edited February 2016
    SOLVED HMAC Product Verification on Modx Revo 2.4.2-pl ;D
    Thank you everyone for the answers.

    @pixelchutes mate, everything works perfect with that code, thank you very much!!!!

    If someone else have the same problem read the @pixelchutes post: https://forum.foxycart.com/discussion/comment/54748/#Comment_54748
  • Awesome! Glad that's working for you now, @ysanmiguel
  • Thanks also @Pixelchutes. I came across your MODX Revolution code and it worked like a charm.
Sign In or Register to comment.