Results 1 to 16 of 16

Thread: Apoch's Programming FAQ -- please post Web related tips here!

  1. #1

    Thread Starter
    Frenzied Member mlewis's Avatar
    Join Date
    Sep 2000
    Posts
    1,226

    Apoch's Programming FAQ -- please post Web related tips here!

    This is a continuation of the Programming FAQ thread in the General VB forum, but this thread is for web tips only!

    Thanks for your contributions!
    M. Lewis
    Pi-Q Software
    How many mouse clicks does it take to cook breakfast?

    Blargh! I am dead!

  2. #2
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170
    well... umm...

    avoid using the LAYER tag, as NN and IE have a conflict with that. Instead use the DIV tag.

    is that a web tip...? or should I delete this?

  3. #3

    Thread Starter
    Frenzied Member mlewis's Avatar
    Join Date
    Sep 2000
    Posts
    1,226
    That could be a tip, I guess. But what I am looking for is more like cool stuff you can do (for examples, see link in my signature)
    M. Lewis
    Pi-Q Software
    How many mouse clicks does it take to cook breakfast?

    Blargh! I am dead!

  4. #4
    Frenzied Member sebs's Avatar
    Join Date
    Sep 2000
    Location
    Aylmer,Qc
    Posts
    1,606
    Originally posted by mendhak
    well... umm...

    avoid using the LAYER tag, as NN and IE have a conflict with that. Instead use the DIV tag.
    yeah you're right, but the onMouseOver does not
    work in NN on a div, you have to use a layer tag, but beside
    that, everything else seem ok!

  5. #5
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170
    sorry lewis, I'm not that good, but I'll put one anyway...

    To avoid the trauma and torture of the browser wars, wherein something works in NN and not in IE, or vice versa,
    just AVOID IT!

    place a sniffer on your very first page, and redirect the users to the browser website of your choice.

    heeeeeeeee.

    hint: Netscape users account for about 15% of web users. Ditch 'em.

    (PS: no intention to start a flame)

  6. #6

    Thread Starter
    Frenzied Member mlewis's Avatar
    Join Date
    Sep 2000
    Posts
    1,226
    All I have to do is put a big disclaimer that says "if you use a sucky browser (read: Not I.E.) then this may not work. If it breaks, its your fault for choosing a piece of junk."

    OK so itd be a bit nicer than that, but thats the basic idea
    M. Lewis
    Pi-Q Software
    How many mouse clicks does it take to cook breakfast?

    Blargh! I am dead!

  7. #7
    Black Cat JoshT's Avatar
    Join Date
    Nov 2000
    Location
    WNY, USA
    Posts
    4,032
    Originally posted by mlewis
    All I have to do is put a big disclaimer that says "if you use a sucky browser (read: Not I.E.) then this may not work. If it breaks, its your fault for choosing a piece of junk."

    OK so itd be a bit nicer than that, but thats the basic idea
    I'm going to open up a gas station, and put a big disclaimer that syas "if you use a sucky automobile (read: Not Nissan) then this gasoline may not work, its your fault for driving a piece of junk."

    How long would I be in business?
    Josh
    Get these: Mozilla Opera OpenBSD
    I have books for sale: "MCSD in a Nutshell" and "VB Distributed Exam Cram" - PM me for details. Will also trade for a decent ATX Pentium 2 MB/CPU/RAM combo.

  8. #8

    Thread Starter
    Frenzied Member mlewis's Avatar
    Join Date
    Sep 2000
    Posts
    1,226
    I'm not selling my code for one thing; for another, I.E. has a bigger market share than Nissan does.
    M. Lewis
    Pi-Q Software
    How many mouse clicks does it take to cook breakfast?

    Blargh! I am dead!

  9. #9
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170
    some guy in this forum told me 17 million netscape users. by my calculations, that's 100 million IE users then. who do u choose?


    Here's another useless web tip. When working for CROSS BROWSER COMPATIBILITY (contradiction, no?)

    use this

    <SCRIPT Language="javascript">
    function init(){
    if (navigator.appName == "Netscape") {
    layerStyleRef="layer.";
    layerref="document.layers";
    styleswitch="";
    pxSwitch="";
    }else{
    layerStyleRef="layer.style.";
    layerref="document.all";
    styleswitch=".style";
    pxSwitch="px";
    }

    }
    </SCRIPT>
    now you can manipulate the various layers using this.

  10. #10
    Frenzied Member sebs's Avatar
    Join Date
    Sep 2000
    Location
    Aylmer,Qc
    Posts
    1,606
    another tip would be,

    whenever you do a check and then a redirection, you know
    when you press back and it come back!

    use

    location.replace

    it does not create a new entry in the history list, it replace
    the current one!

  11. #11
    Black Cat JoshT's Avatar
    Join Date
    Nov 2000
    Location
    WNY, USA
    Posts
    4,032
    Originally posted by mlewis
    I'm not selling my code for one thing; for another, I.E. has a bigger market share than Nissan does.
    I predict this will decrease in the future. More and more devices that are not PC's will be connected to the Internet, and there's a good chance they won't be running IE. AOL is eventually going to dump IE, and Linux is growing in popularity...

    Also, you say you code for IE, but do you test the Solaris version of IE? How about the HP-UX version? And the Mac version generally supports W3 standards before the Windows version.
    Josh
    Get these: Mozilla Opera OpenBSD
    I have books for sale: "MCSD in a Nutshell" and "VB Distributed Exam Cram" - PM me for details. Will also trade for a decent ATX Pentium 2 MB/CPU/RAM combo.

  12. #12
    Frenzied Member sebs's Avatar
    Join Date
    Sep 2000
    Location
    Aylmer,Qc
    Posts
    1,606
    if you want to loop thru your text box

    Code:
    function cycle() {
        var answer = '';
        for (var i = 0; i<document.formName.elements.length; i++) {
            if ((document.formName.elements[i].name.indexOf('Text') > -1)) {
               	if(document.formName.elements[i].value.length<0){
    			alert('Your missing some info');
    			document.formName.elements[i].select();
    			document.formName.elements[i].focus(); 
    			break();          	
               	}
            }
        }
    }

  13. #13
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170
    that's a good one sebs.
    I wonder if anyone's even reading this stuff...


    a lot of people like changing their scroll bar colors, and here's how.

    Code:
    
    <style type="text/css">
    body{
    scrollbar-face-color:#BD7268; 
    scrollbar-arrow-color:#f8e8d0;
    scrollbar-track-color:#f8e8d0; 
    scrollbar-shadow-color:black;
    scrollbar-highlight-color:#f8e8d0;
    scrollbar-3dlight-color:black;
    scrollbar-darkshadow-color:black;
    }
    
    </style>
    play with the colors.

  14. #14

    Thread Starter
    Frenzied Member mlewis's Avatar
    Join Date
    Sep 2000
    Posts
    1,226
    Bleh! Slow down! Gotta get those posted
    M. Lewis
    Pi-Q Software
    How many mouse clicks does it take to cook breakfast?

    Blargh! I am dead!

  15. #15
    Frenzied Member sebs's Avatar
    Join Date
    Sep 2000
    Location
    Aylmer,Qc
    Posts
    1,606
    this one is for flash,

    you can pass parameters to your movie

    Code:
    <OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0" WIDTH=600 HEIGHT=24> 
    	<PARAM NAME=movie VALUE="special.swf?msg=<%=msg%>"> 
    	<PARAM NAME=quality VALUE=high> 
    	<PARAM NAME=bgcolor VALUE=#FFFFFF> 
    	<EMBED src="special.swf?msg=<%=msg%>" quality=high bgcolor=#FFFFFF  WIDTH=600 HEIGHT=24 TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash"></EMBED>
    </OBJECT>
    my above code is mixed with asp, so my msg come from asp!
    msg is a text box in my movie

  16. #16
    Frenzied Member sebs's Avatar
    Join Date
    Sep 2000
    Location
    Aylmer,Qc
    Posts
    1,606
    asp tips,

    if you need to display a lot of item row by row,

    ex: list of book with their desc on the right, etc...

    usually you put it in a table separated by row, and when
    the page is done it appears on the screen!

    well instead, if you do in separate table, they will
    come out one by one, so the user don't thinkg that it takes forever
    to load the page!

Posting Permissions

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



Click Here to Expand Forum to Full Width