logo-dw

Go Back   Dreamweaver Club Forums > Hand Coders Forum > HTML and CSS
Register FAQ Members List Search Today's Posts Mark Forums Read

Reply
 
Thread Tools Display Modes
Old 09-25-2012, 01:55 PM   #1
tony09uk
 
Join Date: Oct 2010
Posts: 340
Default multiple layout with same markup

Hi i have been playing around with html and css for a bit now and decided to create a site with multiple layouts, i want to set up my html and then use the css to get the layout i require. I assume this is possible, but cant work out how to make big variatio s without vhanging the html i.e. layout A will have buttons 1 2 3 at the botyom while layout B will have them at the top.

ive looked for tuts but must be searching th wrong thing as i cant find any.
tony09uk is offline   Reply With Quote
Old 09-25-2012, 04:18 PM   #2
gentleone
gentleone's Avatar
 
Join Date: Nov 2009
Location: Rhodes, Greece
Posts: 2,837
Default

It's possible, but not only with HTML & CSS. With JavaScript you can move, remove and add elements in the DOM, but firstly imo it's not wise to let the layout of a page depend on JavaScript and secondly you will confuse your vistors with a website layout that is not consistant.
__________________
www.gentlemedia.nl
gentleone is offline   Reply With Quote
Old 09-25-2012, 08:31 PM   #3
tony09uk
 
Join Date: Oct 2010
Posts: 340
Default

Thats a valid point that i hadnt thought of. But if i use it as an excercise. Would it be feasiable to use php and store the stylesheets in a database? I wanted to initally show a few of my designs on one site which is why i considered it
tony09uk is offline   Reply With Quote
Old 09-25-2012, 09:33 PM   #4
gentleone
gentleone's Avatar
 
Join Date: Nov 2009
Location: Rhodes, Greece
Posts: 2,837
Default

You can't make a complete different layout without touching the HTML or without using JavaScript.
You can do minor changes to it with the CSS float and position properties and it might be even possible to bring those buttons to the top with 'position: absolute', but... it's an unorthodox way of doing so.

I don't see how a stylesheet pulled out of a database can change the HTML.
__________________
www.gentlemedia.nl
gentleone is offline   Reply With Quote
Old 09-26-2012, 04:30 AM   #5
d a v e
 
Join Date: Feb 2006
Location: finland
Posts: 1,684
Default

a mixture of css garden style switching and showing/hiding different divs of content?? guess you're going to need js somewhere there.
d a v e is offline   Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 08:02 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2017, vBulletin Solutions, Inc.
Copyright 2006 DreamweaverClub.com