Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 10 of 10
  1. #1
    Regular Coder
    Join Date
    Jan 2003
    Posts
    400
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Completely customizable alert Boxes!!

    Okay, I thought up this script when I was working on a website that acted as a cell phone. I did take a little coding outta brothercakes frogger script. If you dont want me to have this up here, just let me know. But here it is:

    Code:
    function alert(msg)
    {
       alObj=document.createElement("div");
       document.body.appendChild(alObj);
    
       alData='<table cellpadding="0" cellspacing="0" border="0"     style="width:25%;height:10%;position:absolute;left:355;top:180;z-index:1;"><tr><td align="center" valign="middle">'
       alData+='<table cellpadding="0" cellspacing="12" border="0" style="-moz-box-sizing:border-box;font:15px comic sans  ms,arial;color:#1d4fa8;font-weight:bold;background-color:#f4f887;border:1px solid #1d4fa8;width:250px;filter:progid:DXImageTransform.Microsoft.Shadow(color=#1d4fa8,direction=135,strength=5);">'
      alData+='<tr>';
      alData+='<td align="center">'+msg+'</td>';
      alData+='</tr>';
      alData+='<tr>';
      alData+='<td align="center"><input type="button" onClick="clal()" value="Ok" style="border:1px inset #1d4fa8;background:#f4f887;color:#1d4fa8;font-weight:bold;height:20;">';
      alData+='</tr>';
      alData+='</table>';
      alData+='</td></tr></table>';
    
      alObj.innerHTML = alData;
    
    }
    
    function clal()
    {
      document.body.removeChild(alObj);
      alObj=null;
    }
    You can edit it however you want to.

    To get it working, all you have to do is create a link or something like this:
    Code:
    <a href="javascript:alert('Hello! How are you?')">Greetings</a>
    and the alert will come up as any other kind!
    Last edited by l3vi; 04-15-2004 at 03:58 AM.

  • #2
    Regular Coder Skyzyx's Avatar
    Join Date
    Aug 2002
    Location
    Silicon Valley, CA
    Posts
    980
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Is it cross-browser? Is it supported by the standards-compliant Netscape 6+, Mozilla, Phoenix, Chimera, Galeon, AOL 7 for Mac OS X, CompuServe 7, Opera 7, Konqueror, or Safari? Or is it only for Internet Explorer, MSN Explorer, or AOL for Windows?

    Creator of SimplePie and Tarzan AWS, co-founder of WarpShare, co-built the Y! Messenger website, usability-focused, and an INFJ personality.

  • #3
    Regular Coder
    Join Date
    Jan 2003
    Posts
    400
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Originally posted by Skyzyx
    Is it cross-browser? Is it supported by the standards-compliant Netscape 6+, Mozilla, Phoenix, Chimera, Galeon, AOL 7 for Mac OS X, CompuServe 7, Opera 7, Konqueror, or Safari? Or is it only for Internet Explorer, MSN Explorer, or AOL for Windows?
    Im not really sure. It might be. Sorry I cant tell ya Im pretty sure it is though.

  • #4
    New to the CF scene
    Join Date
    Feb 2003
    Location
    USA
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I don't really know a whole lot about this stuff...but where exactly do i put the java link thingy at?
    Attached Images Attached Images  

  • #5
    Regular Coder Skyzyx's Avatar
    Join Date
    Aug 2002
    Location
    Silicon Valley, CA
    Posts
    980
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I'm sorry... sarcasm doesn't transmit well over the internet. I meant to say "This is NOT a crossbrowser script, so don't use it unless you are designing webpages that will only be viewed by people with Internet Explorer, because it won't work with any other browser."

    Creator of SimplePie and Tarzan AWS, co-founder of WarpShare, co-built the Y! Messenger website, usability-focused, and an INFJ personality.

  • #6
    Regular Coder
    Join Date
    Nov 2002
    Location
    Carmel California
    Posts
    471
    Thanks
    0
    Thanked 1 Time in 1 Post
    Is it cross-browser? Is it supported by the standards-compliant Netscape 6+, Mozilla, Phoenix, Chimera, Galeon, AOL 7 for Mac OS X, CompuServe 7, Opera 7, Konqueror, or Safari? Or is it only for Internet Explorer, MSN Explorer, or AOL for Windows?
    1. Chimera, Galeon, Safari, standards??????? never even heard of those!!! probobly only like .1% of people use any of them

    ps. aol 8 for windows uses mozilla
    Kris Hubby
    kwhubby site

  • #7
    Regular Coder Skyzyx's Avatar
    Join Date
    Aug 2002
    Location
    Silicon Valley, CA
    Posts
    980
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Actually, I've done some testing with AOL 8, and read the information straight from AOL. AOL 8 for Windows still uses the IE engine. They were planning the changeover for AOL 8, but it has been pushed back to AOL 9.

    You've never heard of standards?! www.w3.org is the group that decides the standards. Most of those other browsers I pointed out are based on the Gecko engine... same as Netscape 6 and 7. They make up far more of a market share than 0.1%. Don't believe too much of the propaganda that Microsoft feeds you...

    I used to use Internet Explorer exclusively too... until the day I discovered Mozilla. I installed it, set it to load on startup, made it my default browser, and haven't ever looked back... perhaps you should give it a try before you flame it... www.mozilla.org .
    Last edited by Skyzyx; 02-24-2003 at 03:48 PM.

    Creator of SimplePie and Tarzan AWS, co-founder of WarpShare, co-built the Y! Messenger website, usability-focused, and an INFJ personality.

  • #8
    Regular Coder
    Join Date
    Nov 2002
    Location
    Carmel California
    Posts
    471
    Thanks
    0
    Thanked 1 Time in 1 Post
    i do, and I like some of the added features and such, yet i am used to ie, and like its less strict parsing, and i am used to its support of stuff like document.all, and other ie only stuff. And whenever I make something even if I don't use document.all Its always first compatible with ie, and then as an after thought I work to maby get it mozilla compatible.

    as of standards, I never mentioned gecko, I just said I never heard of Chimera, Galeon, and Safari (i did just hear of safari though)
    ive heard of gecko!

    edit: aol 8 is ie LOL!!!!! god, even the personel of aol say its mozilla.
    ( i don't use aol, i just had acess to "im" with some aol help guy)
    Kris Hubby
    kwhubby site

  • #9
    Senior Coder
    Join Date
    Jun 2002
    Location
    ColoRockyz
    Posts
    1,646
    Thanks
    1
    Thanked 0 Times in 0 Posts
    Originally posted by Skyzyx
    Is it cross-browser? Is it supported by the standards-compliant Netscape 6+, Mozilla, Phoenix, Chimera, Galeon, AOL 7 for Mac OS X, CompuServe 7, Opera 7, Konqueror, or Safari? Or is it only for Internet Explorer, MSN Explorer, or AOL for Windows?
    ...and what about the new Zoobie browser?

    PS - My g/f would beat you up and sit on you 'till you cried for having that sig.
    Zoobie or not Zoobie...That is the problem.
    <body onUnload="flush( ! )">

  • #10
    Regular Coder Skyzyx's Avatar
    Join Date
    Aug 2002
    Location
    Silicon Valley, CA
    Posts
    980
    Thanks
    0
    Thanked 0 Times in 0 Posts
    You need to read the old Calvin and Hobbes comic strips. They're my heroes!

    Creator of SimplePie and Tarzan AWS, co-founder of WarpShare, co-built the Y! Messenger website, usability-focused, and an INFJ personality.


  •  

    Posting Permissions

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