PDA

View Full Version : Problem with Multiply a Div Region


iiniiniin
09-10-2010, 09:33 AM
This is my situation:

In the content region, I create a div called #set. In this #set, I insert lots of text, images and sub div regions. After that, I want to make 10 versions of #set to let them place vertically in sequence. Of course, these versions are just similar in the form, but their content will be edited differently.

So, could you please show me the way to do this, and also teach me to manage the position of versions?

Thank you so much.

Corrosive
09-10-2010, 10:27 AM
Use a class and not an ID so that you can repeat the div styles. So #set becomes .set.

The positions of versions will be relative to the versions above. So, if coded correctly, one should sit neatly below the other. You can then make fine adjustments with margins and padding.

Hope that helps and welcome to the forum btw :)

iiniiniin
09-10-2010, 01:42 PM
Thank you. I understood it, but partially. After changing # to class, we can control the properties of version at the same time. However, what is the way to make multiple versions? I cannot use normal copy/paste because only text is processed. I absolutely dont want to redraw the div for 10 times, 100 times ... Please instruct me in details, I'm a newbie to CSS
Thank you

Corrosive
09-10-2010, 02:21 PM
I'm not sure I understand why you can't copy and paste your div structure? Maybe if you put your problem in some context we may be able to help further.

Corrosive
09-10-2010, 02:24 PM
Actually, this might be what you need; http://help.adobe.com/en_US/dreamweaver/cs/using/WScbb6b82af5544594822510a94ae8d65-7aaea.html Never used them but sounds like what you want to make your life easier :)

DWcourse
09-10-2010, 03:56 PM
In Dreamweaver you should be able to select the div and copy/paste it. Make sure <div.set> is selected in the status bar at the bottom of the Document window when copying.

Corrosive
09-10-2010, 03:58 PM
Yeah, I was kinda thinking that JC.

iiniiniin
09-12-2010, 03:16 AM
Thank both of you. I have solved the problem. It is just a simple step with copy and paste, noticing that the div is selected in the status bar.
Again, thank you very much for helpful lessons