CPAgrip, wordpress, and content locking

uncommon

Newbie
Joined
Dec 23, 2013
Messages
34
Reaction score
2
So I'm stuck with integrating this code into my wp theme. I have a one page landing page theme. I want to use the content locker feature of CPAgrip to lock specific buttons.

They gave me some code that I'm unfamiliar with. I believe I've put the javascript they provided in the proper location in the header.php file. However, there is a second part of the code that I'm unsure with.

The code is:

onclick="call_locker();"

I'm not sure but I think I need to wrap the code I want locked. Is that the case? If so, then I need to wrap the buttons I want locked?

However, I'm not sure how to go about finding the write code to wrap or even if I'm on the write path. Any suggestions? I'm not a coder. Google is my best friend when it comes to this side of wp. I'm getting better but taking time.
 
Onclick is a JavaScript function so you would attach it to the button id you want protectified. So say to have <input id="yourmom" > or <div id="yourmom">, you would attach that on click function to #yourmom. Its hard to tell without the actual snippet but that's the idea.

Edit: forgot to mention your button will be inside of the div or it will be the input tag.
 
Onclick is a JavaScript function so you would attach it to the button id you want protectified. So say to have <input id="yourmom" > or <div id="yourmom">, you would attach that on click function to #yourmom. Its hard to tell without the actual snippet but that's the idea.

Edit: forgot to mention your button will be inside of the div or it will be the input tag.
How is the code going to be inserted?
 
someone got any answers of this ?? i'm trying to lock image linked to download site but the offers popups and directed locked site in the same time
 
Basic example:
Code:
<button onclick="call_locker()">Click me</button>

You insert the code they gave you inside the clickable element's tag.
 
Last edited:
Back
Top