Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
I am proud to announce the opening of my new FB demo compo!
#31
What aetherfox is, somewhat bluntly, suggesting is that code is more apt to run in more browsers, and be easier to edit if you separate your content from your style. Stuffing CSS code into "style" attributes clouds up a web page more than using plain HTML. This has little to do with code running in one browser vs. another, but it's generally more likely to work in all browsers if you follow proper standards and are aware of CSS bugs that exist in either browser. There is a wealth of cross-browser, standards-compliant code on the web.

e.g.
Code:
<html>
<head>
    <link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>
    <div id="title">Title of Page</div>
    <div id="somefield">Bloopity blah blah blah</div>
    <div class="text">
        <p>blah blah blah</p>
        <p>blah blah blah</p>
    </div>
</body>
</html>

Can be edited more efficiently. Also, it takes less time to download, because style.css would be used across multiple pages and that could would not have to be re-downloaded.

style.css would contain:
Code:
#title {
    /*stuff*/
}

.text {
    /* more stuff */
}

This practice isn't some elistist way of designing web pages... it consistently produces smaller pages that are easier to edit, and can change styles on the fly. THAT is good code, not necessarily "working" code.

Furthermore, anybody actually interested in obtaining your web page source can easily disable right-click and get the source, or just use the menu to view it. But if you want it there, you don't want to clout up the web page with it. Stuff the code into window.onload and stick that into a separate javascript file, called from the page in a <script language="javascript" src="mysrc.js"></script>.

the reason "font weight: 900" does not work in firefox is because the CSS property is "font-weight", not "font weight". IE is slightly better at dealing with broken code and firefox. Generally, you'll want to stick to keywords such as "font-weight: bold" though, as neither browser supports variable font weights. "font-weight: 800" looks just like "font-weight: 900" and "font-weight: bold".

Also, "filter" is a proprietary IE property. It's ugly, and it breaks other browsers, and it will never become a de-facto standard with the advent of CSS3's opacity property. If you can, stay away from them. But for what you use them for, it breaks in an acceptible manner in other browsers if you really want to use them.

Margins as a result of stacking div's are a major pain in the butt for me too. Usually, though, you can find a way that works in both browsers.
Reply
#32
To AetherFox and Jofers:

Pardon me on at least some of my last reply there. Smile ! And also, I am beginning to see the point that you two are trying to make here. It is not so much about Internet Explorer vs. FireFox on my pages, as it is rather about making at least my new compo pages much more simpler and easier to load using my own CSS-based files — something that I have really never even learned before! :o So today, I got a hold of an EXCELLENT beginner’s tutorial about CSS (Cascading Style Sheets) at the following web address:
......and started a good practice of it to apply to my HTMLs to make it more robust, simple, and more flexible than before. And so far, it is working real well and then some, guys!! Big Grin

As well, there are a lot of other tutorials indeed (like the links that you just placed in your last reply there, AetherFox! Big Grin ) that I am looking forward to checking out soon. Right now though, this whole CSS business here will definitely come in real handy for my continuing web development in keeping it both real and simple like never before to me, you know that? Wink=b !

Be catching you now, and thanks a lot for the great ideas, AetherFox and Jofers!!! :king:



[Image: file.php?id=32]
- Adigun Azikiwe Polack
One of the Founders of “Aura Flow” ::: Continuing Developer of “Frantic Journey”
Current Developer of “Star Angelic Slugger” ::: Webmaster of the “AAP Official Projects Squad”
Original Creator of the “The New FreeBASIC 8-Bit Palette Machine”



UPDATE (from May 26, 2005 at 5:54pm EST): Everybody, while I am indeed learning some CSS-based stuff, I just made a quick-and-dirty update to my FB demoscene compo pages (located beginning at http://dhost.hopto.org/aapproj/fbgfx/compo.html) in which:
  • 1 • OpenGL is NO LONGER allowed in the current compo theme that is being presented; and
    2 • I have just revised and updated the new Official Entry Rules for the compo a bit to give it some clarity here. Wink
Like I said, this is only a quick-and-dirty update, in that there is no significant fixes to my pages as of yet. I am only learning some CSS for the *first time* ever, so please bear with me here, okay? Good! Big Grin
url=http://dhost.hopto.org/aapproj/][Image: file.php?id=194][/url]
Your *official* home of the FreeBasic GFX Demo Central, now holding over 150 FB graphics demos so far!!! Big Grin !
Reply
#33
yeah Z!re, geez
url=http://www.random-seed.net][Image: asylumsig.png][/url]
Reply
#34
Go die, kplzthx
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)