Results 1 to 9 of 9
  1. #1
    Join Date
    Mar 2008
    Posts
    533
    Tokens
    0

    Default Creating an error message upon entering page.

    Hi, I have a little button on my website which says "bored?" where once clicked by somebody, they are taken to another page which as they enter, they get an error message containing whatever I put. Once they click OK, another one comes up. Similar to those on those Rick Astley sites.

    So my question is, how can I do this? I'm sure I've done it before, but cannot remember how. Thank you.

  2. #2
    Join Date
    Sep 2008
    Location
    UK
    Posts
    3,670
    Tokens
    0

    Latest Awards:

    Default

    Button page:
    HTML Code:
    <html>
    <head>
    <title>Stupid popups</title>
    </head>
    
    <body>
    
    <form method="post" action="stupidpopups.html">
    <input type="submit" value="Go">
    </form>
    
    <body>
    </html>
    Popup page:
    HTML Code:
    <html>
    <head>
    <title>Stupid popups</title>
    </head>
    
    <body>
    
    <script language="javascript">
    alert('Popup 1');
    </script>
    
    <script language="javascript">
    alert('Popup 2');
    </script>
    
    <script language="javascript">
    alert('Popup 3');
    </script>
    
    </body>
    </html>
    I think that will work but I haven't tested.
    Back for a while.

  3. #3
    Join Date
    Mar 2008
    Posts
    533
    Tokens
    0

    Default

    Thank you.

  4. #4
    Join Date
    Oct 2007
    Posts
    824
    Tokens
    71

    Latest Awards:

    Default

    If you want something like www.pgmr.co.uk/owned.php (you'll need to close it via task manager, pressing x won't work) then use this:

    http://www.habboxforum.com/showthrea...27#post5680827
    Last edited by Trigs; 16-03-2009 at 11:02 PM.
    Vouches
    [x][x]

  5. #5
    Join Date
    Mar 2008
    Location
    Swindon, UK
    Posts
    1,274
    Tokens
    187
    Habbo
    :Ltd

    Latest Awards:

    Default

    Quote Originally Posted by Excellent2 View Post
    Button page:
    HTML Code:
    <html>
    <head>
    <title>Stupid popups</title>
    </head>
    
    <body>
    
    <form method="post" action="stupidpopups.html">
    <input type="submit" value="Go">
    </form>
    
    <body>
    </html>
    Popup page:
    HTML Code:
    <html>
    <head>
    <title>Stupid popups</title>
    </head>
    
    <body>
    
    <script language="javascript">
    alert('Popup 1');
    </script>
    
    <script language="javascript">
    alert('Popup 2');
    </script>
    
    <script language="javascript">
    alert('Popup 3');
    </script>
    
    </body>
    </html>
    I think that will work but I haven't tested.
    Why would you keep going <script language="javascript">?

    Thats just pure stupidity. The script should be placed within the <head> element tags.
    HTML Code:
    <html>
    <head>
    <script type="text/javascript">
    function Bordem()
    {
        while( 1 == 1 )
        {
            alert( 'Boo hoo, ****.' );
        }
    }
    </script>
    
    </head>
    <body>
    <button onClick="Bordem();">Bored? Click here</button>
    </body>
    </html>
    Hi, names James. I am a web developer.

  6. #6
    Join Date
    Mar 2008
    Posts
    5,108
    Tokens
    3,780

    Latest Awards:

    Default

    He's excellent coder m8, he kno whut he doin! u gotta put all those script tags duh! but i aint tested it

  7. #7
    Join Date
    Mar 2008
    Location
    Swindon, UK
    Posts
    1,274
    Tokens
    187
    Habbo
    :Ltd

    Latest Awards:

    Default

    I totalii agree enit
    Last edited by Protege; 17-03-2009 at 11:29 AM.
    Hi, names James. I am a web developer.

  8. #8
    Join Date
    Nov 2005
    Location
    C:\Program Files\Lethal\Jak06
    Posts
    74
    Tokens
    0

    Default

    Could you not just use java script and try something like

    Code:
    function javascript_alert() {
    	
    	var message = "CHANGE THIS";
    	alert (message);
    }

  9. #9
    Join Date
    Mar 2008
    Location
    Swindon, UK
    Posts
    1,274
    Tokens
    187
    Habbo
    :Ltd

    Latest Awards:

    Default

    Once they click OK, another one comes up.

    And why would you remake a function that already exists

    alert( 'Message here' );

    didn't need all the other stuff.
    Hi, names James. I am a web developer.

Posting Permissions

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