1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

I Need help with my script.

Discussion in 'HTML & JavaScript' started by rap8557, Mar 17, 2014.

  1. rap8557

    rap8557 Jr. VIP Jr. VIP Premium Member

    Joined:
    Sep 15, 2008
    Messages:
    1,089
    Likes Received:
    436
    I can't figure it out how to implement my networks onclick locker.

    I'm lost can't figure it out.
    This is the code for the <head>
    Code:
    <script type="text/javascript">var lck = false;</script>
    <script type="text/javascript" src="https://www.cpagrip.com/script_include.php?id=63453"></script>
    <script type="text/javascript">if(!lck){top.location = 'http://lokhlp.com/disable_AdBlock.php'; }</script><noscript>Please enable JavaScript to access this page.<meta http-equiv="refresh" content="0;url=http://lokhlp.com/enable_javascript.php" /></noscript>
    This is the code to call the locker
    Code:
    onclick="call_locker();"
    How can i activate the locker on this?
    Code:
    var t2=setTimeout("document.getElementById('download').innerHTML='<a href=\"#\"> <div class=\"download-button\"> <p> Download </p> </div> </a>'",10700);
    The <div class="download-button"> does'nt have image
    Here's the code on the CSS
    Code:
    .download-button {
        background-color:#3ab2de;
        padding:10px;
        position:relative;
        width:150px;
        height:40px;
        font-family: 'Open Sans', sans-serif;
        font-size:16px;
        text-decoration:none;
        color:#fff;
        background-image: linear-gradient(bottom, rgb(100,170,30) 0%, rgb(129,212,51) 100%);
        box-shadow: inset 0px 1px 0px #7fd2f1, 0px 6px 0px #156785;
        border-radius: 5px;
    }
    
    .download-button:active {
        top:7px;
        background-image: linear-gradient(bottom, rgb(100,170,30) 100%, rgb(129,212,51) 0%);
        box-shadow: inset 0px 1px 0px #7fd2f1, inset 0px -1px 0px #156785;
        color: #156785;
        text-shadow: 0px 1px 1px rgba(255,255,255,0.3);
        background: rgb(44,160,202);
    }
    
    .download-button::before {
        background-color:#072239;
        content:"";
        display:block;
        position:absolute;
        width:100%;
        height:100%;
        padding-left:2px;
        padding-right:2px;
        padding-bottom:4px;
        left:-2px;
        top:5px;
        z-index:-1;
        border-radius: 6px;
        box-shadow: 0px 1px 0px #fff;
    }
    
    .download-button:active::before {
        top:-2px;
    }
    
    .download-button p {
    text-align:center;
    margin-top:10px;
    }
    Im not really good at coding, i just know some basics of it.
    Thanks :)
     
  2. Snckr

    Snckr BANNED BANNED

    Joined:
    Dec 27, 2013
    Messages:
    582
    Likes Received:
    381
    Thanks 4,294,967,295
    how. the. fuck.
     
  3. Snckr

    Snckr BANNED BANNED

    Joined:
    Dec 27, 2013
    Messages:
    582
    Likes Received:
    381
    <div id="your_custom_id"><a href="#" onClick="javascript:gLoad_19025(); return false;"><div id="your-custom-id"></div></a></div> That's how it would work.
     
    • Thanks Thanks x 1
  4. tomsko

    tomsko Regular Member

    Joined:
    Nov 2, 2012
    Messages:
    460
    Likes Received:
    269
    Occupation:
    IM
  5. evilclown

    evilclown Senior Member

    Joined:
    Jul 31, 2012
    Messages:
    805
    Likes Received:
    575
    Occupation:
    Party Clown
    Location:
    Clownville
    This:

    Code:
    var t2=setTimeout("document.getElementById('download').innerHTML='<a href=\"#\"> <div class=\"download-button\"> <p> Download </p> </div> </a>'",10700);
    
    make it:

    Code:
    var t2=setTimeout("document.getElementById('download').innerHTML='<a href=\"#\" onclick="call_locker();"> <div class=\"download-button\"> <p> Download </p> </div> </a>'",10700);
    
    The other part paste just above your </head> tag. Were google analytics is usually placed.

    --

    Why? He asked in the right section. I guess next time, if you don't know wtf the thread is about practice the go away in silence method. It always pays off good.

    That is some serious thanks!
     
    • Thanks Thanks x 2
    Last edited: Mar 17, 2014
  6. rap8557

    rap8557 Jr. VIP Jr. VIP Premium Member

    Joined:
    Sep 15, 2008
    Messages:
    1,089
    Likes Received:
    436
  7. rap8557

    rap8557 Jr. VIP Jr. VIP Premium Member

    Joined:
    Sep 15, 2008
    Messages:
    1,089
    Likes Received:
    436
    Didn't worked... the script also stops running
     
  8. rap8557

    rap8557 Jr. VIP Jr. VIP Premium Member

    Joined:
    Sep 15, 2008
    Messages:
    1,089
    Likes Received:
    436
    Same it didn't worked.. and the script stopped working.. :banghead:
     
  9. rap8557

    rap8557 Jr. VIP Jr. VIP Premium Member

    Joined:
    Sep 15, 2008
    Messages:
    1,089
    Likes Received:
    436
  10. evilclown

    evilclown Senior Member

    Joined:
    Jul 31, 2012
    Messages:
    805
    Likes Received:
    575
    Occupation:
    Party Clown
    Location:
    Clownville
    You need to add the other portion of the script to the header of your site. Use firebug to determine what is the issue.
     
  11. rap8557

    rap8557 Jr. VIP Jr. VIP Premium Member

    Joined:
    Sep 15, 2008
    Messages:
    1,089
    Likes Received:
    436
    Yes i did. The error was Uncaught SyntaxError: Unexpected identifier
     
  12. evilclown

    evilclown Senior Member

    Joined:
    Jul 31, 2012
    Messages:
    805
    Likes Received:
    575
    Occupation:
    Party Clown
    Location:
    Clownville
    That means the code is not right. If you want you can toss me a url over PM.
     
  13. evilclown

    evilclown Senior Member

    Joined:
    Jul 31, 2012
    Messages:
    805
    Likes Received:
    575
    Occupation:
    Party Clown
    Location:
    Clownville
    I check the code on your page. This line needs fixing:

    Code:
    [COLOR=#000000][FONT=monospace]var t2=setTimeout("document.getElementById('download').innerHTML='<a href=\"#\"> <div class=\"download-button\"> <p> Download </p> </div> </a>'",10700);[/FONT][/COLOR][COLOR=#000000][FONT=monospace]
    [/FONT][/COLOR]
    It needs to be like this:
    Code:
    [COLOR=#000000][FONT=monospace]var t2=setTimeout("document.getElementById('download').innerHTML='<a href=\"#\" onclick="call_locker();"> <div class=\"download-button\"> <p> Download </p> </div> </a>'",10700);[/FONT][/COLOR][COLOR=#000000][FONT=monospace]
    [/FONT][/COLOR]
     
  14. rap8557

    rap8557 Jr. VIP Jr. VIP Premium Member

    Joined:
    Sep 15, 2008
    Messages:
    1,089
    Likes Received:
    436
    Yeah i did that. Then it gave me the error then upload the original file again.
    Please check it again i've change the line...

    Can we talk on skype?
     
    Last edited: Mar 17, 2014
  15. amirov137

    amirov137 Registered Member

    Joined:
    Feb 26, 2014
    Messages:
    62
    Likes Received:
    0
    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