New Feature: Playlist Center! Pick a topic and let our playlists guide the way.

Start learning with our library of video tutorials taught by experts. Get started

Dreamweaver CS3 Essential Training
Illustration by

Adding AP div tags


From:

Dreamweaver CS3 Essential Training

with Garrick Chow

Video: Adding AP div tags

Up until this point, when we placed artwork or text directly on our page or even inside tables, we had the ability to right, left, or center align the elements, and pretty much that was the end of the story. If I type some text on here, I can't select that text and just drag it down to the center of my screen, or anywhere. Basically, I can just put it either left aligned, center aligned, or right aligned. End of story. This can be frustrating as a designer, because it would be much easier if you could just stick that artwork or text anywhere you wanted on the page, and just have it stay there. That's where these AP divs come in. They're your friends, because you can position them anywhere without restriction. As their name implies, you can absolutely position them anywhere.
Expand all | Collapse all
  1. 1m 12s
    1. Welcome
      1m 12s
  2. 21m 0s
    1. HTML vs. XHTML
      3m 4s
    2. What is CSS?
      3m 48s
    3. What is XML?
      2m 11s
    4. What is DHTML?
      1m 9s
    5. What is JavaScript?
      1m 23s
    6. File naming conventions
      3m 22s
    7. What is an index page?
      6m 3s
  3. 46m 18s
    1. Setting up your workspace
      2m 39s
    2. The Welcome screen
      4m 11s
    3. Windows and Mac differences
      3m 18s
    4. The Insert bar
      4m 38s
    5. The Property Inspector
      1m 50s
    6. The Document toolbar
      6m 6s
    7. The Document window
      9m 11s
    8. Panels and panel groups
      6m 58s
    9. Saving workspace layouts
      2m 22s
    10. Defining a default browser
      5m 5s
  4. 24m 59s
    1. Defining a site
      9m 5s
    2. File and folder management
      3m 11s
    3. Understanding path structure
      3m 17s
    4. Adding content to a site
      6m 6s
    5. Creating a site map
      3m 20s
  5. 38m 39s
    1. Creating a new blank site
      6m 0s
    2. Creating and saving a new document
      7m 54s
    3. About DOCTYPE
      3m 59s
    4. Inserting images
      9m 26s
    5. Inserting text
      3m 35s
    6. Aligning text and images
      4m 9s
    7. Inserting meta tags
      3m 36s
  6. 45m 58s
    1. Link basics
      6m 4s
    2. Linking with Point to File
      5m 18s
    3. External links
      4m 15s
    4. Creating email links
      5m 49s
    5. Named anchors
      7m 37s
    6. Linking to a file
      7m 35s
    7. Image maps
      9m 20s
  7. 1h 8m
    1. About CSS
      4m 52s
    2. Anatomy of a style sheet
      4m 10s
    3. CSS and page properties
      10m 11s
    4. Moving an internal style sheet to an external style sheet
      6m 46s
    5. The CSS Styles panel
      3m 48s
    6. CSS selectors
      2m 37s
    7. Type selectors
      12m 13s
    8. ID selectors
      10m 21s
    9. Class selectors
      5m 42s
    10. Creating rollovers with pseudo-class selectors
      7m 22s
  8. 42m 54s
    1. CSS vs. the Font tag
      2m 42s
    2. Formatting text with the Property Inspector
      8m 41s
    3. What measurement should I use?
      3m 15s
    4. Managing white space with margins, padding, and line height
      8m 34s
    5. Using font lists
      5m 45s
    6. Aligning text
      2m 47s
    7. Creating lists
      5m 8s
    8. Creating Flash text
      6m 2s
  9. 43m 19s
    1. About tables
      1m 28s
    2. Tables in Code view
      2m 36s
    3. Creating and adding content to tables
      7m 40s
    4. Changing table borders with XHTML
      5m 46s
    5. Coloring tables with XHTML and CSS
      6m 41s
    6. Aligning table content
      6m 39s
    7. Sorting tables
      3m 6s
    8. Setting table widths
      4m 48s
    9. Creating rounded-corner tables
      4m 35s
  10. 28m 22s
    1. Dreamweaver's layout tools
      3m 8s
    2. Tracing images
      4m 58s
    3. Adding AP div tags
      7m 29s
    4. Working with Layout Tables
      6m 55s
    5. Adjusting table widths and nesting tables
      5m 52s
  11. 16m 19s
    1. What is a device?
      3m 14s
    2. Attaching a printer-friendly style sheet
      3m 5s
    3. Styling for print
      7m 41s
    4. Adobe Device Central
      2m 19s
  12. 29m 54s
    1. Rollover rules
      3m 31s
    2. Creating simple rollovers
      5m 36s
    3. Creating disjointed rollovers
      7m 12s
    4. Creating navigation bars with multiple states
      9m 21s
    5. Creating Flash buttons
      4m 14s
  13. 26m 32s
    1. Viewing the code
      6m 9s
    2. Editing in Code view
      3m 0s
    3. The Code toolbar
      5m 11s
    4. Working with Code Collapse
      4m 27s
    5. The Quick Tag Editor
      2m 20s
    6. Working with snippets
      5m 25s
  14. 32m 45s
    1. About forms
      3m 23s
    2. Adding text fields
      9m 52s
    3. Adding checkboxes and radio buttons
      5m 37s
    4. Adding lists and menus
      6m 5s
    5. Submitting form results
      3m 23s
    6. Styling form elements with CSS
      4m 25s
  15. 23m 17s
    1. Opening a new browser window
      9m 38s
    2. Creating a popup message
      2m 50s
    3. Validating text fields
      2m 42s
    4. Getting more behaviors
      7m 2s
    5. Removing extensions
      1m 5s
  16. 14m 58s
    1. External image editor preferences
      3m 18s
    2. Built-in image editing tools
      3m 11s
    3. Roundtrip editing from Dreamweaver to Fireworks or Photoshop
      4m 39s
    4. Copying and pasting
      3m 50s
  17. 34m 16s
    1. Templates in action
      5m 12s
    2. Creating a new template
      6m 36s
    3. Applying templates
      3m 36s
    4. Modifying a template
      1m 40s
    5. Adding repeating regions
      3m 28s
    6. Working with repeating regions
      3m 13s
    7. Adding optional regions
      3m 34s
    8. Creating a library item
      3m 48s
    9. Modifying a library item
      3m 9s
  18. 13m 2s
    1. Using the History panel
      4m 24s
    2. Saving History steps as commands
      3m 25s
    3. Using Find and Replace
      5m 13s
  19. 14m 44s
    1. W3C accessibility guidelines
      4m 6s
    2. Accessibility preferences
      1m 29s
    3. Inserting accessible images
      3m 2s
    4. Inserting accessible tables
      2m 53s
    5. Inserting accessible form objects
      3m 14s
  20. 26m 17s
    1. About media objects
      2m 6s
    2. Linking to audio and video files
      5m 56s
    3. Embedding audio and video files
      7m 7s
    4. Setting parameters
      4m 27s
    5. Inserting Flash content
      2m 37s
    6. Inserting Flash video
      4m 4s
  21. 28m 47s
    1. Getting site reports
      3m 35s
    2. Checking links sitewide
      3m 30s
    3. Signing up with Tripod
      6m 36s
    4. Entering remote info
      4m 13s
    5. Publishing your site
      5m 41s
    6. Updating and publishing pages
      5m 12s
  22. 44s
    1. Goodbye
      44s

