• Resolved thademorrow

    (@thademorrow)


    Hello again.

    Are there any disadvantages to (or reasons not to use) the javascript version of this plugin? I really like the way the javascript version looks but am not sure if there are any reasons not to use it – other than some browsers not supporting javascript.

    Thank you for your help with this.

    Best,
    Tyler.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Phil

    (@philsbury)

    Hi (again :))

    There’s no real reason not to, and only minor disadvantages to using it.

    A bit of background as a whole to the plugin, when I first wrote v1 I wanted savvy users to not be able to see content at all, so I replace the theme file with the age gate so it’s the physical output of the page (not right clicking and removing it!). The JavaScript mode came in in v1.4 for people who had caching in place and the original concept got them stuck in a loop.

    So, draw back one of the JavaScript version is if someone really wanted to, they could just inspect and remove it on every page. I don’t really think people would – their more likely to just lie about their age!

    From a technical standpoint there is one potential drawback if you are doing any filters before showing the age gate. In “normal mode” this can all happen before we output anything to the page, but in JavaScript, it makes an AJAX call first, then shows the page. This can cause a slight delay between page load and showing the age gate, especially if its a heavy process on the server side, or the server is slow.

    There’s a bit of info on this kind of process on the documentation.

    For most people, this won’t be an issue.

    Lastly as you point out, if the browser doesn’t support JS, or has it switched off then the age gate won’t show. I think with things like React/Angular and so on those cases are becoming less of an issue, but certain could happen.

    Hope that all helps!

    Cheers
    Phil

    Thread Starter thademorrow

    (@thademorrow)

    Phil, thanks again for the informative response.

    I have known of people getting past pay-walls and the like using the method you described ?? I am not overly concerned about that for my website. I just wanted to make sure there weren’t any other concerns to look out for.

    Take care.

    Best Regards
    Tyler.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Disadvantages to the Javascript version?’ is closed to new replies.