Solved

Need to restrict access to my site

Posted on 2016-09-05
4
68 Views
Last Modified: 2016-09-06
I have two site upcoming. The first shows three online playing cards as a demo of my paid service, and is free to use. Once they have purchased a license on PayPal, they will have access to the 54 online playing card version.

The game has no back end, as far as I know. The questions, hints and answers are CSS, as far as I know.

I have an underlying WordPress site where users can optionally log in and orders can only be placed by registered users. So I suppose I can provide this site only to logged in users who have also purchased this license.

How do I do this with WordPress? I also use WooCommerce as my storefront.

I need to block non-licensed users...

Thanks
0
Comment
Question by:newbieweb
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 1

Assisted Solution

by:Stefan Hoffmann
Stefan Hoffmann earned 125 total points
ID: 41785581
I'd do it through a page template. You can modify those. Copy one and add source code so that the content is only shown if the user has a licence.

PS: It is very unlikely that the game only consists of css.
0
 
LVL 57

Accepted Solution

by:
Julian Hansen earned 250 total points
ID: 41785628
I am guessing the game runs off javascript. So I would make the javascript load through a php call
<script src="getscript.php"></script>

Open in new window


getscript.php checks to see if the user has registered and then returns the real library otherwise it returns a javascript file that redirects back to the demo page.

You then just need a simple login page that checks the users credentials and sets a cookie that is used by getscript.php to check the users registration status.
0
 
LVL 110

Assisted Solution

by:Ray Paseur
Ray Paseur earned 125 total points
ID: 41785889
This expert suggested creating a Gigs project.
You may need a professional developer to help you with this.  E-Commerce applications usually require some advanced development techniques.  Consider E-E Gigs.

There are some links and ideas in the WP forums, and maybe something in the codex.  Have a look around there.  Here is one example.
https://wordpress.org/support/topic/how-to-make-woocommerce-shop-page-password-protected-1/
0
 

Author Closing Comment

by:newbieweb
ID: 41786069
thanks
0

Featured Post

Report: Liquid Web beats Amazon, Rackspace & More

A study by performance analyst firm Cloud Spectator finds that Liquid Web beats rivals Amazon, Rackspace and DigitalOcean when it comes to website and cloud application performance.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Does your audience prefer people in photos or no people? How can you best highlight what you’re selling? What are your competitors doing, and what can you do that is different and unique from them?  Continue reading to learn how to make your images …
Australian government abolished Visa 457 earlier this April and this article describes how this decision might affect Australian IT scene and IT experts.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
The viewer will get a basic understanding of what section 508 compliance can entail, learn about skip navigation links, alt text, transcripts, and font size controls.

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question