Watch this entire course now—plus get access to every course in the library. Each course includes high-quality videos taught by expert instructors.

Become a member
please wait ...
Dreamweaver CS3 Essential Training
10h 22m Beginner Apr 16, 2007

Viewers: in countries Watching now:

In Dreamweaver CS3 Essential Training, instructor Garrick Chow delves into the many powerful features of the latest version of this powerful web design application. He covers everything from the simplest basics of using Dreamweaver CS3 to applying it to develop a fully interactive, accessible site. Garrick explains the new interface features, and demonstrates how to create, edit, manage, design, and publish a professional website with Dreamweaver CS3 and complementary applications. Exercise files accompany the training.

Subject:
Web
Software:
Dreamweaver
Author:
Garrick Chow

Adding AP div tags

Up until this point, when we placed artwork or text directly on our page or even inside tables, we had the ability to right, left, or center align the elements, and pretty much that was the end of the story. If I type some text on here, I can't select that text and just drag it down to the center of my screen, or anywhere. Basically, I can just put it either left aligned, center aligned, or right aligned. End of story. This can be frustrating as a designer, because it would be much easier if you could just stick that artwork or text anywhere you wanted on the page, and just have it stay there. That's where these AP divs come in. They're your friends, because you can position them anywhere without restriction. As their name implies, you can absolutely position them anywhere.

