简体   繁体   中英

How to protect a template locking it to a url

I'm building a costum wp theme that must be exclusive for a domain URL, what I want to do is lock the theme there, how can this be done ? I was thinking using PHP to check for the URL before including, lets say, the footer.php, and have that part of the code incripted, what do you think? is there a easier way?

What would that require? Looking at the server vars request? I guess I can google that, your opinion on the logic/algorithm would be very appreciated.

Warning, I'm not an advance coder.

Since it´s PHP and open source, you can´t. And even if you do, it´s possible to edit the source and remove the limitations.

The best thing you can do is to encrypt a part of source code with a license file. But even that way, this will make some parts of your theme impossible to change, and the base funcionality can skip the license check. A dead end.

I recommend you to take a look at a commercial template, andthe business model theme makers use to make it profitable.

You can find more, learning with other developers, try http://themeforest.net/

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM