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

Convert iframe code to JS?

Discussion in 'Hire a Freelancer' started by azxster, Jul 25, 2011.

  1. azxster

    azxster Newbie

    Joined:
    Jul 8, 2011
    Messages:
    21
    Likes Received:
    1
    I have this iframe code that I place on publishers' websites

    Code:
    <iframe width="160" height="600" frameborder=0 scrolling='no'
    src=mywebsite></iframe>
    
    where mywebsite hosts my advertiser's javascript.

    I need someone to convert this iframe tag into a javascript tag.
     
  2. bzy39

    bzy39 Regular Member

    Joined:
    Jan 15, 2009
    Messages:
    434
    Likes Received:
    239
    you can try with document.write function... to write the iframe via javascript...
     
  3. zelma143

    zelma143 Power Member

    Joined:
    Jun 25, 2010
    Messages:
    571
    Likes Received:
    37
    Occupation:
    PHP programmer,Bot maker,iMacro script maker
    Just echo it out. in the ifram.js file, something like:-
    document.write('<iframe frameborder="0" scrolling="no" height="300" width="300" name="myFrame" src="yoursite"></iframe>');
    Then in the HTML page:-
    <script language="javascript" src="http://www.example.com/ifram.js"></script>


    that's it
     
  4. azxster

    azxster Newbie

    Joined:
    Jul 8, 2011
    Messages:
    21
    Likes Received:
    1
    Thanks guys!

    Is there a way to "mask" the source of my script and the code of the script. I know you can't hide it because if it's hidden, then users wouldn't be able to run the script. I want to make it harder for people to know I'm using an iframe and/or my advertiser.
     
  5. meannn

    meannn Supreme Member

    Joined:
    Apr 22, 2009
    Messages:
    1,461
    Likes Received:
    1,896
    Occupation:
    Unemployed Winner
    Location:
    TR
    If you don't want to show iframe code in source, encrypt your html code here > smartgb.com/free_encrypthtml.php