Rather than simply placing artwork or text on the page, as we've been doing so far, you can put your content into these AP divs, and move them anywhere you want to make sure that they're lined up nice and neat. So in this movie, we're going take a look at how to create these AP divs on the page, and then how to insert images and text inside of them. I'm currently working with my index page, and we've added this tracing image to it in the previous movie, and again the tracing image is just this background image that we're using as a guide. It does not appear in the browser, and only appears here in {italic}Dreamweaver.{plain} So, there are a couple of ways to insert these AP divs. The first method is to go to the Insert menu, choose Layout Objects, and in here you'll find AP Div.

And here is our AP div. I selected it by clicking that little handle in the upper left-hand corner there, and by clicking that I can drag it anywhere onscreen that I want. So, let's say that I want to create an AP div that's going to hold the image for this Teacloud logo up here. I'm going to come in here and drag the layer up there. I'm just going to drag this so that it matches up to the tracing image. I can finesse this by using the arrow keys on a keyboard to move that up a pixel at a time. And I'll drag the bottom border up a bit. Like so. That looks just about right. Now, bear in mind, you can also use your magnifying glass if you're having trouble lining up your divs. You can zoom in here and see that it lines up okay.

And it seems to be doing that alright. I just prefer to work at 100% at all times, or for the majority of the time at least. Okay, so there's my div. Notice that it's been assigned the name apDiv1, and you can call that whatever you want, but we'll just leave that for the default name for now. We'll talk more about the properties in just a moment here. To add an image inside this layer, I'm going to click inside of it, and then we'll choose Insert > Image. I'll go into my assets folder, into images, and we'll find logo.png, which is, as you can see, is the exact logo that we want to use here. I'll go ahead and click Choose.

Now the image is inside my div tag. Notice that the image looks darker because we had a tracing image screened back to about 50% opacity. And again, that makes it easier to see what your real artwork is, and what your tracing image is. Now we're going to draw the layers for the navigation area, but just to make sure that everything is lined up correctly, we're going use the guides that we can drag out in {italic}Dreamweaver.{plain} This is a feature that was introduced in {italic}Dreamweaver 8,{plain} which was the previous version of {italic}Dreamweaver,{plain} and they're still available in {italic}Dreamweaver CS3.{plain} You want to make sure that you have the rulers turned on. Go to View, and make sure that there's a check mark next to Show when you go to rulers, which I do in this case. To drag out guides you simply click in the ruler, and drag down. Notice that it locks right up to the top of that div, like so. We'll click and drag another one out. That will line up down there, and we'll drag one more out for the left side, and we'll just let that line up. It's snapping right to the tracing image there.

Now that I have some guides for my navigation layer, I'm now going to draw my next AP div. We inserted this div by going to the Insert menu to layout objects and choosing AP Div here. But now if I come into the Layout section of the Insert bar, I'll find the Draw AP Div button. If I click that, notice my cursor turns into the crosshair. So, I'll just come in here and line this up with the guide. And, I'm going to click and drag out. You can notice it's just snapping to the guide there. We'll just drag all the way over here, and line it up with the other div, like so. And there's my second AP div. All I have to do is start inserting my images.

I'm going to go over to my Assets panel, and find the images. In this case, we want - The first one here is aboutus. We have several different aboutus images here. The ones that we want are the ones labeled with out. So, in this case we want aboutus-out. These labels will make much more sense when we get into the chapter on rollovers. We'll drag that in there. The next one is ourproducts. I'll find ourproducts-out, drag that in. Next one is abouttea. Right there. And the last one is brewingtea, like so.

Notice that they're not quite lining up to the tracing image here, and that's because the AP div doesn't have any styling that defines how the images should be aligned inside this particular div. The next step is to determine how everything in here should be aligned. Here in the CSS Styles panel, if I expand here you can see that we actually have styles for each one of our divs. Basically, every time you draw or insert any AP div, {italic}Dreamweaver {plain}automatically gives that div a name and creates a style which defines how to position that layer on the page. This is exactly where the AP div gets its information on where it should be positioned. Notice with AP 2 selected I can see that the height for it is set, the width for it is set, and most importantly, we have left and top.

Position is set to absolute, meaning that this is set to be 10 pixels from the left border of the window, and 15 pixels down from the top of the window. Just like if I select the apDiv1, this div it is set to be 509 pixels from the left border. If I look at my ruler that's just about 509 pixels right there, and it's again, set to be 15 pixels from the top. It's because of this rule that these AP divs know exactly where to stay, and because their position is set to absolute, they will never move from this position. But, we still need to add a rule so that the images inside this one AP div know how to align themselves.

So I'm going to come in here with apDiv2 selected. I'm going to choose Add Property, and in this case we want the text-align property, and I'll find it right here. The value we want in this case is going to be center. And you can see right away it lines up to center. The last thing I'll need to do it set the background color of the AP div area so that it matches the background color of these buttons. We'll come in here and add another property to apDiv2. This will be background color, and we'll just sample that color right off the image here. Like so.

And if I click off you'll see. Now the navigation has a solid background color that matches the images. Let's go ahead and save this and preview this in the browser. There it is. We have absolutely positioned divs here. So, no matter what size I make my window, those objects are staying exactly where they are. This is all done through CSS through AP divs. So this is what AP divs are really good for, putting objects on your page anywhere you want, and having them stay there. But, the downside to this is that with AP divs, it's nearly impossible to do something like centering your layout, because you never know how wide somebody's browser monitor is going to be. It's easy to keep things located in a particular place relative to the upper left-hand corner of your browser window. But, if you want to keep your layout centered on the page, that's almost impossible to do with just AP divs. That's one of the arguments for doing a lot of your layout with tables, and only using the occasional AP div here and there as required when you want something to be absolutely positioned. In the next movie we're going to start working with layout tables in {italic}Dreamweaver.{plain}

There are currently no FAQs about Dreamweaver CS3 Essential Training.

 
Share a link to this course

What are exercise files?

Exercise files are the same files the author uses in the course. Save time by downloading the author's files instead of setting up your own files, and learn by following along with the instructor.

Can I take this course without the exercise files?

Yes! If you decide you would like the exercise files later, you can upgrade to a premium account any time.

Become a member Download sample files See plans and pricing

Please wait... please wait ...
Upgrade to get access to exercise files.

Exercise files video

How to use exercise files.

Learn by watching, listening, and doing, Exercise files are the same files the author uses in the course, so you can download them and follow along Premium memberships include access to all exercise files in the library.
Upgrade now


Exercise files

Exercise files video

How to use exercise files.

For additional information on downloading and using exercise files, watch our instructional video or read the instructions in the FAQ.

This course includes free exercise files, so you can practice while you watch the course. To access all the exercise files in our library, become a Premium Member.

join now Upgrade now

Are you sure you want to mark all the videos in this course as unwatched?

This will not affect your course history, your reports, or your certificates of completion for this course.


Mark all as unwatched Cancel

Congratulations

You have completed Dreamweaver CS3 Essential Training.

Return to your organization's learning portal to continue training, or close this page.


OK
Become a member to add this course to a playlist

Join today and get unlimited access to the entire library of video courses—and create as many playlists as you like.

Get started

Already a member?

Become a member to like this course.

Join today and get unlimited access to the entire library of video courses.

Get started

Already a member?

Exercise files

Learn by watching, listening, and doing! Exercise files are the same files the author uses in the course, so you can download them and follow along. Exercise files are available with all Premium memberships. Learn more

Get started

Already a Premium member?

Exercise files video

How to use exercise files.

Ask a question

Thanks for contacting us.
You’ll hear from our Customer Service team within 24 hours.

Please enter the text shown below:

The classic layout automatically defaults to the latest Flash Player.

To choose a different player, hold the cursor over your name at the top right of any lynda.com page and choose Site preferencesfrom the dropdown menu.

Continue to classic layout Stay on new layout
Exercise files

Access exercise files from a button right under the course name.

Mark videos as unwatched

Remove icons showing you already watched videos if you want to start over.

Control your viewing experience

Make the video wide, narrow, full-screen, or pop the player out of the page into its own window.

Interactive transcripts

Click on text in the transcript to jump to that spot in the video. As the video plays, the relevant spot in the transcript will be highlighted.

Are you sure you want to delete this note?

No

Thanks for signing up.

We’ll send you a confirmation email shortly.


Sign up and receive emails about lynda.com and our online training library:

Here’s our privacy policy with more details about how we handle your information.

Keep up with news, tips, and latest courses with emails from lynda.com.

Sign up and receive emails about lynda.com and our online training library:

Here’s our privacy policy with more details about how we handle your information.

   
submit Lightbox submit clicked
Terms and conditions of use

We've updated our terms and conditions (now called terms of service).Go
Review and accept our updated terms of service.