<?xml version="1.0" encoding="ISO-8859-1" ?>
<?xml-stylesheet type="text/xsl" href="/lib/xsl/devedge-1.00/article_en.xsl"?>
<nde:article 
  url="/viewsource/2003/devedge-redesign/"
  xmlns="http://www.w3.org/1999/xhtml"
  xmlns:nde="http://devedge.netscape.com/2002/de"
  xmlns:ent="http://devedge.netscape.com/2003/ent"
  xml:lang="en">

  <nde:header>
  <nde:title>Netscape DevEdge Redesigns As Standards Showcase</nde:title>
  <nde:category>Article</nde:category>
  <nde:authlist>
    <nde:author>
      <nde:authname>Eric Meyer, Susie Wyshak</nde:authname>
      <nde:authaffil>Netscape Communications</nde:authaffil>
    </nde:author>

  </nde:authlist>
  <nde:pubdate year="2003" month="02" day="11"/>
  <nde:channels>
    <nde:channel id="viewsource" />
    <nde:channel id="strategy" />
    <nde:channel id="css" />
   </nde:channels>
    <nde:keywords>tableless, redesign, dhtml, dhtml menus, css, code sample, cascading style sheets, gecko, web standards, W3C
    </nde:keywords>
    <nde:summary>Netscape DevEdge now showcases efficient, accessible cross-browser design.  A tableless, CSS-driven design lets the visitor choose their preferred theme and incorporates a host of other improvements.  Learn more in this look at some key features.
     </nde:summary>
 <nde:translations>
      <nde:trans url="/viewsource/2003/devedge-redesign/index_ja.html">Japanese</nde:trans>
<nde:trans url="/viewsource/2003/devedge-redesign/index_pt_br.html">Portuguese</nde:trans>
    </nde:translations>
</nde:header>

  <nde:head>
<style type="text/css">
#examples td {border: 1px solid gray; padding: 0.5em; vertical-align: top;}
#content div.summary {float: right; width: 30%; font-size: smaller;
  border: 2px solid #006; background: #DDE; margin: 2em 0 1em 1.5em; padding: 0;}
#content div.summary h3 {margin: 0; padding: 0.25em 0.1em 0.15em;
  background: #006; color: #FFF; text-align: center;}
#content div.summary ul {margin: 0; padding: 0.5em 0.5em 0.75em 1.75em;}
a.simplelink {font-weight: normal !important;} 
</style>
  </nde:head>

  <nde:content>
<h2>Introduction</h2>
<p>
The Netscape DevEdge team undertook a massive redesign in a relatively short 
timeframe to show how advanced CSS and XML can help web developers worldwide 
in their quest to create cross-browser sites based on W3C web standards. 
The redesigned site aims to demonstrate, among other things:
</p>
<ul>
	<li>Various cross-browser standards-based layout and design techniques</li>
	<li>The accessibility advantages of standards-based site design</li>
	<li>How easily you can create an engaging user-controlled experience</li>
</ul>
<p>
Although this is a move the team has debated on and off for some time, we were very definitely inspired by the work that Douglas Bowman did for <a href="http://www.wired.com/news/culture/0,1284,55675,00.html">wired.com's October 2002 redesign</a>.  (You can get more information from <a href="/viewsource/2002/wired-interview/">our interview with Douglas</a>.)  In some ways, what we're doing here is an attempt to have our developer site be a cutting-edge example of what can (and can't) be done with clean markup and CSS-driven layout.
</p>

<div class="summary">
<h3>Benefits To Visitors</h3>
<ul>
    <li>Accessible content: Text and ordering is friendly to screen readers, handheld devices, and other 
	'alternative' user agents.</li>
    <li>High performance: Faster, lighter pages free of clunky tables and markup improve the user experience.</li>
    <li>Customizable: Visitors can pick whichever design and text size makes them happiest 
	while perusing DevEdge.</li>
</ul>
</div>

<h2>The Challenge</h2>
<p>
When we set out to take this step, we had some basic goals in mind.  These were:
</p>
<ul>
<li>Site driven by XHTML 1.0 Transitional and CSS to confer fast page downloads and accessible content</li>
<li>Simple markup to allow for rapid changes to templates</li>
<li>Drop average page weight by 25%</li>
<li>Allow centralized control over layout and appearance</li>
<li>Accomplish page layout with simple CSS positioning</li>
<li>Vastly increase accessibility without special coding or user agent detection</li>
</ul>
<p>
At this stage, we have achieved four of our six goals, and almost hit five.  The two we missed were using XHTML 1.0 Transitional, and the page weight reduction.
</p>
<p>
Why aren't we using XHTML?  Mostly because some of our older content was authored under HTML 4.x, and the effort of converting it was judged to be not worth the payoff.  We instead decided to go with HTML 4.01 Transitional.  Note that as of the redesigned site's launch, not all of our pages validate, thanks largely to the aforementioned legacy content.  We plan to clean those up over time, and eventually have a site that validates from front to back.
</p>
<p>
The page weight reduction goal was very ambitious, and while we came close to cutting down our markup weight, we didn't quite make half.  This was partly because we had relatively lean markup for our previous design; even though it used tables for layout, they were simple tables that we'd stripped down as far as we could.  If you look strictly at the "templated" markup-- that is, the markup that appears on every page-- we would have hit a 50% reduction if we hadn't made our navigation so much more comprehensive.  But more on that in a moment.
</p>


<h2>Key Demo-able Features</h2>

<p>
Here are a few of the new features you can try out:
</p>

<h3>Demo 1: User-Selectable Styles</h3> 
<p>
To show how easily sites can offer a user-controlled look and feel, we decided to employ a "style switcher" that would let users 
pick one of four themes for DevEdge, and also let them change the default text size for the site.  
The basic JavaScript code to do this is based on <a href="http://alistapart.com/stories/alternate/">Paul Sowden's switching script</a>, but incorporates a number of custom changes.  We considered a more complex customization tool that would let users define their own arbitrary color sets for various interface elements, but in the end decided to keep things relatively simple.  The advanced customization feature may be implemented at a later date.
</p>
<p>
When you pick a theme, your preference is saved in a cookie called <code>nde-style</code>.  It would be about as easy to have a stylesheet for each section of a site, thus allowing for area-specific themes.  It's also possible to have stylesheets that completely rearrange the site layout to a user's preference.
</p>
<p>
The same basic mechanism is used to remember the text size setting, except the cookie in this cae is called <code>nde-textsize</code>. 
</p>

<h4>How to try it:</h4>
<ul>
	<li>Mouse over Customize and select your favorite theme.</li>
	<li>Click the + and - to resize the text, and R to reset it to the original size.</li>
</ul>


<h3>Demo 2: Cross-Browser DHTML Menus</h3>
<p>
It's easy to tout the benefits of cross-browser menus, but it wasn't until we began coding with advanced CSS techniques that we really felt the pain of needing to support less standards-compliant browsers.  We went back and forth over using "pure CSS" menus versus more traditional Javascript-driven menus.  In the end, the DevEdge team combined advanced CSS with JavaScript to create menus that drop down beautifully in the multiple browsers based on <a href="/central/gecko">Netscape Gecko</a>, as well as Internet Explorer and Opera.
</p>
<p>
Best of all, the menu markup is based on nested unordered lists, which keeps the markup light and structured for non-visual browsers and alternative devices like cellphones or palm-computing browsers.  In doing this, the DevEdge team drew inspiration from the <a href="http://www.meyerweb.com/eric/css/edge/menus/demo.html">"pure CSS menus" demo</a> at <a href="http://www.meyerweb.com/eric/css/edge/">css/edge</a> and the DHTML menus <a href="http://gazingus.org/dhtml/?id=109">available at gazingus.org</a>, although we took our own approach to the implementation.  This allowed us to create easily restylable menus that worked in multiple browsers using fairly lightweight Javascript. Even better, the CSS and JavaScript are set up so that if JavaScript is disabled, then menus will still work in CSS2-conformant browsers.  Learn from our experiences and see how your site could benefit from re-using this code.
</p>
<h4>How to try it:</h4>
<ul>
<li>Mouse over the top navigational menus with Netscape 7, IE 5.5+, and Opera 7+.</li>
<li>Disable JavaScript. You will see that in Netscape 7.01 or Mozilla 1.0+ the menus still works, due to advanced support of CSS2 present in the Gecko rendering engine.</li>
</ul>


<h3>Demo 3: Structuring for Accessibility and Usability</h3>
<p>
A driving force in the redesign effort was making DevEdge's content even more accessible than it had been in its previous incarnation.  In order to make this possible, the design team decided from the beginning that the site would be laid out using CSS positioning.  This allowed the documents to be structured in a way that makes sense for linear-access devices (such as screen readers) while still permitting visually rich design.
</p>
<p>
For example, in modern browsers, the "Search" and "Customize" boxes are right next to each other. If you look at the document source itself, the "Search" area is part of the site's masthead and appears near the beginning of the document, while the "Customize" area is actually the last thing before the page footer.  In a similar fashion, the navigation bar that runs just underneath the site masthead actually appears <em>after</em> the page content in the document's source.
</p>
<p>
Because the appearance of the site is almost entirely divorced from the source order of the content, DevEdge is now far more friendly to wireless and other 'alternative' browsers that don't use CSS.  Furthermore, the entire layout of the site can be rearranged without changing the underlying markup in the slightest-- thus preserving the accessibility benefits no matter what styles are used to create the site's visual appearance.
</p>
<p>Additionally, print-friendly stylesheets are automatically applied when printing articles, as an experiment 
in simplifying the user experience.  In print, hyperlinks within body text have the URL printed just after the link text, thus making the links less useless in print.
</p>
<h4>How to try it:</h4>
<ul>
<li>View source code of any page.</li>
<li>Verify accessibility with the <a href="http://www.wave.webaim.org/"> WAVE Web Accessibility Validator</a>.</li>
<li>Also, try saving a page to your harddrive. You'll see it renders all text in a way that makes navigation easy for various types of readers.  This can also be seen in browsers that allow you to disable stylesheets, or in those browsers that don't understand CSS.</li>
<li>Print an article to see the printer friendly stylesheet and printed URL paths.</li>
</ul>

<h2>More Features and Benefits</h2>
<p>
The redesign comes with a host of less visible improvements, including:
</p>
<ul>
<li>Automatically-generated RSS data feeds: Now we can syndicate news to  
our new <a href="/toolbox/sidebars/">DevEdge Sidebar Tabs</a> and external newsfeeds.</li>
<li>Automated PDF creation: We can automatically generate PDF versions of our articles by transforming the base XML file into the Acrobat file format.</li>
<li>Simplified scripting: Scripts work in multiple browsers. This also simplifies browser detection, which is only needed to block broken browsers from seeing the Javascript.</li>
<li>Easier, more flexible design process: The design can change easily as CSS allows  separation of presentation from structure. We could just as easily offer wildly different layouts as thematic variations on a single layout.  Some examples of this sort of complete restyling include the <a href="http://www.nitot.com/standards/blog/">standards blog at nitot.com</a>, the <a href="http://www.adactio.com/journal/">journal at adactio.com</a>, and the search engine <a href="http://www.alltheweb.com/help/alchemist/gallery.html">alltheweb.com</a>.</li>
<li>Content reusability: Ready for non-PC devices thanks to the tableless structure. All visitors get exactly the same markup.</li>
<li>Localizability: Easy to add new international sections by hooking content to language-specific templates and CSS.</li>
</ul>
<p>
Although these changes don't have much direct impact on the visitor experience, they do make it much easier for the DevEdge team to keep the site running smoothly and make the information we provide more diverse and useful to visitors.
</p>

<h2>Browser Compatibility Notes</h2>
<p>
Theoretically, any web browser at all can access DevEdge.  In visual terms, however, 
DevEdge employs techniques that work in today's more standards-compliant browsers.  
In any user agent, the site's content should be completely available for your perusal.  
The site's CSS layout has been constructed such that the following browsers and platforms 
are known to take advantage of the site's advanced features.  
</p>
<p>
Preferences: You'll need to enable cookies and JavaScript to experience the full effect of various features, particularly the site themes.  Without JavaScript enabled, you can still navigate using the section index 
pages and CSS menus which work in Netscape 7+ and Mozilla 1+.
</p>
<p>
<strong>Caveat:</strong>  Due to 
known browser bugs or incomplete W3C CSS or DOM standards compliance in these and other browsers, 
you may encounter minor issues.  In addition to wanting to feature modern standards, we decided not 
to optimize for Netscape 4.x simply because we've seen a dramatic downturn of visitors using 4.x, thanks 
to the popularity of Netscape 7.x.  Netscape 4.x users will still receive the content of the site, but not its styling.
</p>
<ul>
<li>Visual layout browser compatibility:
<ul>
<li>Netscape 6+ (any platform)</li>
<li>Mozilla 0.8+ (any platform)</li>
<li>Internet Explorer 5.5+ (Windows)</li>
<li>Internet Explorer 5.0+ (Macintosh)</li>
<li>Opera 6+ (Windows)</li>
</ul>
</li>
<li>Javascript-driven dropdown menus browser compatibility:
<ul>
<li>Netscape 7+ (any platform)</li>
<li>Mozilla 1.0+ (any platform)</li>
<li>Internet Explorer 5.5+ (Windows)</li>
<li>Opera 7+ (Windows)</li>
</ul>
</li>
</ul>
<p>
Give us your <a href="/community/feedback/">feedback</a> if you find the site works 
well on platforms/browsers not listed here, or any suggested code fixes that will improve 
its cross-browser behavior.  
</p>
<h2>Technical Details</h2>
<p>
Learn more about the <a href="/viewsource/2003/devedge-redesign-css/">CSS</a> and 
<a href="/viewsource/2003/devedge-redesign-js/">JavaScript</a> code underlying Netscape DevEdge, as well as our decision making process while constructing the site.
</p>
</nde:content>

<nde:related area="nde">
 <nde:item url="/central/css/">CSS Central</nde:item>
 <nde:item url="/central/dom/">DOM Central</nde:item>
 <nde:item url="/viewsource/2003/devedge-redesign-css/">Netscape DevEdge Redesign: CSS</nde:item>
 <nde:item url="/viewsource/2003/devedge-redesign-js/">Netscape DevEdge Redesign: JavaScript</nde:item>
 <nde:item url="/viewsource/2003/devedge-redesign-faq/">DevEdge Redesign FAQ</nde:item>
</nde:related>

</nde:article>
