Slashdot Mirror


CSS for Mobile Devices

Death of Rats writes: "The World Wide Web Consortium has finally released its working draft for Cascading Stylesheets 2 for Mobile Devices. Definitely check this out if you intend on getting in on WAP or any other form of wireless internet."

13 of 38 comments (clear)

  1. Re:Why a different version? by Bernal+KC · · Score: 2
    Filtering content will never adequately address the fact that the handheld device is different and requires different UE, different structuring of the content,... I'm not going to read the Atlantic Monthly on my cell phone no matter how you filter it. Nor is Datek's streamer the way I want to see stock quotes on my phone. For stuff you want on a mobile device, you need to redesign how it is delivered to suit the features and limitations of the mobile device.

    As for the foolishness of doing much with layout on a mobile device -- that is, in a sense, one motivation for subletting CSS for mobile devices. The idea of CSS is to separate the formatting from the content. There is still formatting that has to be applied to content aimed at a mobile device, CSSMP is an attempt to describe what is possible and appropriate.

    Sooner or later WAP will be rendered obsolete by changes in the wireless networks. But WML and WMLScript will probably endure longer than WAP just because cruft never dies, and this is useful cruft. I think the W3C is right to look forward to a post WAP mobile era where variations of familiar standards, such as XHTML Basic and maybe CSSMP, will integrate mobile devices into the web more cleanly than WAP.

  2. XML + XSL + Cocoon by gattaca · · Score: 2
    The other alternative is to do it all on the server using XML to specify your content and XSL to do the transformation. It exists, it works, and it doesn't rely on hardware manufacturers implementing new standards properly.

    I can't see that, in the near future, anybody will want the same style sheet for a desk top browser and a mobile phone - and I would expect the content displayed on a phone to be very much more restricted. Rather than send a lot of data that's going to get ignored, there's a good argument for only serving the data that's required. A producer->processor->formatter architecture allows for this. A servlet generates dynamic content, which is then passed to a processor that mungs it about a bit - inserts dates, side bars, menus and the like, before a formatter turns it into, for example, HTML, WAP, VoxML, or a binary format like PDF. Apache Cocoon is one architecture that does this, now.

  3. Let's worry about Netscape first by qqaz · · Score: 2

    If a cell phone can display CSS, why can't my PC? Let's get our priorities straight.

    --
    sup :cool:
  4. What about a mobile Slashdot? by Xenna · · Score: 2

    On a related subject, isn't it time for a Slashdot HTML 'view' formatted especially for small screen low-bandwidth devices? I know you can do a lot by setting your display preferences, but it could be a lot better.

    On the subject of WAP: I know the /. consensus is that it sucks, but a WAP version of Slashdot would definitely be welcomed by (admittedly non US) readers. WAP may suck, but the phones are cheap and capable enough to read headers and article abstracts when you're wasting your time in a queue or something. I wouldn't want to take part in a discussion typing on a phone, though...

    WML pages are easy to implement too, I think I could do a reasonable WAP version in a day or so.

  5. Damn... by Wolfier · · Score: 2

    I guess I'm too politically infected. The first thing that came to my mind after reading the story is, "So when will DeCSS arrive for Mobile Devices??"

  6. Pigdog.org has DeCSS by yerricde · · Score: 2

    Pigdog DeCSS is a filter that removes CSS-2 from a web page.

    --
    Will I retire or break 10K?
  7. What about webmasters who don't have root on www? by yerricde · · Score: 2

    The other alternative is to do it all on the server

    My web host doesn't have CGI support. Heck, I can't even do 301/302 redirects; I have to use meta tags or EcmaScript. How do I do anything on the server?

    --
    Will I retire or break 10K?
  8. Re:Why a different version? by TommyTuesday · · Score: 2
    I guess I'm of the school of thought that the ISPs for mobile devices ought to filter the content and rewrite it to suit mobile phones.

    Huh?! Last time I checked, my ISP was responsible for providing me bandwidth and...well, bandwidth.

    Try to think of one reason why many destinations (gobs of ISPs) should try to filter the immense variety of web content, instead of each "content provider," who has easy access to the data, creating output viewable on numerous devices (once, mind you, not once/transfer), before it is in transit.

    The idea of rewriting code (ie, http://www.amazon.com/phone/) for different access devices has always struck me as somewhat foolish.

    Yeah, different devices, like say, IE and Netscape? It may be inconvenient for web developers to do so, but hopefully standards like this will decrease the likelihood of a dominant proprietary system.

    Tom

  9. Will it get used? by ash5g · · Score: 2

    Is anyone using WAP? It'll probably be a while before CSS gets supported, and even longer before it gets implemented. Even browsers running on PC's don't all support it(or support it in the standard way). I don't think the idea of browsing stuff on a dodgy screen is going to take off anyway.

  10. Why a new MP stylesheet language? This is why! by resistant · · Score: 2

    We can credit W3C for being forward-looking, but I expect that CSSMP will go the way of WAP.

    Perhaps not. I believe the point of this newly crafted subset of CSS2 is to provide a stable reference for useful functions that ought to be in mobile devices (meaning ultra-portable devices with limited display capabilities, and not meaning laptops which might have better display capabilities than many quite old desktop computer layouts with small VGA monitors which are still in use throughout the world).

    This area is of keen interest to me, and after the long agony with simple HTML 3.2/4.0[1]+ and with CSS1 through the still not-quite-totally-there CSS2, any way to avoid any more standards wrangling will come as a great relief to those of us who have to actually do this stuff for a living. I'd imagine that XSLT 1.0+ engines will do much of the actual work, and it really helps to be able to more or less reuse all that existing work with a near-exact subset of CSS2.

    Anyways, I'm back (in a few minutes, after a little more procrastination) to figuring out how to most efficiently split up parts of (simple for now) XML documents for later Java/Python XML/XSLT processing, while allowing simpler, more immediate PHP 4.0+ XML processing. Argh ....

    --
    A truly excellent pizza parlor is a delight unto the heavens. Treasure the sauce and the toppings!
  11. Why a different version? by waldoj · · Score: 3

    It seems strange to me that a wholly different version of CSS is required for mobile phones. Wouldn't an extension of the existing CSS definitions make more sense? The majority of these terms exist in CSS.

    I guess I'm of the school of thought that the ISPs for mobile devices ought to filter the content and rewrite it to suit mobile phones. The idea of rewriting code (ie, http://www.amazon.com/phone/) for different access devices has always struck me as somewhat foolish.

    Perhaps the only thing more foolish than that is attempting much in the way of layout on a PCS screen. :) I understand that there are more advanced devices, like the Palm VII, that can handle more than 16x3 characters (or whatever), but it still seems to be mostly about content right now.

    We can credit W3C for being forward-looking, but I expect that CSSMP will go the way of WAP.

    -Waldo

    1. Re:Why a different version? by _xeno_ · · Score: 3
      It is an extension of CSS2. CSS2 has this concept of media types, with different rules. (For example, there is a vocal media type, which has very little use for line-height and rendering things... The one thing I remember about the voice media type is that you can specify types of voices to say (render) content in.)

      All CSSMP does is say that there is now a mobil-phone media type, and that these rules are used for it. In a way, it's a completely different spec, but you'd need it to be separate. Lumping voice browsers, TV browsers, and console-browsers into one standard would get... messy. CSSMP just gives another set of rules for rendering HTML content.

      BTW, how do you expect ISP's to rewrite Amazon.com's main page to work on a cellphone? It's kinda graphically intensive... How about Slashdot? For simple pages, it'd be easy, but for complex pages like Slashdot it would be all but impossible. (Especially pages that are designed to look a certain way, which cellphones, and lynx, usually choke on. Try nVidia's webpage under Lynx some time - it's all graphics without ALT tags.)

      Actually, as it turns out, CSSMP might be exactly what you want - since a page designed with a CSS2 style sheet can have multiple media types, the cellphone section would describe how to render the page on a cellphone, while the browser sections would identify how to display it under a browser. A properly designed page would work both under a CSS2 compliant browser (there aren't any!) and under a CSS2 compliant cellphone (and... there aren't any of those, either). But it would be the same HTML document, just different styling rules for different ways of displaying the same content.

      And while you're giving the W3C credit for being forward looking, realize that there is no (finished, I think Mozilla trys to) browser that currently implements CSS2 - and the W3C is currently working on CSS3 .

      --
      You are in a maze of twisty little relative jumps, all alike.
  12. Re:What?? by _xeno_ · · Score: 3
    Given that the only browser that I'm aware of this date that even attempts to implement CSS2 (which is not the same as standard CSS which IE for Mac does right) is Mozilla. (Or, rather, Gecko, I guess. The Mozilla renderer/parser combo, which I think is Gecko - but I might be wrong... Bottom line is that all Mozilla based browsers (eg, Galeon) should pick up the ability.)

    There is currently one production browser in existance that actually implements CSS1 - Internet Explorer 5 for Macintosh. Only the Mac version of IE does CSS1 correctly. No other browsers do. This spec is designed to supplement CSS2. The W3C is actively working on CSS3 for some strange reason...

    As to why they did this, that's simple: HTML was never designed to specify the style of the document, just the structure. That's why the tags have names like Paragraph, Emphasis, and Strong. HTML was designed to structure content - it never was intended to be used to create the complex web pages we see today.

    CSS was designed to solve that problem - it would move style away from the structure. CSS2 has the idea of multiple media types - all this mobile phone implementation really does is add another media type. The idea behind media types is so that HTML+CSS2 can be used in both a browser, and then have a special set of rules for when it's printed. There's a "vocal" set of rules for blind people who use text-to-speech browsers. Now there's a WAP "media" type so that phones that support it can view content.

    Most simply, the idea behind CSS2 is to allow someone to create a webpage based on content and not on style - and to allow the CSS backend to be changed, so that the look and feel of a website isn't done in HTML as much as it's done in CSS. The mobile phone CSS spec is simply an extension of this ideal - to separate content from style. By extension, that means you don't need to rewrite the page in HDML - all you need to do is use the special cellphone CSS section, and the page is "converted." This was the basic goal behind CSS2. It's too bad no one ever really got around to using it.

    --
    You are in a maze of twisty little relative jumps, all alike.