.p tag

I’ve used FW for many years and am showing a client how to use it. This is throwing up issues which I should know about:

I’ve styled the .p tag. And text is automatically styled with the .p tag. But in the Styles pallet the .p tag text isn’t highlighted as having that style (nothing is highlighted). And if I style text as (say) .h1, the only way I can get that back to .p is by selecting [nostyle].

Why isn’t .p text highlighted in the Styles pallet and why can I not style text with the .p tag (I have to use [nostyle])??

I just know my client will think this is bonkers.

Mark


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Hi Mark
the p tag defines a paragraph (note no dot in front). This tag is used and created by freeway when you hit the “publish the site” button. You can change and add attributes to the p tags specification but it is meant as an overall specification. Normally you would add the overall colour of the pages text, the general size or its justification… that sort of thing.
if you wanted to apply specific attributes to certain areas then you could use a .class style or if it was a title then you could use one of the h tags (and again these don’t have dots in front)

So lets say in your example you applied a h1 style within the inspector palette then the out-put would look something like this:

  <h1 class="f-lp">max was here</h1>

but if you were to remove the h1 style from around the text within the inspector palette the html out-put would be written like this:

  <p class="f-lp">max was here</p>

Freeway automatically adds paragraph tags around text and there for you should need to apply it specifically because it a global style… So if you had added color:red to the p style then all the text in your document that did not have a specified style applied to it would be coloured red.

I hope this makes thing clearer
all the best max


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Hi Max

Yes I get all of that, but

Why doesn’t the Style pallet show that text is styled with a p tag? (text with a h1 tag is highlighted as being h1, but not p text)

Why can I not apply p style to my text? It comes up with an error? We have to use the ‘NoStyles’ to get a p style.

If I have styled text, say h1, why do I have to click, ‘NoStyle’ in the Styles pallet, rather than p style to get back to my body text style?


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

On 28 Feb 2011, at 16:47, Mark wrote:

Why can I not apply p style to my text? It comes up with an error? We have to use the ‘NoStyles’ to get a p style.

The p style is an integral style; it’s understood, it’s a kind of ‘given’, which is why it has no ID or class dot in from of it. The body style is the same, as are the h1 through 6 styles, although I don’t know why the h styles are selectable in Freeway like that; someone else here will chime in, no doubt. Probably because you have to apply them yourself; Freeway can’t guess that you want an h1 tag like it can know that you want a p tag.

When you type a paragraph of text, when you hit Return, Freeway automatically puts p tags around it, and it then ‘takes on’ the p tag. You can’t apply it, it’s a given. You can edit the p style to be whatever you want, but as long as you’re typing and hitting Return, you’ll get the p tag applied by Freeway. So, if your text has Returns between paragraphs, by choosing ‘No Style’ you’re actually choosing the p tag, by default.

I could probably have put that better, but I hope you get the gist of it.

best wishes,

Paul Bradforth

Buy my eBooks at:
http://www.paulbradforth.com/books/


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Hi Max and Paul

Thanks for your time. I kind of get it, but I think my client will think it is just weird and that something is wrong with the software.

Thanks once again

Mark


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

On 28 Feb 2011, at 17:19, Mark wrote:

Thanks for your time. I kind of get it, but I think my client will think it is just weird and that something is wrong with the software.

Assure him that there isn’t! It’s all part of the grand design of CSS.

I’d like to write more, but I interact with the forum via email and I suspect the forum software does something to code; I seem to remember something about four tildes, but can’t find it when I log into the forum.

best wishes,

Paul Bradforth

Buy my eBooks at:
http://www.paulbradforth.com/books/


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Found it! What I wanted to go on to say was:

It’s where the ‘Cascading’ bit of ‘Cascading Style Sheeets’ comes in. For instance, if you had CSS that said:

body {
font-size: 1em;
}

… that would set a basic font size for the entire site, that is, everything between the opening and closing body tags, and like the p tag, you wouldn’t have to apply it, it would apply itself. If you then had a DIV or container on your page with the ID (Freeway name) of, say, ‘maincontent’, you could write:

#maincontent p {
font-size: 1.2em;
line-height: 1.4em;
color: #4c4c4c;
}

… and it would apply ONLY within that container, and only to paragraphs; that CSS would be read by the browser after the initial ‘body’ CSS and would override it. Similarly, this:

#maincontent ul {
whatever;
}

… would apply only to HTML lists within that same container, whereas:

ul {
color: grey;
}

… would apply to all lists throughout the site, unless you’d overridden them as above.
I’m not an expert at this, and I hope I’ve got it right; someone’ll slap me if I haven’t, I expect. Anyway, hope it helps.


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Hi Paul and Max

I’ve relooked at this thread. Thanks for your time.

I found the following Softpress knowledgeBase article:

suggesting that we use a body tag as a basis for text styles.

The body tag will automatically style all text for the entire site (that is, everything between the opening and closing body tags).

We can achieve the same result (automatic styling for all text) by applying style attributes to the p tag.

Is one way ‘better’ than the other?


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

On 17 Aug 2011, at 10:45, Mark wrote:

The body tag will automatically style all text for the entire site (that is, everything between the opening and closing body tags).

We can achieve the same result (automatic styling for all text) by applying style attributes to the p tag.

Is one way ‘better’ than the other?

Mark, I think you might have answered your own question—the body tag will affect everything, but the p tag will only affect paragraphs, and not everything on the site will be a paragraph, so you may find it not working in places.

best wishes,

Paul Bradforth

Buy my eBooks at:
http://www.paulbradforth.com/books/


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Hi Paul

I was just wondering which option is best for my base style, before creating headings etc. (all text on a site will start as a paragraph, before I apply headings?)

I’m guessing it doesn’t really matter.

Mark


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

On 17 Aug 2011, at 12:27, Mark wrote:

Hi Paul

I was just wondering which option is best for my base style, before creating headings etc. (all text on a site will start as a paragraph, before I apply headings?)

I’m guessing it doesn’t really matter.

Personally, I just style the p tag and a couple of headers, but there are folks here who are much more knowledgeable than me, so maybe someone’ll chip in …

best wishes,

Paul Bradforth

Buy my eBooks at:
http://www.paulbradforth.com/books/


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Thanks for that. If that’s what you do, I’ll do it too.

Cheers

Mark


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Freeway conflates the ideas of tags and styles – a little bit too
much for my taste. When you select some “paragraphs of text” in your
layout, and you style them as a list, they stop being P tags and
become LI tags inside of either a UL or an OL tag. Fundamentally
different, in other words. If your style only applies to the P tag,
then all of tho text inside your list will be default styled, probably
16px Times. Similarly, if you apply one of the h1, h2, h3 “styles” to
a line of text, it stops being a P and becomes an h1 or whatever. The
only styles you can apply without worrying about changing the tag are
any that begin with a dot in their name. Those are class styles, so
you end up with a tag like this:

<p class="bigRedBold">some text</p>

So if you want to set one font for the entire plage, you would be best
served to set it in the body tag. That way, any style that does not
explicitly set a font will “inherit” this setting from the body – the
court of last resort in the cascade of styles.

But this is a very weak preference, so any other tag that you want to
set to a different font can override it. Generally, the closer a style
definition is to the text it refers to, the more authority it has.
Think of it like this – the dog-catcher in your borough has more
authority over your dog than the mayor, or your senator, or the
president.

Walter

On Aug 17, 2011, at 7:27 AM, Mark wrote:

Hi Paul

I was just wondering which option is best for my base style, before
creating headings etc. (all text on a site will start as a
paragraph, before I apply headings?)

I’m guessing it doesn’t really matter.

Mark


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options


freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options