|
pageoneresults -> RE: Applying CSS in FP (6/3/2003 20:12:02)
|
[url=" http://www.csstips.com/frontpage/images/fp-styling-menu.gif" ]FrontPage Styling Menu[/url] The above is a screenshot from my FP2002. I believe FP2000 also has the styling menu in the upper left hand corner, it has been too long! Once your external style sheet (file.css) is set up and then linked to properly from the head of your document, any page you open that references that style sheet will show the styles in the styling menu. You' ll notice that I' ve included some span elements so that you can see what happens when you set up span specific classes. The a indicator now appears to the left of those span.classnames. I also dropped in a general color for green. Note how it does not have an indicator to the left of it. This is where the problem lies. FP has no way of knowing that you are wrapping a word(s) in a span element while in normal view. The only way it knows is to specify span.green so that now you have a specific class for coloring text. You and I both know that we can specify .green in our stylesheets which allows us to wrap any text in a <span> container and achieve green. All of that is of course done via hand in html view. But, the WYSIWYG interface of FP does not allow that functionality. You need to be specific. span.red{color:#f00;bakcground:transparent;} span.green{color:#090;background:transparent;} Doing the above in your stylesheet will now classify that as a specific span class and will appear in the FP styling menu with an a indicator to the left of it. The user would highlight the text they want to make green, and then select the a green from the styling menu. If that span.class is not specifically named, the <span></span> containers need to be added manually in html view. <span> is an inline element. If you are applying styles to text in FP, you have to have specific span.class names for the styling menu to function properly (a green). If you want to apply color to block level elements, you would specify block level specific classes, for example... p.red{color:#f00;bakcground:transparent;} p.green{color:#090;background:transparent;} Your styling menu will now show the words red and green but instead of an a indicator, they will now have a block level indicator (¶). If I just position my cursor in front of a paragraph and select that ¶ green from the menu, the entire paragraph will turn to green. Front page will now change the <p> tag to <p class=" green" >. Remember, it is a block level element so I can click anywhere within the block and style it. If I am styling text, I have to highlight that text (select it) and choose a green from the styling menu. P.S. I should point out that there are some fundamental flaws in FP' s styling menu. It treats all block level elements as <p> so trying to use the styling menu for block level elements will not work. Sure, you could do p.red but if you try to apply that ¶ red to let' s say a <li> which is also block level, it wraps the <li> in a <p> tag. This is where html coding gets totally thrashed. I' m hoping for better support in the new version of FP. We shall see...
|
|
|
|