Forgot your password?
typodupeerror
The Internet News Slashdot.org

Retooling Slashdot with Web Standards 764

Joe Clark writes "Nearly a year after an interview with this correspondent highlighted a few problems with Slashdot's HTML, Daniel M. Frommelt and his posse have recoded a prototype of Slashdot that uses valid, semantic HTML and stylesheets. Frommelt projects four-figure bandwidth savings in the candidate redesign, were it adopted, not to mention better appearance in a wide range of browsers and improved accessibility. Next he needs volunteers to retool the Slashdot engine. And yes, he did it all with CmdrTaco's blessing." Slashdot has kept its HTML 3.2 design for a long time ("because it works"), but perhaps this effort will be a catalyst for change...
This discussion has been archived. No new comments can be posted.

Retooling Slashdot with Web Standards

Comments Filter:
  • While you're at it (Score:5, Insightful)

    by GoldMace ( 315606 ) on Saturday November 22, 2003 @01:08AM (#7534668)
    Could you please make page 2 of comments actually be page 2 of the comments. I might be incredibly naive, but it seems something more like page 1.5. I don't know about the rest of you, but I always just read the odd numbered pages of comments, because like way too much stuff if repeated from the previous page on the even numbered ones.
  • well (Score:5, Insightful)

    by revmoo ( 652952 ) <slashdot@meep.GIRAFFEws minus herbivore> on Saturday November 22, 2003 @01:09AM (#7534674) Homepage Journal
    but perhaps this effort will be a catalyst for change...

    How about a new look altogether?

    I had a look at the new site, and while it does fix many problems and should certainly be used to replace the existing setup, why not go a little farther and retool the look of the site as well?

    The look of slashdot has barely changed since the late 90's, and while the look certainly brings part of it's character, it's beginning to look dated. Perhaps it can be redesigned with a more effecient and cohesive interface while still retaining some of it's previous character?

    Or is it just a pipe-dream...
  • by The Unabageler ( 669502 ) <joshNO@SPAM3io.com> on Saturday November 22, 2003 @01:10AM (#7534679) Homepage
    did you not read the article?

    the code was converted to XHTML 1.0 Transitional, and validated


    that's almost as standard as you can get.
  • Hallelujah! (Score:5, Insightful)

    by EchoMirage ( 29419 ) on Saturday November 22, 2003 @01:12AM (#7534695)
    This is long long long long long overdue. Just because HTML 3.2 "worked" didn't make it good, or right. A proper application of [X]HTML and CSS can be a huge bandwidth saver. It looks like Google [google.com] also updated their design yesterday or today - no doubt to subtly cut down on the huge amounts of bandwidth they serve out. More importantly for Slashdot, however, is that writing their code in an open and updated fashion really opens up the market for the kinds of people that can access the site, and that's never a bad thing. So congratulations on starting this project, and I hope it gets underway soon!

    Now maybe I'll finally be able to change my .sig!
  • Agent sensing (Score:3, Insightful)

    by Trillan ( 597339 ) on Saturday November 22, 2003 @01:13AM (#7534698) Homepage Journal

    When the time comes, please add some code to switch to a light design when browsing with a PDA. I know right now you can select light mode, but it affects all browsers used from an account which isn't at all what I want...

  • Re:well (Score:5, Insightful)

    by Xerithane ( 13482 ) <xerithane@nerLIS ... g minus language> on Saturday November 22, 2003 @01:16AM (#7534715) Homepage Journal
    The beauty of CSS is that it can look different just by linking to a different stylesheet. If you read the full article, you would note he did make an alternate layout. It was sort of a mix between games and the traditional green, and wasn't exactly pretty. I don't think the idea was for it to be pretty, just to be "different."

  • Custom Colors (Score:2, Insightful)

    by VirtuaKnight ( 680220 ) on Saturday November 22, 2003 @01:17AM (#7534723)
    Perhaps you could add a section to preferences that lets users choose which color schemes to use on all of the Slashdot sections. If they don't want to set the same color for all sections, let them choose a default (individual settings for each section would probably eat up a lot of space).
  • by ericdano ( 113424 ) on Saturday November 22, 2003 @01:18AM (#7534731) Homepage
    One of the problems is the constant twiddling that happens on the CVS of slash. If you run a slash site, which I do, and keep up to date, you need to usually update every template on the site. Little things change, etc, etc. It's a pain in the ass. And look at when the Slashcode [slashcode.com] site was updated. Like months ago.

    It would be GREAT to see them finally, 3 or 4 years later, dump the old theme and streamline it with CSS and stuff. Is it going to happen anytime soon. Probably not.....

  • Re:well (Score:5, Insightful)

    by shaitand ( 626655 ) on Saturday November 22, 2003 @01:20AM (#7534740) Journal
    Not by this guy, he did a great job recreating the existing site, but did you look at his alternative skin? Dear god no...
  • by drpentode ( 586437 ) on Saturday November 22, 2003 @01:20AM (#7534741)

    Now that you've made slashdot standards compliant, why not make it look good? CSS has powerful leading, word spacing and font tools (all of them with relative measurements to look good across most browsers). If a browser doesn't like a text attribute, it won't display it, so you won't have to worry about the same unpredictability as you would with layers and div boxes. The one thing that sucks the most on slashdot is its typesetting. Type is the one thing web designers forget about, but doing it right drastically improves the appearance and readability of a site.

  • Re:CTRL-R (Score:1, Insightful)

    by Anonymous Coward on Saturday November 22, 2003 @01:22AM (#7534751)
    Fuck html standards, I'd like to see slashdot live up to basic community standards.

  • by PotatoHead ( 12771 ) <dougNO@SPAMopengeek.org> on Saturday November 22, 2003 @01:26AM (#7534774) Homepage Journal
    is a bad idea. Personally, I like it. Reducing the necessary bandwidth to use the site is a good thing though for everyone involved. Why spend money you don't have to in a down economy.

    Things do look a bit dated, but maybe that is a good thing. The popularity of /. is not an issue so what's to prove by changing the look? Gain new users? Have more impact?

    Anyone that matters knows the site already. The content is the reason they return, not the pretty icons. Getting more impact through a more compelling rendering might matter to a few folks, but will the expense be worth it?

    Maybe this is the wrong comparison... Take an established publication like the Times or WSJ. Do they make big changes often? No. The formula works and is a big part of their identity.

    I think they keep things the way they are because they know change works against the needs of their readers; namely, access to relevant content easily.

    Unless I am missing something, major changes to /. would prove to be a mistake.

  • Re:F5 (Score:5, Insightful)

    by ergo98 ( 9391 ) on Saturday November 22, 2003 @01:28AM (#7534786) Homepage Journal
    This is the classic response to that comment (about wasteful whitespace), yet I don't buy it.

    a) Totally guessing, but about 99.9999% of the pages served up are interpreted by "no one" other than the browser. It's more "readable" by the browser minus the whitespace.

    b) Most pages, like this, is "mechanically generated" - What you see in the final results was rendered: It isn't the "source-code". As such there is absolutely no code maintenance issues.

    What you're left with is the prospect that maybe one out of every million page hits is going to a Slashdot developer who's debugging that the rendered properly, though if it's XHTML transitional then a XML editor would be a great choice and would again make it irrelevant if it's clogged full of waste whitespace.
  • by Speare ( 84249 ) on Saturday November 22, 2003 @01:37AM (#7534837) Homepage Journal

    Not a flame.

    If you're thinking of retooling the slash engine itself, I hope you consider some of the oft-complained areas for the most improvement. Things get mixed up in any random-access submission "queue" engine, but slash seems to suffer from these things often. Even editors have grumbled about not seeing other editors' status on various stories.

    • detect multiple/overlapping story submissions by their URLs, and make it easier for editors to find the earliest and to find the best (longest, most links, no broken links) examples of a breaking story
    • automatically give submitters a reason for their rejections: "rejected; another poster broke the story earlier and/or better."
    • capitalize stories according to title rules (not just every word)
    • fix or highlight the top fifty most common grammatical mistakes in submissions automatically (s/\bmore then\b/more than/g)
    • automatically mirror (and provide as separate link) a front-page snapshot of featured stories for the first hour of a story going public
    • searcher should be aware of common three-letter acronyms, and index them better
    • allow meta-moderation of "overrated" and "underrated"
  • by polyhue ( 38042 ) on Saturday November 22, 2003 @01:42AM (#7534862)
    Well that's one of the key reasons to convert it - an alternate stylesheet can be provided for PDAs, though I don't know if any actually use it -- but more importantly it will lay out in clean text and respect the semantic structure, showing headlines (H tags), paragraphs, lists, etc., so all the freaks here could check it on their phones and such constantly and it should be good and readable.
  • by scoobysnack ( 144572 ) on Saturday November 22, 2003 @01:43AM (#7534869) Homepage

    Good article, just a couple of suggestions...

    In general, it's usually better to avoid giving layout-suggestive names to your div tags. In the example, the author calls the Login/Sections/Help div leftcolumn. It would probably be better to name it something that is more suggestive of it's content rather than it's location - this way, if in the future a new skin was added that moved the content to the right-side, or even bottom of the page, the div name wouldn't contradict it's location.

    Another suggestion would be to disable all images in the print.css file. The author already went ahead and disabled the advertisement, the left and right columns, but he left those pesky story icons. I know that when I print an article, usually all I care about is the text. It's a simple way to make a page a little more printer friendly.

    My last suggestion would be to move the content div tag, up near the top of the page. This way, as your browser downloads the information from the server, it will download the story information (important) before downloading the left/righthand content panes (unimportant). If someone stops loading their browser before the page download has been completed, at least the browser can attempt to render the story data. And with css, the layout will be preserved.

  • by yerricde ( 125198 ) on Saturday November 22, 2003 @01:46AM (#7534883) Homepage Journal

    how about eliminating all of the completely wasteful, bandwidth and processor consuming, whitespace?

    As you point out, XML, CSS, and ECMAScript, unlike Python, are not very sensitive to whitespace. Slashdot can mitigate whitespace's contribution to bandwidth in two ways: 1. mod_gzip (which Slashdot already uses), and 2. caching proxies that strip excess whitespace. But this article itself is intended to be read by developers, and clarity counts.

  • Comment removed (Score:5, Insightful)

    by account_deleted ( 4530225 ) on Saturday November 22, 2003 @01:52AM (#7534919)
    Comment removed based on user account deletion
  • by ericdano ( 113424 ) on Saturday November 22, 2003 @01:56AM (#7534936) Homepage
    Fast page loads would be one thing. Do a view page sometime and see all the CRAP that is in there. If you could reduce it then you could be speeding up your web viewing (slashdot reading) experience, and unclogging/freeing up Slashdot's bandwidth. Sounds like a win/win to me.
  • However, someone sufficiently motivated can rip it out and slap in something new. Sometimes people end up rewriting amazing portions of software when it's big enough. I'm not sure slashdot really does enough to warrant that kind of manhandling, it might be better to start entirely over.

    But then, I've never looked into slashcode, because while slashdot is a fine site, I would never want to run it. I'll learn a lot more if I write my own code, and I don't have lofty goals for my website.

  • ahem. ahem. (Score:1, Insightful)

    by Anonymous Coward on Saturday November 22, 2003 @03:41AM (#7535221)
    There's no way to tell a DIV to be a certain width & height, but grow larger if the content demands it. Feel free to post some html and prove me wrong.

    I'm being facetious of course -- Tables are only better because they have certain features that weren't included in CSS for whatever reason.
  • Re:F5 (Score:3, Insightful)

    by dvdeug ( 5033 ) <[or.liame] [ta] [guedvd]> on Saturday November 22, 2003 @04:20AM (#7535299)
    I don't see why so many sites have such a fetish with tabbed and spaced HTML when the browser discards it as garbage bytes,

    Whitespace isn't going to be your biggest bandwidth waster. So why not leave human readable.

    actually wasting time (albeit a tiny amount, but nonetheless) parsing through it.

    Why don't you measure it and compare it to other optimizations before you recommend that people spend their time changing it? "Premature optimization is the root of all evil", or something like that?
  • by Micah ( 278 ) on Saturday November 22, 2003 @04:29AM (#7535316) Homepage Journal
    Speaking of div tag names, I noticed they had one called "advertisement". Man, wouldn't that make ad blockers easy! Just overlay a custom CSS file with something like:

    #advertisement { display: none; } :-)
  • Re:Teeny Bug (Score:5, Insightful)

    by ubernostrum ( 219442 ) on Saturday November 22, 2003 @04:57AM (#7535357) Homepage

    I'm not really up on my css, but I would guess a solution would be to have the centre column floating next to the left column, or to define the distance from the left hand side in em units instead of pixels.

    Or the CSS property overflow [w3.org], which could be used in a variety of ways to make the text visible when it gets too large for the column.

  • Re:Blech... (Score:5, Insightful)

    by setmajer ( 212722 ) on Saturday November 22, 2003 @05:00AM (#7535363) Homepage
    The designer hardcoded a fontface because CSS doesn't automatically resize columns like tables do.

    Er, 'fontface'? WTF is a 'fontface'?

    As for CSS resizing automagically, resize in relation to what, pray tell? A box with width: 30%; resizes in relation to the viewport, a box with width: 15em; resizes in relation to font size, as of CSS 2.1 a box with float: left or float: right and no width resizes in relation to content (most browsers--including IE/Win--do this anyway) and table-layout will get you table-style layout with whatever tags you like. MS just didn't feel the need to support it in IE 5/Win or IE/Mac so people don't use it much. That's Microsoft's fault, not the W3C's

    Because CSS was designed by doofus eggheads and not experts in solving real world web design problems.

    Ian Hickson [hixie.ch] edited the CSS2.1 spec, and he's been 'solving real world web design problems' since at least 1998 when I worked with him at the Web Stanards Project [webstandards.org]. Hakon Wium Lie [w3.org] edited CSS 1, 2 and 2.1 and has been working on Opera [opera.com] since 1999, earned an MS in Visual Studies from MIT and wrote his thesis on electronic display of newspapers. TantekCelik [tantek.com] is responsible for the widely-lauded Tasman rendering engine used in IE 5.x/Mac. These people do use this stuff in the real world, and if you don't like the directions they're taking your'e free to join the www-style [w3.org] discussion list and let them know.

    Which then forces me to do a bunch of work

    One line of CSS is 'a bunch of work'? I suppose you find tying your own shoes a pretty onerous task as well?

    or accept undesirable browser settings

    Let me get this straight: you're hacked because the site doesn't use your settings for font size and face, but setting your browser to override the site's settings with your choices is 'undesirable'? Huh?

  • by ubernostrum ( 219442 ) on Saturday November 22, 2003 @05:11AM (#7535382) Homepage

    I don't know if this si a browser issue, or a problem with the CSS spec, but text overflow is a serious issue, one which breaks nearly every CSS page with complex layout in existance.

    Yeah, you'd think somebody would come up with an " overflow [w3.org]" property and put it in the CSS spec to fix that, wouldn't you?

    Snarky comments aside, most problems with layouts being broken by text magnification can be fixed with careful design. Yeah, it takes some work, but generally no more than what you'd put in nesting 800 tables...

  • Tidying posts (Score:5, Insightful)

    by KjetilK ( 186133 ) <{ten.omsnrejk} {ta} {litejk}> on Saturday November 22, 2003 @06:02AM (#7535452) Homepage Journal
    Amen!

    I hope they implement ASAP.

    But there is another challenge, and that's the posts people write. Anybody care about their code? For example, quoting, to do it properly, one should write: <blockquote><p>blah, blah</p></blockquote>. That's an awful lot of typing.

    A page is not going to validate unless the posts are correct.

    The way I have planned to do this on one of my sites, is to make sure that every time somebody clicks "Preview" or "Submit", the post is handled to Tidy [sourceforge.net] for sanity checks and conversion. By using preview, you can correct you're code, but you can never submit something that isn't well-formed.

    I'm using Perl too, not Slashcode, but AxKit [axkit.org]. Nevertheless, a good Perl implementation of Tidy is still lacking. There is a HTML::Tidy [sourceforge.net] project page on Sourceforge, but it hasn't really gotten off the ground.

    Does anybody else want to work on this, or do you have other ideas for cleaning up posts?

  • by pacman on prozac ( 448607 ) on Saturday November 22, 2003 @06:34AM (#7535513)
    Thats not the only problem, if it was just a single comment thread rolling over the page it would be easy enough to scroll past it....

    Its not...using nested mode, go to any article with 400 or more posts, the 2nd page will be almost identical to the first except for the last 1/4 or so, and that last 1/4 will be on page 3.

    I had assumed that nested mode didn't work well with whatever code calculates the offset from the limit on each page.
  • Re:F5 (Score:2, Insightful)

    by ergo98 ( 9391 ) on Saturday November 22, 2003 @09:26AM (#7535816) Homepage Journal
    Whitespace isn't going to be your biggest bandwidth waster

    True enough, but you don't always have to take on the biggest foe first - whitespace is one of those things that was actually intentionally added (it was more work to cleanly whitespace), so it would actually be less work to have skipped it.

    Why don't you measure it and compare it to other optimizations before you recommend that people spend their time changing it?

    Slashdot serves up millions of pages a day. One useless tab is several MB of Slashdot's bandwidth for absolutely no, or little, gain. I don't need to measure it (and, quite simply, I don't care enough too, though if someone wants to they can grab the tidy utility from the W3C, which strips out whitespace) to see that there is considerable waste in there. In the grand scheme of things it really isn't that much of a hit, but given that it was work to add it...
  • Handheld-friendly (Score:3, Insightful)

    by ralphclark ( 11346 ) on Saturday November 22, 2003 @09:38AM (#7535841) Journal
    The article suggests as a consequence of the CSS-based implementation that printer-friendly and handheld-friendly views would be available. Now that's surely going to be the killer argument for many of us. How much time would I save if I could read slashdot comfortably on the way to and from work? I'd get my life back finally after five years of being glued to my desk every evening...
  • Re:F5 (Score:2, Insightful)

    by Mr. Slippery ( 47854 ) <tmsNO@SPAMinfamous.net> on Saturday November 22, 2003 @09:39AM (#7535846) Homepage
    whitespace is one of those things that was actually intentionally added (it was more work to cleanly whitespace), so it would actually be less work to have skipped it.

    During development, people have to look at the generated HTML. To preserve their sanity, they use whitespace. Removing whitespace would be extra work (and it would end up being put back in by the next fellow who had to work on that code).

  • by TeknoHog ( 164938 ) on Saturday November 22, 2003 @10:15AM (#7535944) Homepage Journal
    Don't forget the 'light mode' in your /. preferences. Makes this site a lot more palatable even on full graphical browsers.
  • by DarkSarin ( 651985 ) on Saturday November 22, 2003 @10:38AM (#7536008) Homepage Journal
    Having read some of the other posts in this thread, there is a solution--DON'T use TABLES!!! I personally think that tables are a bad idea, and should be avoided at all possible.

    In most cases, one can replace tables with division tags, which work much better in general. The only caveat is that IE tends to break CSS based DIV tags if you use the wrong type of positioning. To be specific, if you use position: fixed; IE will NOT position this correctly, and really has trouble with multiple elements being fixed position. Mozilla actually fixes this position relative to your screen, not the rest of the page, allowing things like floating menu bars without crazy javascript solutions.

    It would be possible, (not necessarily convenient or easy) to migrate to a non-table based layout that would LOOK just about identical for most people, and solve the problems you mention.
  • Re:Tidying posts (Score:3, Insightful)

    by scrytch ( 9198 ) <chuck@myrealbox.com> on Saturday November 22, 2003 @11:26AM (#7536177)
    But there is another challenge, and that's the posts people write. Anybody care about their code? For example, quoting, to do it properly, one should write:

    blah, blah

    . That's an awful lot of typing.

    A page is not going to validate unless the posts are correct.

    The balance problem is trivally corrected by actually parsing the HTML in the post, then inserting the proper closing tags at the end. No, the page will still not validate -- but no one is asking for slash pages+posts to validate, merely asking that the templates themselves manage to validate.

    Demanding people submit validated HTML is simply going to chase a lot of people away from posting at all. A blog's job is not to make posting difficult.

  • PHP and Smarty (Score:3, Insightful)

    by justMichael ( 606509 ) on Saturday November 22, 2003 @11:56AM (#7536290) Homepage
    I use this all the time with Smarty output filters.

    In development the filters are disabled, when it goes to production they strip white space and single line comments.

    Combine that with Smarty caching and phpa and you get dynamic PHP pages that perform like static ones.

  • by frozenray ( 308282 ) on Saturday November 22, 2003 @02:02PM (#7536999)
    Good points.

    > allow meta-moderation of "overrated" and "underrated"

    *rrated is abused far too often in my opinion.
    Here [slashdot.org]'s an explanation from another /.er on why *rrated is not M2ed. I guess this would be easy to fix if the metamoderators could see the score of the comment at the time it was moderated (e.g. "Overrated at +3 Insightful" or something like that).

    Also, it should not be possible to moderate *rrated on a post with no previous moderation. This would prevent troll moderators from immediately lower the score of a post from 1 to 0 or -1 and thereby putting it below the threshold used by most readers without being caught in M2.

    Alternatively, we could rethink the whole M2 system, here [slashdot.org] are some ideas.
  • Re:Tidying posts (Score:3, Insightful)

    by KjetilK ( 186133 ) <{ten.omsnrejk} {ta} {litejk}> on Saturday November 22, 2003 @02:26PM (#7537180) Homepage Journal

    The balance problem is trivally corrected by actually parsing the HTML in the post, then inserting the proper closing tags at the end.

    Yes, that's true! But it is not simply the balance problem I'm addressing. People may for example use the BLOCKQUOTE element, but don't realize that it should be a P element within it. There are quite a lot of small things like that.

    but no one is asking for slash pages+posts to validate,

    I do... :-)

    The point is, tidy should be able to do that job easily, unless I've misunderstood something. Except in rather rare cases, tidy will ensure that the XHTML is well-formed, rewrite the stuff that doesn't, that it does not contain elements that are not in the spec, and that should be sufficient to ensure that the whole document validates, given that the template is good.

    Demanding people submit validated HTML is simply going to chase a lot of people away from posting at all. A blog's job is not to make posting difficult.

    This is a very important point. Indeed, if this is the result, it would be wrong. However, I'm quite sure this would not be the result, Tidy would be transparent to the user and a help.

fortune: cannot execute. Out of cookies.

Working...