Discover Habbo's history
Treat yourself with a Secret Santa gift.... of a random Wiki page for you to start exploring Habbo's history!
Happy holidays!
Celebrate with us at Habbox on the hotel, on our Forum and right here!
Join Habbox!
One of us! One of us! Click here to see the roles you could take as part of the Habbox community!


Page 2 of 3 FirstFirst 123 LastLast
Results 11 to 20 of 25

Thread: Button coding?

  1. #11
    Join Date
    May 2006
    Posts
    1,797
    Tokens
    0

    Latest Awards:

    Default

    use Smifflas method but add an onclick="popUp("lol.htm");" to your button instead of the <a href> bit.
    Coming and going...
    Highers are getting the better of me

  2. #12
    Join Date
    Dec 2007
    Posts
    2,807
    Tokens
    0

    Latest Awards:

    Default

    Quote Originally Posted by MrCraig View Post
    use Smifflas method but add an onclick="popUp("lol.htm");" to your button instead of the <a href> bit.
    So what would be the code I would put instead? Im crap at HTML JS etc

  3. #13
    Join Date
    Dec 2007
    Posts
    1,683
    Tokens
    0

    Latest Awards:

    Default

    Add onclick="popUp("lol.htm");"

    to the end of your button, E.G: <button script="somethingjustusingthistofillspaceetc" onclick="popUp("lol.htm");">
    Last edited by Independent; 21-02-2008 at 12:10 PM.

  4. #14
    Join Date
    Dec 2006
    Location
    Swindon
    Posts
    3,299
    Tokens
    215
    Habbo
    dunko

    Latest Awards:

    Default

    Or use

    <a href="lol.html" onclick="popUp('lol.htm') return false;">Button Code</a>

  5. #15
    Join Date
    Apr 2006
    Location
    London, England
    Posts
    696
    Tokens
    0

    Default

    heres an easier way

    <a href="#" onClick="chw=window.open('file.html','NewWindow',' resizable=no,scrollbars=yes,status=no,width=900,he ight=440'); if (chw != null) chw.focus(); return false"> BUTTON </a>

    If you dont wish it to scroll just change scrollbars to no
    Last edited by DUB; 21-02-2008 at 05:18 PM.
    ;veni vidi vici
    ;i came, i saw, i ownt

  6. #16
    Join Date
    Dec 2007
    Posts
    1,683
    Tokens
    0

    Latest Awards:

    Default

    Quote Originally Posted by Blob View Post
    Or use

    <a href="lol.html" onclick="popUp('lol.htm') return false;">Button Code</a>
    Quote Originally Posted by DUB View Post
    heres an easier way

    <a href="#" onClick="chw=window.open('file.html','NewWindow',' resizable=no,scrollbars=yes,status=no,width=900,he ight=440'); if (chw != null) chw.focus(); return false"> BUTTON </a>

    If you dont wish it to scroll just change scrollbars to no
    I was answering the question to MrCraig's one, but hey.. Fair enough looks a lot better code in an a thing.

  7. #17
    Join Date
    Dec 2007
    Posts
    2,807
    Tokens
    0

    Latest Awards:

    Default

    Quote Originally Posted by Blob View Post
    Or use

    <a href="lol.html" onclick="popUp('lol.htm') return false;">Button Code</a>
    What do I put for 'the button code'? As I said I really am a n00b

  8. #18
    Join Date
    May 2006
    Posts
    1,797
    Tokens
    0

    Latest Awards:

    Default

    hm i can never remember window.open javascript parameters tbh

    EDIT:

    In head:
    Code:
    <script language="JavaScript">
    function popUpWindow(URL) {
    day = new Date();
    id = day.getTime();
    eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=900,height=440');");
    }
    </script>
    For your button
    Code:
    <input type="button" value="Button Text" onclick="popUp("lol.html");" />
    Try that
    Last edited by MrCraig; 21-02-2008 at 05:26 PM.
    Coming and going...
    Highers are getting the better of me

  9. #19
    Join Date
    Apr 2006
    Location
    London, England
    Posts
    696
    Tokens
    0

    Default

    Quote Originally Posted by Mythim View Post
    What do I put for 'the button code'? As I said I really am a n00b

    <a href="#" onClick="chw=window.open('file.html','NewWindow',' resizable=no,scrollbars=yes,status=no,width=900,he ight=440'); if (chw != null) chw.focus(); return false"> <img src="linktobuttonimage" border="0" /> </a>

    Mine or what craig said above do basically the same thing
    Last edited by DUB; 21-02-2008 at 05:30 PM.
    ;veni vidi vici
    ;i came, i saw, i ownt

  10. #20
    Join Date
    May 2006
    Posts
    1,797
    Tokens
    0

    Latest Awards:

    Default

    Yeah, only diff is i use an actual button as opposed to a button image..
    Coming and going...
    Highers are getting the better of me

Page 2 of 3 FirstFirst 123 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •