Tips and Tricks HQ Support

Support site for Tips and Tricks HQ premium products

  • Home
  • Contact Us
  • Documentation
  • Forum Home
    • Forum
    • Forum Search
    • Forum Login
    • Forum Registration

eStore APR code doesn't work

by

Tips and Tricks HQ Support Portal › Forums › WP eStore Forum › eStore APR code doesn't work

Tagged: APR, APRTP, cookie

  • This topic has 22 replies, 3 voices, and was last updated 11 years, 2 months ago by wzp.
Viewing 15 posts - 1 through 15 (of 23 total)
1 2 →
  • Author
    Posts
  • January 3, 2014 at 8:41 pm #10350
    erickres
    Member

    I have read all previous posts and watch the tutorial video, but still having problem.

    In this page:

    [http://marten.arvixe.com/~erickres/testvid/]

    I have this code:

    [wp_eStore_APR expiry=0 status=unexpired]

    Now you see me!

    [/wp_eStore_APR]

    I have added a product with the digital product url as: [aprtp://marten.arvixe.com/~erickres/testvid/]

    No matter what I do, I cannot see the hidden content.

    January 3, 2014 at 9:55 pm #60098
    wzp
    Moderator

    Could you please enable the debug logs, try your test again, and then post the content of the download_manager_debug.log file?

    Now, if you’d also checkout this thread:

    https://support.tipsandtricks-hq.com/forums/topic/estore-apr-page-admin-encrypted-link-content-between-shortcode-is-hidden

    You’ll see in my posts, that WP was automagically adding a trailing slash to the permalink. I’ll bet the product URI in your eStore database does not have a trailing slash.

    I’m pretty sure this is the problem, because every time I enter a URL for your site without a trailing slash, your site automagially adds one. 8)

    January 3, 2014 at 11:40 pm #60099
    erickres
    Member

    I actually did try with and without the ‘/’, I wasn’t sure what I should do, but it didn’t work in any case.

    So should it be “aprtp://marten.arvixe.com/~erickres/testvid/” or “aprtp://marten.arvixe.com/~erickres/testvid”?

    I will get the debug logs and post it soon.

    Thanks

    January 3, 2014 at 11:42 pm #60100
    wzp
    Moderator

    Because you had setup the permalinks on WP to add the trailing slash, the APRTP URI should have the trailing slash as well.

    January 4, 2014 at 12:00 am #60101
    wzp
    Moderator

    Okay, I think I see the problem…

    [01/03/2014 11:47 PM] – Status : Dispatching APRTP URL = [http://marten.arvixe.com/%7Eerickres/testvid/]

    [01/03/2014 11:47 PM] – Status : Authenticating APR request for: [http://marten.arvixe.com/~erickres/testvid/]

    [01/03/2014 11:47 PM] – Status : $_COOKIE[1b2b79c29b70a2f3c1a5da283914075d] not found.

    When the APRTP link is dispatched, the tilde “~” is translated into a “%7E” which of course is correct.

    But when the APR shortcode is invoked, the tilde is not converted into a “%7E” which when run through the validation will not match the original cookie.

    Please try renaming the permalink to something without the tilde, reset the logs, and try the test again.

    January 4, 2014 at 12:07 am #60102
    erickres
    Member

    I cannot get rid of the ‘~’ at this point.

    I am building a new site for a domain that is currently being used. So I have to use this temp address which I get from the hosting supplier.

    The part “http://marten.arvixe.com/~erickres/” is a given to me.

    This is only temporary, but I do want to test it all before running live. Any other options you think of?

    January 4, 2014 at 12:21 am #60103
    wzp
    Moderator

    The APR mechanism is meant to be RFC-1738 compliant. That is why the tilde in your product URI is converted into a “%7E” encoded character.

    Some newer browsers however, follow the more relaxed RFC-2396, which says it’s okay to not encode tildes. So, when one of these browsers returns the URL back to eStore, the tilde is unencoded; thereby causing the cookie mismatch issue.

    I could adjust the code, but it might cause eStore to become browser dependent.

    January 4, 2014 at 12:25 am #60104
    erickres
    Member

    I understand the problem. I am just looking for a temporary solution for my testing before going live.

    Do you think some kind of “short link” should work?

    When you say you can adjust the code, is it something simple that can be implemented just temporary and be reverted back before going live? Is it a piece of code that I can get from you and modify one of the files?

    January 4, 2014 at 12:27 am #60105
    wzp
    Moderator

    That will not work, because the “Authorizing APR request for:” URL creates a unique cookie. When the shortcode is invoked, the “Authenticating APR request for:” URL must ***EXACTLY*** match the URL previously authorized.

    January 4, 2014 at 12:28 am #60106
    wzp
    Moderator

    That’s what makes the system so secure, LOL.

    January 4, 2014 at 12:30 am #60107
    erickres
    Member

    So any thoughts about a temporary code adjustments?

    January 4, 2014 at 12:31 am #60108
    wzp
    Moderator

    No promises, but I will look into a “running with scissors” hack you can try.

    January 4, 2014 at 12:34 am #60109
    erickres
    Member

    Thanks!

    I have another wordpress empty site that I’ve used to experiment on, it has a proper domain name. I guess that another option would be to install the eStore there and test this function there, then copy the page to the current site. I would prefer to avoid this if possible.

    January 4, 2014 at 12:47 am #60110
    wzp
    Moderator

    The licensing for eStore allows this.

    January 4, 2014 at 12:48 am #60111
    erickres
    Member

    Well, I will do it just to do some testing, not permanently.

    But I’d wait for your fix first.

  • Author
    Posts
Viewing 15 posts - 1 through 15 (of 23 total)
1 2 →
  • You must be logged in to reply to this topic.
Log In

Forum Related

  • Forum Home
  • Forum Search
  • Forum Registration
  • Forum Login

Support Related Forms

  • Contact Us
  • Customer Support
  • Request a Plugin Update
  • Request Fresh Download Links

Useful Links

  • Plugin Upgrade Instructions
  • WP eStore Documentation
  • WP eMember Documentation
  • WP Affiliate Platform Documentation
  • Tips and Tricks HQ Home Page
  • Our Projects

Quick Setup Video Tutorials

  • WP eStore Video Tutorial
  • WP eMember Video Tutorial
  • WP Affiliate Platform Video Tutorial
  • Lightbox Ultimate Video Tutorial

Our Other Plugins

  • WP Express Checkout
  • Stripe Payments Plugin
  • Simple Shopping Cart Plugin
  • Simple Download Monitor

Copyright © 2025 | Tips and Tricks HQ