Thread: CSS and XHTML
Hello all! I saw a post on pgsql-hackers from Robert Treat that made me interested in finding out if there's something for me to do with the postgresql.org site. It sounds like there are a lot of things going on: merging of sites, adding or increasing the multilingual capabilities, and reworking the backend. I don't know specifics of what needs to be done and I'm willing to work on anything I'm capable of doing. One thing I am interested in doing is working to make the site as efficient and standards-compliant as possible. In particular, I'd like to see the feasibility of coding to the XHTML standard and moving as much presentational code to CSS as possible. For the most part, this is pretty straightforward and not too difficult. I downloaded the site from the CVS and reworked cache/index.htm, postgresql.css, and page.php. I rewrote them to XHTML 1.0 Strict and got them free of errors (using BBEdit's Check Syntax function) with presentation that closely matches the original. (One caveat: I haven't been able to connect to the database(s)—is there a way to do this from my development machine?—so the generated pages haven't included the main content. The markup generated by the basic.*.php scripts is all error-free.) I don't foresee any major problems in the rest of the site, though I have to get to know the code better to be sure. I see at least two advantages for the site: (a) the resulting scripts are easier to read, as there is very little presentational markup remaining, and therefore much easier to maintain; and (b) the server load is substantially decreased, as less code needs to be sent to the client. The presention (in the css file) is cached by the clients, so it rarely needs to be fetched. The pages themselves are slimmed down, since they contain just the document structure. For example, the current main index page is 15.2K + .6K (postgresql.css) for a total of 15.8K. The main index page is now 6.3K (sans news remember), and postgresql.css is 3.8K, for a total of 10.1K. I know we're only talking 5K, but it's a 30% reduction in server load for the *first* page view. Once the CSS is cached, we're looking at a 40% reduction per page. Of course these will change once the content. Just a rough estimate for the content section: 13.6K to 11.3K, so just a little savings there (about 15%). Anyway, you guys probably know all this anyway. And I'm sure there are more critical issues to work on. But this is one thing I know I could work on and you can probably tell I'm kind of excited to. If you have any questions or would like to see the modifications, just ask. One thing I'd like to know is server stats (load and browser distributions, if it's available). And if I can help out in other ways, I'm happy to do that as well. Regards, Michael Glaesemann grzm myrealbox com
On Sunday, November 9, 2003, at 11:30 PM, Michael Glaesemann wrote: > For example, the current main index page is 15.2K + .6K > (postgresql.css) for a total of 15.8K. The main index page is now 6.3K > (sans news remember), and postgresql.css is 3.8K, for a total of > 10.1K. I know we're only talking 5K, but it's a 30% reduction in > server load for the *first* page view. Once the CSS is cached, we're > looking at a 40% reduction per page. Where's my math! 15.8K to 6.3K is a *59%* reduction. (6.3K is approximately 40% of 15.8K). Off to an auspicious start! :) Michael
Hello Michael, You can find some stats at http://www.postgresql.org/stats/ I think it would be good to have a XHTML compatible site. But as it seems the site structure will change (if we decide tomerge the sites), it might be better if you wait for this new structure before redoing the (X)HTML to avoid double work... Mit freundlichen Grüßen Andreas Grabmüller ----- Original-Nachricht ----- Von: "Michael Glaesemann" <grzm@myrealbox.com> An: pgsql-www@postgresql.org Datum: Sunday, November 09, 2003 03:34 PM Betreff: [pgsql-www] CSS and XHTML > Hello all! > > I saw a post on pgsql-hackers from Robert Treat that made me interested > in finding out if there's something for me to do with the > postgresql.org site. It sounds like there are a lot of things going on: > merging of sites, adding or increasing the multilingual capabilities, > and reworking the backend. > > I don't know specifics of what needs to be done and I'm willing to work > on anything I'm capable of doing. One thing I am interested in doing is > working to make the site as efficient and standards-compliant as > possible. In particular, I'd like to see the feasibility of coding to > the XHTML standard and moving as much presentational code to CSS as > possible. > > For the most part, this is pretty straightforward and not too > difficult. I downloaded the site from the CVS and reworked > cache/index.htm, postgresql.css, and page.php. I rewrote them to XHTML > 1.0 Strict and got them free of errors (using BBEdit's Check Syntax > function) with presentation that closely matches the original. (One > caveat: I haven't been able to connect to the database(s)is there a > way to do this from my development machine?so the generated pages > haven't included the main content. The markup generated by the > basic.*.php scripts is all error-free.) I don't foresee any major > problems in the rest of the site, though I have to get to know the code > better to be sure. > > I see at least two advantages for the site: (a) the resulting scripts > are easier to read, as there is very little presentational markup > remaining, and therefore much easier to maintain; and (b) the server > load is substantially decreased, as less code needs to be sent to the > client. The presention (in the css file) is cached by the clients, so > it rarely needs to be fetched. The pages themselves are slimmed down, > since they contain just the document structure. For example, the > current main index page is 15.2K + .6K (postgresql.css) for a total of > 15.8K. The main index page is now 6.3K (sans news remember), and > postgresql.css is 3.8K, for a total of 10.1K. I know we're only talking > 5K, but it's a 30% reduction in server load for the *first* page view. > Once the CSS is cached, we're looking at a 40% reduction per page. > > Of course these will change once the content. Just a rough estimate for > the content section: 13.6K to 11.3K, so just a little savings there > (about 15%). > > Anyway, you guys probably know all this anyway. And I'm sure there are > more critical issues to work on. But this is one thing I know I could > work on and you can probably tell I'm kind of excited to. If you have > any questions or would like to see the modifications, just ask. One > thing I'd like to know is server stats (load and browser distributions, > if it's available). And if I can help out in other ways, I'm happy to > do that as well. > > Regards, > > Michael Glaesemann > grzm myrealbox com > > ---------------------------(end of broadcast)--------------------------- > TIP 3: if posting/reading through Usenet, please send an appropriate > subscribe-nomail command to majordomo@postgresql.org so that your > message can get through to the mailing list cleanly -- LetzPlay.de | Freemail: http://www.letzplay.de/mail | Forenhosting: http://www.letzplay.de/foren
On Sun, 9 Nov 2003, Andreas GrabmXller wrote: > Hello Michael, > > You can find some stats at > http://www.postgresql.org/stats/ > > I think it would be good to have a XHTML compatible site. But as it > seems the site structure will change (if we decide to merge the sites), > it might be better if you wait for this new structure before redoing the > (X)HTML to avoid double work... If we are redoing the site, might it not be better to try and adhere to the XHTML standard as much as possible, to avoid doing double work? :)
----- Original-Nachricht ----- Von: "Marc G. Fournier" <scrappy@postgresql.org> An: Andreas GrabmXller <webmaster@letzplay.de> CC: pgsql-www@postgresql.org, grzm@myrealbox.com Datum: Sunday, November 09, 2003 07:06 PM Betreff: [pgsql-www] CSS and XHTML > On Sun, 9 Nov 2003, Andreas GrabmXller wrote: > > > Hello Michael, > > > > You can find some stats at > > http://www.postgresql.org/stats/ > > > > I think it would be good to have a XHTML compatible site. But as it > > seems the site structure will change (if we decide to merge the sites), > > it might be better if you wait for this new structure before redoing the > > (X)HTML to avoid double work... > > If we are redoing the site, might it not be better to try and adhere to > the XHTML standard as much as possible, to avoid doing double work? :) Yes, but if the code in CVS is out of date and hast to be redone for the new site structure, it does not make sense to updateit to XHTML ;) Mit freundlichen Grüßen Andreas Grabmüller -- LetzPlay.de | Freemail: http://www.letzplay.de/mail | Forenhosting: http://www.letzplay.de/foren
On Sun, 9 Nov 2003, Andreas GrabmXller wrote: > Yes, but if the code in CVS is out of date and hast to be redone for the > new site structure, it does not make sense to update it to XHTML ;) True, but if there is someway of Micheal being able to access the new code, so that he can update it as its being developed, instead of waiting until the end? I may be thinking of something else, but isn't xHTML just a more strict HTML? (ie. <TD>'s *must* have matching </TD>'s) Michael?
----- Original-Nachricht ----- Von: "Marc G. Fournier" <scrappy@postgresql.org> An: Andreas GrabmXller <webmaster@letzplay.de> CC: scrappy@postgresql.org, pgsql-www@postgresql.org, grzm@myrealbox.com Datum: Sunday, November 09, 2003 07:42 PM Betreff: [pgsql-www] CSS and XHTML > On Sun, 9 Nov 2003, Andreas GrabmXller wrote: > > > Yes, but if the code in CVS is out of date and hast to be redone for the > > new site structure, it does not make sense to update it to XHTML ;) > > True, but if there is someway of Micheal being able to access the new > code, so that he can update it as its being developed, instead of waiting > until the end? Well, the new code isn't really existing yet... there are just the two test.htm files but nobody has decided yet if we doit that way (I think nobody has even decided if we merge the sites?)... > I may be thinking of something else, but isn't xHTML just > a more strict HTML? (ie. <TD>'s *must* have matching </TD>'s) > > Michael? Mit freundlichen Grüßen Andreas Grabmüller -- LetzPlay.de | Freemail: http://www.letzplay.de/mail | Forenhosting: http://www.letzplay.de/foren
On Sun, 9 Nov 2003, Andreas GrabmXller wrote: > Well, the new code isn't really existing yet... there are just the two > test.htm files but nobody has decided yet if we do it that way (I think > nobody has even decided if we merge the sites?)... Actually, I thought we had decided that the only two we couldn't merge in were gborg and techdocs? And, I tend to be of the opinion that if nobody pipe's up negative, go with as proposed ... and the only comment I saw go about the design was from Dave, and it appeared positive :) Correct me if I'm wrong here, but when I looked at it, all I saw was that the left menu 'bar' was extended to pull in the various sites? I didn't see anything jump out at me as far as changes were concerned, beyond that ... or did I miss something?
----- Original-Nachricht ----- Von: "Marc G. Fournier" <scrappy@postgresql.org> An: Andreas GrabmXller <webmaster@letzplay.de> CC: scrappy@postgresql.org, pgsql-www@postgresql.org, grzm@myrealbox.com Datum: Sunday, November 09, 2003 07:59 PM Betreff: [pgsql-www] CSS and XHTML > On Sun, 9 Nov 2003, Andreas GrabmXller wrote: > > > Well, the new code isn't really existing yet... there are just the two > > test.htm files but nobody has decided yet if we do it that way (I think > > nobody has even decided if we merge the sites?)... > > Actually, I thought we had decided that the only two we couldn't merge in > were gborg and techdocs? And, I tend to be of the opinion that if nobody > pipe's up negative, go with as proposed ... and the only comment I saw go > about the design was from Dave, and it appeared positive :) You are right, I just don't know who decides what here ;) And I don't know who is responsible for the advocacy and developersites... > Correct me if I'm wrong here, but when I looked at it, all I saw was that > the left menu 'bar' was extended to pull in the various sites? I didn't > see anything jump out at me as far as changes were concerned, beyond that > ... or did I miss something? Yes, principially you are right, it's the new menu plus the current-versions-box on the top right and maybe the new indexpage. If we decide to do this changes it might be the easiest way if Michael takes the current CVS source and applies the changesin test2.htm in a XHTML compatible way... Mit freundlichen Grüßen Andreas Grabmüller -- LetzPlay.de | Freemail: http://www.letzplay.de/mail | Forenhosting: http://www.letzplay.de/foren
On Sun, 9 Nov 2003, Andreas GrabmXller wrote: > You are right, I just don't know who decides what here ;) And I don't > know who is responsible for the advocacy and developer sites... I'd say that Advocacy falls under Josh et al ... developer tends to be an enigma (nobody really maintains it) .... As for 'who decides' ... its more by consensus ... so unless you get negative feedback, go with 'nobody is against it, so proceed' ... if you waited for everyone to give feedback and agreement, you could be sitting on it for months :)
On Sunday, November 9, 2003, at 11:30 PM, Michael Glaesemann wrote: > The pages themselves are slimmed down, since they contain just the > document structure. For example, the current main index page is 15.2K > + .6K (postgresql.css) for a total of 15.8K. The main index page is > now 6.3K (sans news remember), and postgresql.css is 3.8K, for a total > of 10.1K. I know we're only talking 5K, but it's a 30% reduction in > server load for the *first* page view. Once the CSS is cached, we're > looking at a 40% reduction per page. Where's my math! 15.8K to 6.3K is a *59%* reduction. (6.3K is approximately 40% of 15.8K). Off to an auspicious start! :) Michael
-On [20031109 19:42], Marc G. Fournier (scrappy@postgresql.org) wrote: >I may be thinking of something else, but isn't xHTML just a more strict >HTML? (ie. <TD>'s *must* have matching </TD>'s) Basically HTML 4.01 defined in XML. -- Jeroen Ruigrok van der Werven <asmodai(at)wxs.nl> / asmodai / kita no mono PGP fingerprint: 2D92 980E 45FE 2C28 9DB7 9D88 97E6 839B 2EAC 625B http://www.tendra.org/ | http://www.in-nomine.org/~asmodai/diary/ Unto the pure all things are pure...
Marc, Andreas: > > You are right, I just don't know who decides what here ;) And I don't > > know who is responsible for the advocacy and developer sites... > > I'd say that Advocacy falls under Josh et al ... developer tends to be an > enigma (nobody really maintains it) .... Robert is the lead on Advocacy. I've no objections to making Advocacy the "press" page for a united site. However, Robert may have some objections, I don't know. Robert, FWIW, taking this united approach would silence some of the objections of Peter and some of the other core Hackers who don't like advocacy in its current form. Andreas, before we could consider merging Advocacy, though, we'd need to have the multi-lingualism set up. One of the primary reasons why Advocacy is a seperate system is because it's in 7 langauges. As for Techdocs ... We really, really want to try techdocs on Bricolage, but Bric outputs static web pages which we would then upload. It's possible that we could blend those into the main site; I'm not sure. The issue would be not having Techdocs on CVS as Bric already incorporates version control. Also, I don't think Bric supports XHTML -- but don't quote me on that. Also, re: the XHTML issue, are there potential browser problems? Never forget the number of people in the world using I.E. 5.0 or Netscape 6.2. There's a lot. -- Josh Berkus Aglio Database Solutions San Francisco
On Sun, 9 Nov 2003, Josh Berkus wrote: > Marc, Andreas: > > > > You are right, I just don't know who decides what here ;) And I don't > > > know who is responsible for the advocacy and developer sites... > > > > I'd say that Advocacy falls under Josh et al ... developer tends to be an > > enigma (nobody really maintains it) .... > > Robert is the lead on Advocacy. I've no objections to making Advocacy > the "press" page for a united site. However, Robert may have some > objections, I don't know. Robert, FWIW, taking this united approach > would silence some of the objections of Peter and some of the other core > Hackers who don't like advocacy in its current form. Just a side note ... even with a 'merged site', there should be no reason why we can't have 'advocacy.postgresql.org' point to the lead page for that section ... same with developer ... I think the thing I don't like about the current advocacy site is that it doesn't have the 'glitz' that one generally sees from a marketing perspective ...
Marc, > Just a side note ... even with a 'merged site', there should be no reason > why we can't have 'advocacy.postgresql.org' point to the lead page for > that section ... same with developer ... I think the thing I don't like > about the current advocacy site is that it doesn't have the 'glitz' that > one generally sees from a marketing perspective ... You and Peter need to battle it out then. Peter doesn't like the existing advocacy site becuase it's too much Marketing-Speak. I think, in a lot of ways, he's right; we're not a big corporation and we don't need to pretend to be one. However, there are several viewpoints in this discussion and I think we should battle it out on -Advocacy after 7.4 releases. -- Josh Berkus Aglio Database Solutions San Francisco
Hello all! On Monday, November 10, 2003, at 01:46 AM, Andreas Grabmüller wrote: > You can find some stats at > http://www.postgresql.org/stats/ Thanks for the stats. I noticed that the Report Magic analysis dates from March. Is there anything more recent? Or might not it matter? > I think it would be good to have a XHTML compatible site. But as it > seems the site structure will change (if we decide to merge the > sites), it might be better if you wait for this new structure before > redoing the (X)HTML to avoid double work... I'm all for avoiding double work. When is a decision to be made on merging sites? With the merge, will there by a style redesign as well? On Monday, November 10, 2003, at 04:49 AM, Andreas Grabmüller wrote: > > If we decide to do this changes it might be the easiest way if Michael > takes the current CVS source and applies the changes in test2.htm in a > XHTML compatible way... On Monday, November 10, 2003, at 06:05 AM, Josh Berkus wrote: > Also, re: the XHTML issue, are there potential browser problems? > Never forget > the number of people in the world using I.E. 5.0 or Netscape 6.2. > There's a > lot. Netscape 6.2 shouldn't be a problem at all. IE5/Win can be handled quite easily. As Marc pointed out, XHTML is just HTML defined as XML. Big differences include closing tags, lowercasing tags (XML is case-sensitive), and quoting attributes. Nothing really major. As such, any browser that can handle HTML shouldn't have a problem with XHTML. Presentation via CSS is another thing. Briefly, really old browsers just don't do CSS. They'll ignore all of the presentation, but the content will be just fine. Very basic :) but just fine. And most recent browsers handle parts or most of CSS just dandy. Speaking to IE5/Win directly, there are well-documented ways to work around it's particular CSS bugs without resorting to custom pages or browser detection. Looking at the list of browsers, the areas I'm a little concerned about are the ~3% using 4.x browsers, the ~3% identifying as Netscape compatible, and the ~3% not providing any browser identity. That's six percent we really don't know about, and 3% we'd probably end up hiding some of the CSS from.They wouldn't get the full glory of the site, but it wouldn't be plain Jane either. (I'm currently looking for a place to get a version of Netscape 4 to test with.) There are a few identities I'm not familiar with, but they don't account for much (less than 1.5%). And I'm ignoring the bots and text-only browsers, since presentation doesn't really matter to them. The three things on my mind are answering any other questions people may have, getting my computer wrapped around a more recent version of the code, and somehow connecting to the database or hosting a sample of it myself to work on the content section. And a fourth thing. I'd like to get people's reactions to what I've done so far and to test it with browsers I don't have access to (mostly the IE/Win versions, Galeon, and Konqueror). Michael grzm myrealbox com
It's rumoured that Michael Glaesemann once said: > Hello all! > > On Monday, November 10, 2003, at 01:46 AM, Andreas Grabmüller wrote: > >> You can find some stats at >> http://www.postgresql.org/stats/ > > Thanks for the stats. I noticed that the Report Magic analysis dates > from March. Is there anything more recent? Or might not it matter? March is when the first version of the new site went live on the new server we setup. >> I think it would be good to have a XHTML compatible site. But as it >> seems the site structure will change (if we decide to merge the >> sites), it might be better if you wait for this new structure before >> redoing the (X)HTML to avoid double work... > > I'm all for avoiding double work. When is a decision to be made on > merging sites? With the merge, will there by a style redesign as well? It's not so much when we merge, but when we transition. At some point, onece we're happy with Andreas' new framework & style, we will move to it. Incidently, unless Andreas objects, I see no reason why you cannot submit patches for the new code to get it up to xhtml strict if you like (though I have to wonder if we would have to use transitional - for example, iirc there is no nowrap in strict). Regards, Dave.
Michael, > browsers I don't have access to (mostly the IE/Win versions, Galeon, > and Konqueror). Gaelon & Konqueror are easy for me; I have several different versions on my Linux machines. I'm also not particularly worried about the Linux geeks using older versions, as they (we) are used to being told to upgrade to fix something. And upgrades are free. I'd say ignore Konqueror compatibility completely, except that Safari runs KHMTL too. I can also test IE 5.0 & 3.0 as well, I *think* -- I've got Win2k and Win98 on vmware. -- Josh Berkus Aglio Database Solutions San Francisco
On Tuesday, November 11, 2003, at 03:07 AM, Dave Page wrote: > patches for the new code to get it up to xhtml strict if you like > (though > I have to wonder if we would have to use transitional - for example, > iirc > there is no nowrap in strict). Your right: no nowrap in Strict. However, you can set nowrap to elements using css, I believe. <style type="text/css"> <!-- .nowrap { white-space:nowrap; } --> </style> <table> <tr><td>This cell should wrap normally.</td> <td class="nowrap">This cell won't wrap (or warp, for that matter) no matter how much text you put it it.</td></tr> </table> .nowrap works in <table>, <tr>, and <td> tags.
> -----Original Message----- > From: Michael Glaesemann [mailto:grzm@myrealbox.com] > Sent: 10 November 2003 18:50 > To: pgsql-www@postgresql.org > Subject: Re: [pgsql-www] CSS and XHTML > > > On Tuesday, November 11, 2003, at 03:07 AM, Dave Page wrote: > > patches for the new code to get it up to xhtml strict if you like > > (though I have to wonder if we would have to use transitional - for > > example, iirc there is no nowrap in strict). > > Your right: no nowrap in Strict. However, you can set nowrap > to elements using css, I believe. Ahh, thanks. I'm not as up to speed with xhtml/strict as I should be :-( Regards, Dave.
On Tuesday, November 11, 2003, at 04:26 AM, Dave Page wrote: >> Your right: no nowrap in Strict. However, you can set nowrap >> to elements using css, I believe. > > Ahh, thanks. I'm not as up to speed with xhtml/strict as I should be > :-( From what I've seen, PostgreSQL people are usually so up-to-speed on nearly everything, there's very little I can contribute. If you knew everything about CSS and XHTML, I'd have very nearly nothing to give back to the community! :) Michael grzm myrealbox com