Professional Documents
Culture Documents
Basics 2011
Dreamweaver Basics
Introduction
Adobe Dreamweaver CS4 is a web authoring software that aids in the creation and maintenance of web pages. Dreamweaver uses tools similar to those found in a word processing program to allow for the development of web pages without knowledge of HTML. It also provides the option of hand-editing the HTML for greater control of the document.
Contents
Table of Contents
Introduction ..................................................................................................................................... 1 Contents .......................................................................................................................................... 1 Opening Dreamweaver ................................................................................................................... 2 Defining a Site ................................................................................................................................ 2 The Dreamweaver Work Area ........................................................................................................ 8 Modifying Page Properties ........................................................................................................... 11 Formatting Text ............................................................................................................................ 16 Using Text from Microsoft Word ................................................................................................. 18 Saving Pages ................................................................................................................................. 20 Adding Links ................................................................................................................................ 21 Adding Email Links ...................................................................................................................... 23 Adding Anchors ............................................................................................................................ 23 Inserting Images ............................................................................................................................ 25 Inserting Tables ............................................................................................................................. 27 Laying Out a Page ......................................................................................................................... 29 Previewing Your Site .................................................................................................................... 30 Uploading Files ............................................................................................................................. 31 Viewing Your Published Site........................................................................................................ 33
Page 1
Defining a Site
T There are tw wo parts to your y website e your loc cal files, and d your remo ote files. You u create loca al files o on your com mputer using g Dreamwea aver, and up pload them to your rem mote web sp pace via SFT TP ( (secure file transfer t pro otocol). It is very impor rtant that th he files on your local computer are set u up exactly the t same as a the files on your rem mote web s server. Tha at is, that th hey are all in the s same location relative e to each ot ther. B Before you can c upload local files to o a web serv ver, you mu ust create w what Dreamw weaver calls s a Site F File. Site Fil les contain information about wher re your files s are stored locally, whe ere they are e stored r remotely, an nd how they y will be tran nsferred bac ck and forth between yo our compute er and the w web s server. You should do this t before you y create your y first we eb page. A All UM stude ents, faculty y and staff have h free we ebsite space e available to them from m ITCS. We e will u utilize this sp pace in toda ays worksh hop. The UR RL of your p ersonal web bsite space is h http://www-personal.u umich.edu/~ ~youruniqu uename/. A All of your website w files will be stored in the Pu ublic/html fo older of your r IFS space. Please see h http://www-p personal.um mich.edu/~pa attyb/websp pace.html fo or instruction ns on check king your we eb s space. If you u do not hav ve an html folder, f pleas se contact IT TCS. If you need to work on a web page e on the SPH H web serve er, I will help p you set up p your site f file d definition.
T To create a new Site File, click the Manage Sites link in y your Files P Panel.
T The Manage e Sites dialo ogue window w will come up. Click N New. The Site Definitio on wizard w will come u up:
Page 2
Site Site Nam me: Give yo our site a de esired name e. Type in a name that provides a meaningful description of your site. s Local Si ite Folder: This T is where you will store s the loc cal copies o of your files. Click the fo older ect it. icon and d navigate to o your perso onal space. Create a fo older there f for your proj ject and sele
Page 3
Click the e plus sign (+) to add a new serve er. This nex xt set of que estions refer r to the remo ote web ser rver you are e using. This s will be the ITS web serv ver: Server S name e: does not matter m Connect C usin ng SFTP SFTP S addres ss of your web w server is s sftp.itd.um mich.edu Username U is s your UM uniqname u Password P is your Kerbe eros passw word Root R director r: Public/html/
Page 4
Click k the Test bu utton. If you u have enter red all of the e informatio on in succes ssfully, you w will see a me essage sayin ng that you have conne ected succe essfully. Clic ck OK and then Next.
Page 5
Do you y want to o enable checking in and a checkin ng out files s? Only say y yes to this ques stion if you will w not be th he only pers son updating g this websi ite. Enabling g checking in and checking out ma akes it so that only one person can n edit a sing gle file at the e same time e. Click Next t.
Page 6
Y You will see e a summary y of your Sit te Files definition. If eve erything loo oks good, cli ick Done. Y You can mo odify your Site Files def finition at an ny time by g oing to Man nage Sites in the Files s Panel. T This will brin ng up the Site Definition n dialogue box, b where y you can ma ake the desired change es. You c can also hav ve as many different Si ite Files as needed.
Page 7
D Document Window W T The Docume ent Window w is your work area whe ere you crea ate and edit your web p page. D Dreamweav ver has the option o to dis splay the Do ocument Wiindow in thr ree different t ways: the c code v view, the de esign view, and a the code and desig gn view. Th he code view w shows HT TML only. T The d design view shows only y the design n, or the visu ual layout of f your page. The code and design n view s shows a com mbination of f the two.
Page 8
Insert Pane el The T Insert Panel P allows s you to inse ert web obje ects into you ur web pages, p such h as images s, forms and d media. Eac ch Group (s such as common listed here) c contains a g group of spe ecific objects. The Common C group has eve erything you u will need t today.
Files s Panel The Files Pane el is more th han a file bro owser. It allo ows you to see the struc cture of all the t files and d directories s in your website. You c can open n, move, co opy, rename e and delete e files from t the Files Pa anel. We will talk t more ab bout your S ite Files late er in the workshop.
P Properties Panel T The Propert ties Panel provides deta ails of the properties p of f a selected object. The Properties s Panel w will change depending on o the objec ct or text tha at is selecte ed.
Page 9
D Document Toolbar T T The Toolbar r allows you u to toggle between b view ws, and sho ows the title e of the docu ument. It also has s shortcut icon ns that allow w you to upl load and do ownload you ur file, and p preview the page in a b browser.
O Other Pane els There e are several additiona al panels on the left side e of the wor rk area, including Desig gn, Code e, Applicatio on, and Tag Inspector. These T pane els are desig gned to provide additio onal inform mation abou ut Web Dev velopment. For F example e, the Code Panel allow ws you to look up HTML tags, CSS S syntax, Ja avascript syntax, and m much more. W We will not cover these e panels durin ng this works shop.
W Working wi ith Panels Occa asionally, a panel will be ecome deta ached from m the workspace and be ecome a flo oating windo ow. This can be annoying because e the panel is always o on top, block king your vie ew of the page. p To re-attach a panel, click the e Designer r button at th he top of the e window, a and choo ose Reset:
Page 10
O On the left side s of the Page P Proper rties window w are severa al categorie es of page p properties. T The first o one is Appe earance (CS SS). Here yo ou can choo ose the defa ault font-fam mily, font siz ze, font colo or, b background color, back kground ima age and all four f margins s for your do ocument. Y You can still use d different fonts and color rs in differen nt parts of your y web pa age. This jus st sets the d default settin ngs for t the entire pa age. F Font Famili ies Y You will noti ice that whe en you click the carrot for f page fon nt, there are not many f fonts on the list. T This is beca ause the font you choos se will only display d in th he user's bro owser if the user has th hat font installed on their machine. You ma ay also notic ce that each h item in the e list contain ns more than n one f font, for example, "Arial l, Helvetica, , sans-serif." Sans serif f is what is k known as a font family, , as are s serif, fantasy y, script and d monospac ce. By choosing "Arial, Helvetica, s sans-serif," you are say ying "If t the user has s Arial installed, display y my text in Arial. If they y don't have e Arial, but t they have H Helvetica, display my te ext in Helvet tica. If they don't have A Arial or Helvetica, disp play my text in w whatever sa ans-serif fon nt they have chosen as their defaullt.
Page 11
Y You can clic ck the color wheel at the e top of the color picke er to find add ditional colo ors. B Background Images P Please note that background images tile on a web page. That means s that they d display over r and o over in rows s and columns. If you use a backgr round image e, make sur re that it is a small (usu ually a around 100 pixels by 10 00 pixels) and will blend d well when n tiled.
Page 12
H Here you ca an change th he font face e, size and color c of the f four link sta ates: Linke ed color: the e color of lin nked text Visite ed links: the e color of links to pages s that the us ser has alrea ady visited Rollo over links: th he color of li inks while th he user is ro olling their m mouse over them Activ ve links: the color of link ks while they y are being clicked on
You can also select t an Underlin ne style. The default is that links a are always u underlined, w which users ex xpect, but yo ou can chan nge it so tha at links are n never under rlined, are o only underlin ned during mouse m rollov ver, or are underlined ex xcept during g mouse rol llover. It is perfe ectly accept table to leav ve these all on their def faults (whic ch is blue un nderlined tex xt for links and d purple und derlined text t for visited links) but fe eel free to play around w with these s settings. What is most import tant is that your y visited link color is s different fr rom your reg gular link co olor. This is a visua al clue to us sers that the ey have alre eady visited a page.
Page 13
H Headings ar re used for page p titles, section title es, sub-sectiion titles, an nd so on. Th hey are use ed to s structure your web page e. HTML off fers six leve els of headin ngs, with He eading 1 be eing the largest and H Heading 6 being b the sm mallest. I rar rely use mor re than thre ee levels of h headings to o structure w web p pages. In the image e above I ha ave set the heading h fon nt, specified that all hea adings should be bold, a and set t the font size es for headin ngs one thro ough three. Note that I again used d the em me easurement of font s size so that users can increase and d decrease the size of the text. O Once your selections s ha ave been made, m press Apply to ap ttings to the page and O OK to pply the set a accept the changes. c
Page 14
E Enter the tex xt that you want w to appear in the title bar in th e Dreamwe eaver title bo ox:
W Whatever yo ou enter the ere will appe ear in the we eb browser''s title bar. U Use short bu ut descriptiv ve page t titles.
Page 15
Font Type
Font Size
Color
F Formatting Headings and Paragr raphs T The first thin ng you want t to put on your y web pa age is the pa age title. Put your curso or in the doc cument w window and type in the page title. Next N click th he drop-dow wn for the Fo ormat property in the P Properties Panel. P Here you see your choices: paragraph format, any y of the six le evels of hea adings, a and Preform matted. Since the level 1 heading is s the highes st level, it sh hould be use ed for page titles. C Choose Hea ading 1 in th he Format drop-down d list:
Page 16
Page 17
t entire co ontents of a Word file into your we eb page, ple ease If you want to place the your curs sor where yo ou want the text to go o on the page e and click th he File drop p-down menu an nd choose Im mport -> Word Docum ment. You w will be promp pted to navigate to
Page 18
Its fine to o leave the default d setti ings intact a and click OK K button to r run the com mmand. 3. Run the text throug gh NotePad d or WordP Pad first. A t third alterna ative is simp ply to paste the e text copied d from Word d into either NotePad or Wordpad, then copy it from f the there and d paste it int to Dreamwe eaver. You w will lose som me formattin ng, but all of nasty Wo ord code will be gone.
Page 19
If you are saving your work to your personal space on the UM web server, you may notice that you already have a file in your file list called index.html. It is fine to over-write this file. You cannot have two index files in your html folder, one named index.htm and the other named index.html. You should have only one default home page file. Once you have your page properties and formatting set, an easy way to create secondary pages is to click the File drop-down menu and choose Save As Give the page a new file name and edit its content appropriately.
Page 20
The Hyperlink H di ialogue box x will open. Here H you wiill need to ty ype in the text that t you wan nt to be clickable in the e Text field the fu ull URL of th he webpage e you want to t link to in t the Link fie eld the Target T field allows you to have the e link open i n a new win ndow by cho oosing _bla ank. If you do d not want the link to open o in a ne ew window, leave the T Target field blank. Text that describ bes the link into the Titl le field (this s can be the e same as th he text you want to be clickable) You may leave the t Tab Index and Acc cess Key fie elds blank.
Page 21
I If you need to t link to ano other page in n your site, you y can click k the folder icon next to o the link fiel ld and n navigate to th hat file. You u can also cli ick the Point to File ico n and drag i it to the page e you want to o link to in the Files Panel P .
Page 22
T The Email Link L dialogue e box will op pen. Type in n the text th hat you want t to be click kable, and th he em mail address s, and click OK.
N Note: Email links are of ften harvest ted by robot ts that searc ch the web, collecting e email addres sses for s spammers.
Page 23
L Linking to a Named Anchor In the Docum ment window, select the text you would w like ac ctivated as a link. In th he Link Field d of the P Properties Panel, P type the t number sign (#) followed by th e name of y your anchor r (e.g. type # #top in t the Link field d if you nam med your anchor top).
Page 24
Page 25
C Changing th he value of the t Align fie eld to Left will w make tex xt wrap arou und your ima age on the right. S Similarly, ch hanging the value of the e Align field d to Right w ill make tex xt wrap arou und your ima age on t the left.
Page 26
T The Insert Table T dialogue window allows you to control a ll aspects o of your table: how many y rows a and columns s it has, how w wide it is, whether or not it has a border, and if it does, how thick that b border is, ho ow much sp pace there is s between cells c (cellspa acing), how w much spac ce there is b between a cells content and the edge of the e cell (cellpa adding), hea ader rows a and/or colum mns, and mo ore. Text
Page 27
Page 28
Y You can use e any of these sample designs d to create c your own web pa ages. Just r replace the sample t text with you ur own text, and add im mages. U Using a Consistent Pa age Design n for Multiple Pages
O Once you have h gotten your first page p format tted the wa ay you like it t, you can u use it as a t template for r other pages in your web w site. Af fter saving the file, clic ck the File drop-down menu a and choose e Save As and save e it with a ne ew file nam me. Now you u have a ne ew file and a new p page. Chan nge the content approp priately. Re emember to o save the p page title fo or the title bar as w well.
Page 29
Page 30
Up ploading Files
O Once your site s has bee en defined, you y can pub blish your sit te. This me eans you ca an transfer y your files t to a server so s others may have acc cess to your web site th hrough the Internet. Y Your Files Panel P is alw ways visible on the left side s of the D Dreamweav ver work are ea. You can n see b both your local and rem mote files at any time by y clicking the e Expand/C Collapse but tton at the to op of the F Files Panel.
C Clicking the Expand/Co ollapse butto on will open a Site Win ndow with tw wo panes, o one for the L Local F Folder and one for the Remote Site. L Local Folde er T The Local Folder appea ars on the ri ight-hand side of the w indow and c contains a list of the file es s stored on yo our compute er or networ rk. R Remote Site T The Remote e Site appea ars on the le eft-hand side of the win ndow and sh hows a list o of the files s stored on t the server. Until you co onnect to the server, the Remote S Site side of t the window will remain blank.
Page 31
Local Folder
T To connect to the serve er and view the Remote e Site, click the Connec ct button in the Site Files t toolbar.
Connect Button
Put File(s)
O Once you ha ave connected to the server, you can c transfer r files from the Local Fo older to the Remote S Site and vice e versa. Yo ou can do th his by dragg ging selecte d files from one pane to the other, or by u using the Ge et File(s) an nd Put File( (s) buttons in the toolba ar. W When you tr ransfer files to the server, you will be asked if you want to o Include D Dependent F Files. Including De ependent Files means that t all the files f depend dent on the file you are transferring g ( (images, ext ternal style sheets) will also be transferred to the server. K Keep in mind that when n you transfe er files, you overwrite t he existing file. Make s sure you do o not t. c copy over th he most rece ent version, or the edits s will be lost
Page 32
Page 33