Jump to content

Jonas

Members
  • Posts

    2,402
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by Jonas

  1. I'm sorry, could you describe your problem in more detail. That is to say, any detail at all would be of great help...
  2. Black to pink to black?orWhite to pink to white?
  3. Jonas

    ???

    Here's a site I made, using nested tables layout. I tried it with divs, but they wouldn't extend down with the text...Oh, and the displays best in Opera thing, is because I don't like the borders on firefox and IE's way of building the border on the outside of the element...
  4. Jonas

    scroll text

    No! No! Don't encourage the use of the <marquee> tag...
  5. In IE and Opera, it just says "initializing..."
  6. Jonas

    ???

    http://validator.w3.org/check?uri=http://www.iribbit.net/Yay! :)And no problem. Glad to be of help...
  7. Jonas

    ???

    a) Try lowercase letters: onMouseOver --> onmouseoveronMouseOut --> onmouseout:) I suppose you should use <object> combined with classid and what not...http://www.w3schools.com/media/media_browsersounds.asphttp://www.w3schools.com/media/media_object.asp<bgsound> is an IE only tag...<embed> is for older browsers, supported in both IE and netscape, but deprecated...Good luck...
  8. Depending on which doctype you use, you might wanna close the image tag.html: <img src="..." alt="...">xhtml: <img src="..." alt="..." />
  9. Jonas

    ???

    You better get right on it! For shame!!
  10. Jonas

    ???

    Me thinks he should validate his xhtml first...http://validator.w3.org/check?uri=http://www.iribbit.net/
  11. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN""http://www.w3.org/TR/html4/loose.dtd"><html><head> <title>Banner Colorizer</title><meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <style type="text/css">.noShow{ display: none; width: 350px; padding: 5px; }.yesShow{ display: block; width: 350px; cursor: pointer; padding: 5px; }</style> <script type="text/javascript">var bgArray = [['#000000','#ffddff'],['#000000','#ffddff'],['#000000','#ffddff'],['#000000','#ffddff'],['#000000','#ffddff'],['#000000','#ffddff'],['#000000','#ffddff']];var fgArray = [['#000000'],['#000000'],['#000000'],['#000000'],['#000000'],['#000000'],['#000000']];var divArray = ['aDiv','bDiv','cDiv','dDiv','eDiv','fDiv'];var prev_banner = 0;var curr_banner = 0;var j = 0;var bTimer = null;var stop = false;function mkBG(toggle){if(stop) return;if(toggle){ document.getElementById(divArray[prev_banner]).className = 'noShow'; document.getElementById(divArray[curr_banner]).className = 'yesShow'; }banner = document.getElementById(divArray[curr_banner]); banner.style.background = bgArray[curr_banner][j]; banner.style.color = fgArray[curr_banner][j]; j++; if(j == bgArray[curr_banner].length && curr_banner == divArray.length - 1){ prev_banner = curr_banner; curr_banner = 0; j = 0; setTimeout('mkBG(true)', 5000); return; } else if(curr_banner < divArray.length && j == bgArray[curr_banner].length){ prev_banner = curr_banner; curr_banner++; j = 0; setTimeout('mkBG(true)', 5000); return; }setTimeout('mkBG()', 200); }function init(){setTimeout('mkBG(true)',50);}window.onload = init;</script> </head><body> <p> Customize your colors. </p> <div style="width:360px; height: 40px;"> <div class="noShow" id="aDiv" title="NewsA" onclick="window.location = 'http://www.w3schools.com/';"> Header A:<br />This is news item A. As you can see, it will pan out to black, and end up pink. Not sure this was what you wanted... </div> <div class="noShow" id="bDiv" title="NewsB" onclick="window.location = 'http://www.w3schools.com';"> Header B:<br />If this isn't what you want, we can work around that and work our way closer. Notice also that the height changes depending on the length of the text. If you want to give the news header a fixed height, you have to define a height in the style tag... </div> <div class="noShow" id="cDiv" title="NewsC" onclick="window.location = 'http://www.w3schools.com';"> Header C:<br />I think it's possible to just add divs like this, and they will be included in the scroll. Let's see... </div> <div class="noShow" id="dDiv" title="NewsD" onclick="window.location = 'http://www.w3schools.com';"> Header D:<br />Did it work? Not initially. But by changing the <span style="color: #ff0000;">divArray</span> sentence in the script tags to include dDiv, it worked. Now, just add as many divArrays as you want in the script tags... </div> <div class="noShow" id="eDiv" title="NewsE" onclick="window.location = 'http://www.w3schools.com';"> Header E:<br />Now I have 5 headers. Another thing to note is I've changed the display time from 2000 to 5000 ms, milliseconds. Look for <span style="color: #ff0000;">setTimeout</span> two places within the script tags, and change both of them to a higher or lower value for different display time. I also had to add a bgColor and fgColor array for every newsitem... :| Annoying... </div> <div class="noShow" id="fDiv" title="NewsF" onclick="window.location = 'http://www.w3schools.com';"> Header F:<br />Any questions? Don't hesitate to ask @ [url="http://w3schools.invisionzone.com"]http://w3schools.invisionzone.com[/url]... I'm sure we can improve this script even more, optimize it... </div> </div></body></html> Try it here:http://www.w3schools.com/html/tryit.asp?fi...e=tryhtml_basicCtrl+C the code in the codebox, and Ctrl+V it into the left frame...Oh, and excuse my ramblings...
  12. <a href="mailto:xxxxxx@xxxx.xxx" title="email me">email me</a>
  13. Huh, I have IE6, FF, NN and Opera...http://www.opera.com/download/:)I'm currently looking forward to Opera 9, which will have xslt support, so I can start learning writing AND displaying xml...
  14. I'm currently using (X)HTML, CSS and JavaScript...
  15. LOL, in the end, I think w3schools.com decides. Nuances, I know...
  16. Try putting the code here:http://www.w3schools.com/html/tryit.asp?fi...e=tryhtml_basicIt makes a banner which changes between Google, Yahoo and Mr. Jeeves, and also a link based on which search engine is currently displayed. As he says, you could edit this to make a news ticker with a link to the clicked news header... And of course, you could change the color to be the same on all of them...
  17. Jonas

    Visual Basic

    We're learning VB in school now, in computers class. The book we use use examples such as labels with "Hello World" as caption, but our teacher doesn't use the book at all. Instead, he gives us snippets of code so we can program stuff like Sudoku. We're currently having a project, where me, Bjørnar (also on this forum) and another guy is making a game called SubWars. Our teacher liked it a lot, and he wants us to convert it to JavaScript afterwards, using divs and stuff for labels. He's really a linux fan, hates microsoft, and says he's only used VB on one or two occasions outside class. But he knows his stuff. I think programming is universal in a way. If you only know the syntax, the same rules apply...That said, I guess Visual Basic could be seen as useful, but I'd rather get a thorough lesson in PHP/MySQL or .NET...
  18. There's also this script I've used earlier which works nice... <!-- put script in external file, or the w3 html validator will detect <link> in the script tags, and it's not allowed there -->var useragent = navigator.userAgent;var bName = (useragent.indexOf('Opera') > -1) ? 'Opera' : navigator.appName;if (bName == "Opera") {document.write("<link type=\"text\/css\" rel=\"stylesheet\" href=\"opera.css\" \/>")}else if (bName == "Netscape") {document.write("<link type=\"text\/css\" rel=\"stylesheet\" href=\"netscape.css\" \/>")}else {document.write("<link type=\"text\/css\" rel=\"stylesheet\" href=\"microsoft.css\" \/>")} So, if you have one stylesheet for Opera, one for NN/FF, one for Microsoft IE, that would work nicely. And then whatever css works for the individual browser in the correct stylesheet...
  19. Dude, go out, get some air, take it easy, relax. Someone will help you when they see it, if they can...
  20. Ok, so I wasn't really offended, hence the
  21. One way would be to make images in a program like Photoshop or GIMP, with transparent background, and use <img> and <map>. That would lock it in place...
  22. Jonas

    Link colours

    A blue link, but not the default, 16-colors blue. Something more like what's in the the header of every forum... ^
×
×
  • Create New...