Jump to content

Licensing addon question


kannan

Recommended Posts

Hi,

 

I have created licensing product and license key.

 

In documentation you have mentioned

 

"Now retrieve the license key and local key from the database or file storage you have saved them in " on 5th point.

 

but i have only the license key in database .so where the local key is stored .

or from where i will get the local key?

also,

 

In check_sample_code.php file you have mentioned

 

$licensing_secret_key = "abc123"; # Set to unique value of chars

 

shall i mentioned any value in the above $licensing_secret_key variable.?

 

for eg: $licensing_secret_key="abcdefgh";

 

can you please explain how to validate the domain?

 

for eg:

 

I had given my licensing product to the user domain http://www.first.com,

 

nobody can not use the product other than the http://www.first.com,

 

for that how to customize the given check_sample_code.php

 

please give me the solution.

 

 

Thanks in advance,

kannan

Link to comment
Share on other sites

  • 1 month later...

Hi,

 

I'm also at a loss here. It seems that all licensing s/w out there have the same thing in common. They think all of us some sort of pre knowledge about integration on licensing.

 

I read through all the wiki, sample code and searched forums to find nothing. Absolutely nothing that can help a 1st time starter.

 

I'm building a theme for DirectAdmin and would like to integrate this to the theme. But i still don't know hoe to do it.

 

how do you input the values for localkey, licensekey? where do i store the localkey? How do i retrieve them?

Link to comment
Share on other sites

  • WHMCS CEO

You're right in a way. It is expected that because you're building an app to sell and distribute that you would be familiar with basic coding somewhat. The sample code is commented with things like below to instruct you where and what to add though:

 

# Get Variables from storage (retrieve from wherever it's stored - DB, file, etc...)
# The call below actually performs the license check. You need to pass in the license key and the local key data
# Save Updated Local Key to DB or File
# Show Invalid Message

 

Whether you store the license key and local key in a database or flat file is up to you and the architecture of your application. In your case it sounds like you wouldn't have a DB given that it's just a theme so you would probably want to use a flat file. In our case we use the database. For that reason it's left flexible and up to the user to use whichever suits best adding either sql queries or reading/writing to a file.

 

Matt

Link to comment
Share on other sites

Thanks for clearing this upto me. Since i'm not someone who built the application and since the theme i'm building is not built from scratch and my programming skills are not at par with many of you (Yuk i hate programming by the way ;) ) could you give small step by step guide?

 

I know now i have to use a flat file. now i need to know how i can store the data that i entered via a textbox. well there are a lot of questions actually, but i'll try to sort them out somehow.

Link to comment
Share on other sites

  • 6 months later...
  • 4 months later...

Yes did you ever find a solution to this, I am familiar with some light php but would like a guide to help, it was a bit more complex than expected but I will give it a shot tonight with or without a tutorial and if I am successful I will write some sort of tutorial, but don't expect me to be successful.

Link to comment
Share on other sites

  • 6 months later...

I am two questions related to LICENSING

1.) Why i need to store the localkey ,why can't I just enter it into the php file directly at once

2.) Since Check file will be stored in the client server .we can't run it everytime.So how to run this once in a month/day, to check the license.

 

Please advise me.

Is there any guide available to sort this.

I hope this post is too old and someone have answer for this.

 

Thanks,

vetrib2w

Link to comment
Share on other sites

  • 1 month later...

Same here. I'm trying to do something but the "documentation" is very far to be clear. The question is not "you are supposed to be skilled with php". The only way to understand your code is with reverse engineering. I mean 180 lines with a couple of comments is not enough to understand how we can include your script in our php files. A sample with WHMCS database connection would be great.

Link to comment
Share on other sites

My developer knows C# and had difficulty implementing code corresponding to the PHP sample code. I hired a PHP/C# contractor that had the right experience to do it quite easily. Also Matt has been very helpful through support email in clarifying a number of aspects. I expect to have things working by tomorrow.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated