#content
html,body { margin:0; padding:0; }
#extra{background:#FF8539}
#navigation{background:#B9CAFF}
#footer { color:#FFF; background:#333; }
#footer p { margin:0; padding:5px 10px; }
#footer p a{color:#0f0}
#content { background:#f6f6f6; }
$(function() {
$('.ss').click(function() {
var styleName = $(this).attr('rel');
var title = $(this).attr('title');
switchStylestyle(styleName);
var curClass = 'current-style';
$('#styleswitchs img').filter('.'+curClass).removeClass(curClass);
$('#'+styleName).addClass(curClass);
$('#current-style').text(title);
$('#css-inc').load('./style/'+styleName.replace(/s/, "")+'.css',
function(){ $(this).prepend('/* Style '+title+' */'+"\n\n");}
);
return false;
})
.filter(':first').click();
});
function switchStylestyle(styleName) {
$('link[@rel*=alternate][@title]').each(function(i) {
this.disabled = true;
if (this.getAttribute('title') == styleName) this.disabled = false;
});
}
<link rel="stylesheet" href="./style.css" /> <link rel="alternate stylesheet" href="style/01.css" title="s01" /> <link rel="alternate stylesheet" href="style/02.css" title="s02" /> <link rel="alternate stylesheet" href="style/03.css" title="s03" /> .. <a href="#" rel="s01" class="ss" title="3 columns"><img src="01.png" /></a> <a href="#" rel="s02" class="ss" title="3 columns"><img src="02.png" /></a> <a href="#" rel="s03" class="ss" title="3 columns"><img src="03.png" /></a> ..
<div id="container">
<div id="header">Header</div>
<div id="wrapper">
<div id="content">Content</div>
</div>
<div id="navigation">Navigation</div>
<div id="extra">Extra stuff</div>
<div id="footer">Footer</div>
</div>







































