dwt says it's not there; code shows it is(?)

G

Guest

Working through my first major learning on CSS and the use of DWTs, I've
moved almost all of the basic structure of one of my sites to a DWT and
cleaned out almost all the formatting in the html and linked it to styles in
a CSS sheet. I'm now cleaning up the pages and have a couple editable
regions from the DWT that had an extra paragraph mark AFTER the region's
editable area. In other words, it looked that there was a <p> in the DWT in
the editable region but, when viewed from the actual web page it wasn't
inside the editable region (when I hovered over it I got the DO NOT ENTER
symbol). My assumption was that somehow there was a <p> in DWT but when I
went there to check: no <p>. So back to the code on the actual page and sure
enough there was an extra <p>nbsp; at the end of the region. The problem was
that is shows in the shaded area (i.e. implies that it's in the DWT).

I can delete the extra html in the page but of course get warned that I'm
making changes in a non-editable area and am offered the choice of either
restoring the original code on save or accepting the changes. I accept the
changes and the code is wonderfully removed, but it looks like I'm going to
have to do this to each individual page that somehow has inherited the extra
code from somewhere.

I did test to see if forcing a save of the DWT (thus updating each page it's
attached to) would clean things up (since the DWT actually is correct) but
the extra code remains.

Does anyone know how this stuff got there so I can avoid it in the future
and is there a way, other than changing each actual page, to get the code
removed.

Thanks

Tom
 
G

Guest

tcarp said:
Working through my first major learning on CSS and the use of DWTs, I've
moved almost all of the basic structure of one of my sites to a DWT and
cleaned out almost all the formatting in the html and linked it to styles in
a CSS sheet. I'm now cleaning up the pages and have a couple editable
regions from the DWT that had an extra paragraph mark AFTER the region's
editable area. In other words, it looked that there was a <p> in the DWT in
the editable region but, when viewed from the actual web page it wasn't
inside the editable region (when I hovered over it I got the DO NOT ENTER
symbol). My assumption was that somehow there was a <p> in DWT but when I
went there to check: no <p>. So back to the code on the actual page and sure
enough there was an extra <p>nbsp; at the end of the region. The problem was
that is shows in the shaded area (i.e. implies that it's in the DWT).

I can delete the extra html in the page but of course get warned that I'm
making changes in a non-editable area and am offered the choice of either
restoring the original code on save or accepting the changes. I accept the
changes and the code is wonderfully removed, but it looks like I'm going to
have to do this to each individual page that somehow has inherited the extra
code from somewhere.

I did test to see if forcing a save of the DWT (thus updating each page it's
attached to) would clean things up (since the DWT actually is correct) but
the extra code remains.

Does anyone know how this stuff got there so I can avoid it in the future
and is there a way, other than changing each actual page, to get the code
removed.

Thanks

Tom


Addendum:

I've done some further testing and found that the <p>nbsp; came back when
the DWT associated with the page was resaved. Since the code isn't actually
in the DWT but it shows up in the uneditable portion of the page it looks
like FP is forcing the <p>nbsp; to be generated somehow.

The bottom line is that deleting the code from the page (and forcing it to
be accepted) gets overridden if the DWT is resaved.

Tom
 
S

Stefan B Rusynko

The <p> tag is being added to the DWT when you save it
- open the DWT in browser and view source to see it

Usually added because your editable region is
not is a valid html block level container
- like a <div> or <p> or <td) , etc
has an open html tag in it w/ no closing tag
or has a space after it

Make sure the editable region is clean and has no extra spaces or line breaks after it as say

<div>
<!-- #BeginEditable "content" --><p>some sample text</p><!-- #EndEditable -->
</div>


--

_____________________________________________
SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
"Warning - Using the F1 Key will not break anything!" (-;
To find the best Newsgroup for FrontPage support see:
http://www.frontpagemvps.com/FrontPageNewsGroups/tabid/53/Default.aspx
_____________________________________________


|
|
| "tcarp" wrote:
|
| > Working through my first major learning on CSS and the use of DWTs, I've
| > moved almost all of the basic structure of one of my sites to a DWT and
| > cleaned out almost all the formatting in the html and linked it to styles in
| > a CSS sheet. I'm now cleaning up the pages and have a couple editable
| > regions from the DWT that had an extra paragraph mark AFTER the region's
| > editable area. In other words, it looked that there was a <p> in the DWT in
| > the editable region but, when viewed from the actual web page it wasn't
| > inside the editable region (when I hovered over it I got the DO NOT ENTER
| > symbol). My assumption was that somehow there was a <p> in DWT but when I
| > went there to check: no <p>. So back to the code on the actual page and sure
| > enough there was an extra <p>nbsp; at the end of the region. The problem was
| > that is shows in the shaded area (i.e. implies that it's in the DWT).
| >
| > I can delete the extra html in the page but of course get warned that I'm
| > making changes in a non-editable area and am offered the choice of either
| > restoring the original code on save or accepting the changes. I accept the
| > changes and the code is wonderfully removed, but it looks like I'm going to
| > have to do this to each individual page that somehow has inherited the extra
| > code from somewhere.
| >
| > I did test to see if forcing a save of the DWT (thus updating each page it's
| > attached to) would clean things up (since the DWT actually is correct) but
| > the extra code remains.
| >
| > Does anyone know how this stuff got there so I can avoid it in the future
| > and is there a way, other than changing each actual page, to get the code
| > removed.
| >
| > Thanks
| >
| > Tom
|
|
| Addendum:
|
| I've done some further testing and found that the <p>nbsp; came back when
| the DWT associated with the page was resaved. Since the code isn't actually
| in the DWT but it shows up in the uneditable portion of the page it looks
| like FP is forcing the <p>nbsp; to be generated somehow.
|
| The bottom line is that deleting the code from the page (and forcing it to
| be accepted) gets overridden if the DWT is resaved.
|
| Tom
 
G

Guest

Stefan B Rusynko said:
The <p> tag is being added to the DWT when you save it
- open the DWT in browser and view source to see it

Usually added because your editable region is
not is a valid html block level container
- like a <div> or <p> or <td) , etc
has an open html tag in it w/ no closing tag
or has a space after it

Make sure the editable region is clean and has no extra spaces or line breaks after it as say

<div>
<!-- #BeginEditable "content" --><p>some sample text</p><!-- #EndEditable -->
</div>


--

_____________________________________________
SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
"Warning - Using the F1 Key will not break anything!" (-;
To find the best Newsgroup for FrontPage support see:
http://www.frontpagemvps.com/FrontPageNewsGroups/tabid/53/Default.aspx
_____________________________________________


|
|
| "tcarp" wrote:
|
| > Working through my first major learning on CSS and the use of DWTs, I've
| > moved almost all of the basic structure of one of my sites to a DWT and
| > cleaned out almost all the formatting in the html and linked it to styles in
| > a CSS sheet. I'm now cleaning up the pages and have a couple editable
| > regions from the DWT that had an extra paragraph mark AFTER the region's
| > editable area. In other words, it looked that there was a <p> in the DWT in
| > the editable region but, when viewed from the actual web page it wasn't
| > inside the editable region (when I hovered over it I got the DO NOT ENTER
| > symbol). My assumption was that somehow there was a <p> in DWT but when I
| > went there to check: no <p>. So back to the code on the actual page and sure
| > enough there was an extra <p>nbsp; at the end of the region. The problem was
| > that is shows in the shaded area (i.e. implies that it's in the DWT).
| >
| > I can delete the extra html in the page but of course get warned that I'm
| > making changes in a non-editable area and am offered the choice of either
| > restoring the original code on save or accepting the changes. I accept the
| > changes and the code is wonderfully removed, but it looks like I'm going to
| > have to do this to each individual page that somehow has inherited the extra
| > code from somewhere.
| >
| > I did test to see if forcing a save of the DWT (thus updating each page it's
| > attached to) would clean things up (since the DWT actually is correct) but
| > the extra code remains.
| >
| > Does anyone know how this stuff got there so I can avoid it in the future
| > and is there a way, other than changing each actual page, to get the code
| > removed.
| >
| > Thanks
| >
| > Tom
|
|
| Addendum:
|
| I've done some further testing and found that the <p>nbsp; came back when
| the DWT associated with the page was resaved. Since the code isn't actually
| in the DWT but it shows up in the uneditable portion of the page it looks
| like FP is forcing the <p>nbsp; to be generated somehow.
|
| The bottom line is that deleting the code from the page (and forcing it to
| be accepted) gets overridden if the DWT is resaved.
|
| Tom


Hi Stephen

Unfortunately, I don't think that's it. At least the DWT doesn't contain
the <p>.

This is the code from the DWT:

<div id="intro">
<div id="quicksummary">
<!-- #BeginEditable "quicksummary" -->(quicksummary)<!--
#EndEditable -->
</div> <!--quicksummary-->
<div id="preamble">
<!-- #BeginEditable "preamble" -->(preamble)<!-- #EndEditable -->
</div> <!--preamble-->

</div> <!--intro-->


As you can see there is no <p> in any of the <div>s here.

This, however, is the code from the page that has the DWT attached (I've
removed most of the text):

<div id="intro">
<div id="quicksummary">
<!-- #BeginEditable "quicksummary" -->quicksummary text is
here<!-- #EndEditable -->
</div> <!--quicksummary-->
<div id="preamble">
<!-- #BeginEditable "preamble" --><p>Preamble text is here</p>
<!-- #EndEditable --><p> </div> <!--preamble-->

</div> <!--intro-->

If you look at the <!--- #EndEditable --> you will see the <p>&nbsp. In the
page's code, this is "browned" out indicating that it is in the DWT (and in
Design mode I get the do not enter when I hover over the paragraph mark).
But, as you can see, no such code exists in the DWT.

If I delete the <p>&nbsp in the page's code and force it to be accepted, it
disappears from the page but comes back the next time I make a change to the
DWT.
 
S

Stefan B Rusynko

Caused by your comments
(where FP also inserts thr &nbsp & <p> tags if thry are not in a container)
Try changing it to
<div id="intro"><!--intro-->
<div id="quicksummary"><!-- #BeginEditable "quicksummary" --><!--quicksummary--><!-- #EndEditable --></div>
<div id="preamble"><!-- #BeginEditable "preamble" --><!--preamble--><!-- #EndEditable --></div>
</div>

--

_____________________________________________
SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
"Warning - Using the F1 Key will not break anything!" (-;
To find the best Newsgroup for FrontPage support see:
http://www.frontpagemvps.com/FrontPageNewsGroups/tabid/53/Default.aspx
_____________________________________________


|
|
| "Stefan B Rusynko" wrote:
|
| > The <p> tag is being added to the DWT when you save it
| > - open the DWT in browser and view source to see it
| >
| > Usually added because your editable region is
| > not is a valid html block level container
| > - like a <div> or <p> or <td) , etc
| > has an open html tag in it w/ no closing tag
| > or has a space after it
| >
| > Make sure the editable region is clean and has no extra spaces or line breaks after it as say
| >
| > <div>
| > <!-- #BeginEditable "content" --><p>some sample text</p><!-- #EndEditable -->
| > </div>
| >
| >
| > --
| >
| > _____________________________________________
| > SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
| > "Warning - Using the F1 Key will not break anything!" (-;
| > To find the best Newsgroup for FrontPage support see:
| > http://www.frontpagemvps.com/FrontPageNewsGroups/tabid/53/Default.aspx
| > _____________________________________________
| >
| >
| > |
| > |
| > | "tcarp" wrote:
| > |
| > | > Working through my first major learning on CSS and the use of DWTs, I've
| > | > moved almost all of the basic structure of one of my sites to a DWT and
| > | > cleaned out almost all the formatting in the html and linked it to styles in
| > | > a CSS sheet. I'm now cleaning up the pages and have a couple editable
| > | > regions from the DWT that had an extra paragraph mark AFTER the region's
| > | > editable area. In other words, it looked that there was a <p> in the DWT in
| > | > the editable region but, when viewed from the actual web page it wasn't
| > | > inside the editable region (when I hovered over it I got the DO NOT ENTER
| > | > symbol). My assumption was that somehow there was a <p> in DWT but when I
| > | > went there to check: no <p>. So back to the code on the actual page and sure
| > | > enough there was an extra <p>nbsp; at the end of the region. The problem was
| > | > that is shows in the shaded area (i.e. implies that it's in the DWT).
| > | >
| > | > I can delete the extra html in the page but of course get warned that I'm
| > | > making changes in a non-editable area and am offered the choice of either
| > | > restoring the original code on save or accepting the changes. I accept the
| > | > changes and the code is wonderfully removed, but it looks like I'm going to
| > | > have to do this to each individual page that somehow has inherited the extra
| > | > code from somewhere.
| > | >
| > | > I did test to see if forcing a save of the DWT (thus updating each page it's
| > | > attached to) would clean things up (since the DWT actually is correct) but
| > | > the extra code remains.
| > | >
| > | > Does anyone know how this stuff got there so I can avoid it in the future
| > | > and is there a way, other than changing each actual page, to get the code
| > | > removed.
| > | >
| > | > Thanks
| > | >
| > | > Tom
| > |
| > |
| > | Addendum:
| > |
| > | I've done some further testing and found that the <p>nbsp; came back when
| > | the DWT associated with the page was resaved. Since the code isn't actually
| > | in the DWT but it shows up in the uneditable portion of the page it looks
| > | like FP is forcing the <p>nbsp; to be generated somehow.
| > |
| > | The bottom line is that deleting the code from the page (and forcing it to
| > | be accepted) gets overridden if the DWT is resaved.
| > |
| > | Tom
| >
| >
| > Hi Stephen
|
| Unfortunately, I don't think that's it. At least the DWT doesn't contain
| the <p>.
|
| This is the code from the DWT:
|
| <div id="intro">
| <div id="quicksummary">
| <!-- #BeginEditable "quicksummary" -->(quicksummary)<!--
| #EndEditable -->
| </div> <!--quicksummary-->
| <div id="preamble">
| <!-- #BeginEditable "preamble" -->(preamble)<!-- #EndEditable -->
| </div> <!--preamble-->
|
| </div> <!--intro-->
|
|
| As you can see there is no <p> in any of the <div>s here.
|
| This, however, is the code from the page that has the DWT attached (I've
| removed most of the text):
|
| <div id="intro">
| <div id="quicksummary">
| <!-- #BeginEditable "quicksummary" -->quicksummary text is
| here<!-- #EndEditable -->
| </div> <!--quicksummary-->
| <div id="preamble">
| <!-- #BeginEditable "preamble" --><p>Preamble text is here</p>
| <!-- #EndEditable --><p> </div> <!--preamble-->
|
| </div> <!--intro-->
|
| If you look at the <!--- #EndEditable --> you will see the <p>&nbsp. In the
| page's code, this is "browned" out indicating that it is in the DWT (and in
| Design mode I get the do not enter when I hover over the paragraph mark).
| But, as you can see, no such code exists in the DWT.
|
| If I delete the <p>&nbsp in the page's code and force it to be accepted, it
| disappears from the page but comes back the next time I make a change to the
| DWT.
|
|
|
 
G

Guest

Stefan B Rusynko said:
Caused by your comments
(where FP also inserts thr & <p> tags if thry are not in a container)
Try changing it to
<div id="intro"><!--intro-->
<div id="quicksummary"><!-- #BeginEditable "quicksummary" --><!--quicksummary--><!-- #EndEditable --></div>
<div id="preamble"><!-- #BeginEditable "preamble" --><!--preamble--><!-- #EndEditable --></div>
</div>

--

_____________________________________________
SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
"Warning - Using the F1 Key will not break anything!" (-;
To find the best Newsgroup for FrontPage support see:
http://www.frontpagemvps.com/FrontPageNewsGroups/tabid/53/Default.aspx
_____________________________________________


|
|
| "Stefan B Rusynko" wrote:
|
| > The <p> tag is being added to the DWT when you save it
| > - open the DWT in browser and view source to see it
| >
| > Usually added because your editable region is
| > not is a valid html block level container
| > - like a <div> or <p> or <td) , etc
| > has an open html tag in it w/ no closing tag
| > or has a space after it
| >
| > Make sure the editable region is clean and has no extra spaces or line breaks after it as say
| >
| > <div>
| > <!-- #BeginEditable "content" --><p>some sample text</p><!-- #EndEditable -->
| > </div>
| >
| >
| > --
| >
| > _____________________________________________
| > SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
| > "Warning - Using the F1 Key will not break anything!" (-;
| > To find the best Newsgroup for FrontPage support see:
| > http://www.frontpagemvps.com/FrontPageNewsGroups/tabid/53/Default.aspx
| > _____________________________________________
| >
| >
| > |
| > |
| > | "tcarp" wrote:
| > |
| > | > Working through my first major learning on CSS and the use of DWTs, I've
| > | > moved almost all of the basic structure of one of my sites to a DWT and
| > | > cleaned out almost all the formatting in the html and linked it to styles in
| > | > a CSS sheet. I'm now cleaning up the pages and have a couple editable
| > | > regions from the DWT that had an extra paragraph mark AFTER the region's
| > | > editable area. In other words, it looked that there was a <p> in the DWT in
| > | > the editable region but, when viewed from the actual web page it wasn't
| > | > inside the editable region (when I hovered over it I got the DO NOT ENTER
| > | > symbol). My assumption was that somehow there was a <p> in DWT but when I
| > | > went there to check: no <p>. So back to the code on the actual page and sure
| > | > enough there was an extra <p>nbsp; at the end of the region. The problem was
| > | > that is shows in the shaded area (i.e. implies that it's in the DWT).
| > | >
| > | > I can delete the extra html in the page but of course get warned that I'm
| > | > making changes in a non-editable area and am offered the choice of either
| > | > restoring the original code on save or accepting the changes. I accept the
| > | > changes and the code is wonderfully removed, but it looks like I'm going to
| > | > have to do this to each individual page that somehow has inherited the extra
| > | > code from somewhere.
| > | >
| > | > I did test to see if forcing a save of the DWT (thus updating each page it's
| > | > attached to) would clean things up (since the DWT actually is correct) but
| > | > the extra code remains.
| > | >
| > | > Does anyone know how this stuff got there so I can avoid it in the future
| > | > and is there a way, other than changing each actual page, to get the code
| > | > removed.
| > | >
| > | > Thanks
| > | >
| > | > Tom
| > |
| > |
| > | Addendum:
| > |
| > | I've done some further testing and found that the <p>nbsp; came back when
| > | the DWT associated with the page was resaved. Since the code isn't actually
| > | in the DWT but it shows up in the uneditable portion of the page it looks
| > | like FP is forcing the <p>nbsp; to be generated somehow.
| > |
| > | The bottom line is that deleting the code from the page (and forcing it to
| > | be accepted) gets overridden if the DWT is resaved.
| > |
| > | Tom
| >
| >
| > Hi Stephen
|
| Unfortunately, I don't think that's it. At least the DWT doesn't contain
| the <p>.
|
| This is the code from the DWT:
|
| <div id="intro">
| <div id="quicksummary">
| <!-- #BeginEditable "quicksummary" -->(quicksummary)<!--
| #EndEditable -->
| </div> <!--quicksummary-->
| <div id="preamble">
| <!-- #BeginEditable "preamble" -->(preamble)<!-- #EndEditable -->
| </div> <!--preamble-->
|
| </div> <!--intro-->
|
|
| As you can see there is no <p> in any of the <div>s here.
|
| This, however, is the code from the page that has the DWT attached (I've
| removed most of the text):
|
| <div id="intro">
| <div id="quicksummary">
| <!-- #BeginEditable "quicksummary" -->quicksummary text is
| here<!-- #EndEditable -->
| </div> <!--quicksummary-->
| <div id="preamble">
| <!-- #BeginEditable "preamble" --><p>Preamble text is here</p>
| <!-- #EndEditable --><p> </div> <!--preamble-->
|
| </div> <!--intro-->
|
| If you look at the <!--- #EndEditable --> you will see the <p>&nbsp. In the
| page's code, this is "browned" out indicating that it is in the DWT (and in
| Design mode I get the do not enter when I hover over the paragraph mark).
| But, as you can see, no such code exists in the DWT.
|
| If I delete the <p> in the page's code and force it to be accepted, it
| disappears from the page but comes back the next time I make a change to the
| DWT.
|
|
|
Thanks again, Stephan

Let me see if I got it. If there is a comment outside the editable region
(in this case) FP might generate a <p>?

I use comments next to closing </div>s to maintain my sanity a little. It
helps me keep track of which DIV is being closed for nested DIVs. I usually
put the comment after the closing </div>. If it were before that closing tag
would FP NOT have generated the extra <p>?

I may try a different approach to marking the ending <./div>s so that I can
remove them altogether.

And finally, your post implies that am I wrong in assuming that a comment is
ignored by FP (or for that matter any other design tool). Is there a rule of
thumb that I can use instead to understand when to avoid this issue?

Thanks

Tom
 
S

Stefan B Rusynko

It might generate it anywhere
- but by putting it inside of the editable region at least you can remove it on pages

Put them inside of your Divs, just before your closing div tag

--

_____________________________________________
SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
"Warning - Using the F1 Key will not break anything!" (-;
To find the best Newsgroup for FrontPage support see:
http://www.frontpagemvps.com/FrontPageNewsGroups/tabid/53/Default.aspx
_____________________________________________


|
|
| "Stefan B Rusynko" wrote:
|
| > Caused by your comments
| > (where FP also inserts thr & <p> tags if thry are not in a container)
| > Try changing it to
| > <div id="intro"><!--intro-->
| > <div id="quicksummary"><!-- #BeginEditable "quicksummary" --><!--quicksummary--><!-- #EndEditable --></div>
| > <div id="preamble"><!-- #BeginEditable "preamble" --><!--preamble--><!-- #EndEditable --></div>
| > </div>
| >
| > --
| >
| > _____________________________________________
| > SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
| > "Warning - Using the F1 Key will not break anything!" (-;
| > To find the best Newsgroup for FrontPage support see:
| > http://www.frontpagemvps.com/FrontPageNewsGroups/tabid/53/Default.aspx
| > _____________________________________________
| >
| >
| > |
| > |
| > | "Stefan B Rusynko" wrote:
| > |
| > | > The <p> tag is being added to the DWT when you save it
| > | > - open the DWT in browser and view source to see it
| > | >
| > | > Usually added because your editable region is
| > | > not is a valid html block level container
| > | > - like a <div> or <p> or <td) , etc
| > | > has an open html tag in it w/ no closing tag
| > | > or has a space after it
| > | >
| > | > Make sure the editable region is clean and has no extra spaces or line breaks after it as say
| > | >
| > | > <div>
| > | > <!-- #BeginEditable "content" --><p>some sample text</p><!-- #EndEditable -->
| > | > </div>
| > | >
| > | >
| > | > --
| > | >
| > | > _____________________________________________
| > | > SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
| > | > "Warning - Using the F1 Key will not break anything!" (-;
| > | > To find the best Newsgroup for FrontPage support see:
| > | > http://www.frontpagemvps.com/FrontPageNewsGroups/tabid/53/Default.aspx
| > | > _____________________________________________
| > | >
| > | >
| > | > |
| > | > |
| > | > | "tcarp" wrote:
| > | > |
| > | > | > Working through my first major learning on CSS and the use of DWTs, I've
| > | > | > moved almost all of the basic structure of one of my sites to a DWT and
| > | > | > cleaned out almost all the formatting in the html and linked it to styles in
| > | > | > a CSS sheet. I'm now cleaning up the pages and have a couple editable
| > | > | > regions from the DWT that had an extra paragraph mark AFTER the region's
| > | > | > editable area. In other words, it looked that there was a <p> in the DWT in
| > | > | > the editable region but, when viewed from the actual web page it wasn't
| > | > | > inside the editable region (when I hovered over it I got the DO NOT ENTER
| > | > | > symbol). My assumption was that somehow there was a <p> in DWT but when I
| > | > | > went there to check: no <p>. So back to the code on the actual page and sure
| > | > | > enough there was an extra <p>nbsp; at the end of the region. The problem was
| > | > | > that is shows in the shaded area (i.e. implies that it's in the DWT).
| > | > | >
| > | > | > I can delete the extra html in the page but of course get warned that I'm
| > | > | > making changes in a non-editable area and am offered the choice of either
| > | > | > restoring the original code on save or accepting the changes. I accept the
| > | > | > changes and the code is wonderfully removed, but it looks like I'm going to
| > | > | > have to do this to each individual page that somehow has inherited the extra
| > | > | > code from somewhere.
| > | > | >
| > | > | > I did test to see if forcing a save of the DWT (thus updating each page it's
| > | > | > attached to) would clean things up (since the DWT actually is correct) but
| > | > | > the extra code remains.
| > | > | >
| > | > | > Does anyone know how this stuff got there so I can avoid it in the future
| > | > | > and is there a way, other than changing each actual page, to get the code
| > | > | > removed.
| > | > | >
| > | > | > Thanks
| > | > | >
| > | > | > Tom
| > | > |
| > | > |
| > | > | Addendum:
| > | > |
| > | > | I've done some further testing and found that the <p>nbsp; came back when
| > | > | the DWT associated with the page was resaved. Since the code isn't actually
| > | > | in the DWT but it shows up in the uneditable portion of the page it looks
| > | > | like FP is forcing the <p>nbsp; to be generated somehow.
| > | > |
| > | > | The bottom line is that deleting the code from the page (and forcing it to
| > | > | be accepted) gets overridden if the DWT is resaved.
| > | > |
| > | > | Tom
| > | >
| > | >
| > | > Hi Stephen
| > |
| > | Unfortunately, I don't think that's it. At least the DWT doesn't contain
| > | the <p>.
| > |
| > | This is the code from the DWT:
| > |
| > | <div id="intro">
| > | <div id="quicksummary">
| > | <!-- #BeginEditable "quicksummary" -->(quicksummary)<!--
| > | #EndEditable -->
| > | </div> <!--quicksummary-->
| > | <div id="preamble">
| > | <!-- #BeginEditable "preamble" -->(preamble)<!-- #EndEditable -->
| > | </div> <!--preamble-->
| > |
| > | </div> <!--intro-->
| > |
| > |
| > | As you can see there is no <p> in any of the <div>s here.
| > |
| > | This, however, is the code from the page that has the DWT attached (I've
| > | removed most of the text):
| > |
| > | <div id="intro">
| > | <div id="quicksummary">
| > | <!-- #BeginEditable "quicksummary" -->quicksummary text is
| > | here<!-- #EndEditable -->
| > | </div> <!--quicksummary-->
| > | <div id="preamble">
| > | <!-- #BeginEditable "preamble" --><p>Preamble text is here</p>
| > | <!-- #EndEditable --><p> </div> <!--preamble-->
| > |
| > | </div> <!--intro-->
| > |
| > | If you look at the <!--- #EndEditable --> you will see the <p>&nbsp. In the
| > | page's code, this is "browned" out indicating that it is in the DWT (and in
| > | Design mode I get the do not enter when I hover over the paragraph mark).
| > | But, as you can see, no such code exists in the DWT.
| > |
| > | If I delete the <p> in the page's code and force it to be accepted, it
| > | disappears from the page but comes back the next time I make a change to the
| > | DWT.
| > |
| > |
| > |
| >
| >
| >
| Thanks again, Stephan
|
| Let me see if I got it. If there is a comment outside the editable region
| (in this case) FP might generate a <p>?
|
| I use comments next to closing </div>s to maintain my sanity a little. It
| helps me keep track of which DIV is being closed for nested DIVs. I usually
| put the comment after the closing </div>. If it were before that closing tag
| would FP NOT have generated the extra <p>?
|
| I may try a different approach to marking the ending <./div>s so that I can
| remove them altogether.
|
| And finally, your post implies that am I wrong in assuming that a comment is
| ignored by FP (or for that matter any other design tool). Is there a rule of
| thumb that I can use instead to understand when to avoid this issue?
|
| Thanks
|
| Tom
 
G

Guest

My old problem of the DWT generating code has shown up again. From the last
time on this thread, I got in the habit of not putting any comments in my
html (I used to use them to help me remember which </div> went with which
<div>.

But I have a situation where the DWT is generating a <p>&nbsp</p> on every
page that it's attached to and no comments. Going back to some earlier
advice on this thread, I also checked for the integrity of the html tags and,
from what I can see, things should be OK.

I don't think these forums should turn into debugging vehicles, but I'm
stumped.

This is the body of the DWT:

<body>
<div id="wrapper">
<div id="container">
<div id="pageHdr">
<div id="hdrLogo">
<p id="logoP1">
<img border="0" src="../images/Scales_logo.gif" width="190"
height="160"></p>
<p id="logoP2">People or Policy</p>
<p id="logoP3">Observations on the pendulum</p>
</div>
<div id="hdrText">
<!-- #BeginEditable "hdrText" --> <!-- #EndEditable -->
</div>
</div>
<!-- #BeginEditable "navBar" --> <!-- #EndEditable -->
<div id="pageMain">
<hr>
<div id="colLeft">
<!-- #BeginEditable "colLeft" --> <!-- #EndEditable --></div>
<div id="colRight">
<!-- #BeginEditable "colRight" --> <!-- #EndEditable --></div>
<div id="colCenter">
<!-- #BeginEditable "colCenter" --> <!-- #EndEditable --></div>
</div>
<div id="pageFooter"></div>
</div>
</div>
</body>

The code is being generated right above the <div id="pageMain">. The only
thing I can see is that the editable region "navBar" is not contained in a
div specified in the DWT. Instead, this first line of html in the pages that
have the DWT attached is a <div>. It is followed by a simple unorder list.
I've checked and all the pages have the closing </div> and the <ul> plus all
the <li> are closed properly.

Since each page that uses the DWT follows the same convention for this
editable region (it's the inline navigation bar area) I probably could put
the <div></div> tags in the DWT, but I'd rather not until I understand why
the code is being generated.

Like with the original occurance that started this thread, I can delete the
generated <p>&nbsp</p> from the page. But since it is seen as being part of
the DWT, even if I force accept, it comes back the next time the DWT is
updated.

Thanks

Tom
 
S

Stefan B Rusynko

FP wil add a <p> tag to any empty comment tags (your editable regions)
So fill your editable region w/ a FP comment w/o any spaces and all on 1 line as in
<!-- #BeginEditable "hdrText" --><!--webbot bot="PurpleText" preview="HEADER HERE" --><!-- #EndEditable -->
And always wrap any editable region in at least 1 html container (a div is fine) as in
<div id="navBar">
<!-- #BeginEditable "navBar" --><!--webbot bot="PurpleText" preview="navBar HERE" --><!-- #EndEditable --></div>

So your code would be

<body><div id="wrapper"><div id="container"><div id="pageHdr">
<div id="hdrLogo">
<p id="logoP1"><img border="0" src="../images/Scales_logo.gif" width="190" height="160"></p>
<p id="logoP2">People or Policy</p><p id="logoP3">Observations on the pendulum</p>
</div>
<div id="hdrText">
<!-- #BeginEditable "hdrText" --><!--webbot bot="PurpleText" preview="HEADER HERE" --><!-- #EndEditable -->
</div>
</div>
<div id="navBar">
<!-- #BeginEditable "navBar" --><!--webbot bot="PurpleText" preview="navBar HERE" --><!-- #EndEditable --></div>
<div id="pageMain">
<hr>
<div id="colLeft">
<!-- #BeginEditable "colLeft" --><!--webbot bot="PurpleText" preview="colLeft HERE" --><!-- #EndEditable --></div>
<div id="colRight">
<!-- #BeginEditable "colRight" --><!--webbot bot="PurpleText" preview="colRight HERE" --><!-- #EndEditable --></div>
<div id="colCenter">
<!-- #BeginEditable "colCenter" --><!--webbot bot="PurpleText" preview="colCenter HERE" --><!-- #EndEditable --></div>
</div>
<div id="pageFooter"></div>
</div></div></body>


--

_____________________________________________
SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
"Warning - Using the F1 Key will not break anything!" (-;
To find the best Newsgroup for FrontPage support see:
http://www.frontpagemvps.com/FrontPageNewsGroups/tabid/53/Default.aspx
_____________________________________________


| My old problem of the DWT generating code has shown up again. From the last
| time on this thread, I got in the habit of not putting any comments in my
| html (I used to use them to help me remember which </div> went with which
| <div>.
|
| But I have a situation where the DWT is generating a <p>&nbsp</p> on every
| page that it's attached to and no comments. Going back to some earlier
| advice on this thread, I also checked for the integrity of the html tags and,
| from what I can see, things should be OK.
|
| I don't think these forums should turn into debugging vehicles, but I'm
| stumped.
|
| This is the body of the DWT:
|
| <body>
| <div id="wrapper">
| <div id="container">
| <div id="pageHdr">
| <div id="hdrLogo">
| <p id="logoP1">
| <img border="0" src="../images/Scales_logo.gif" width="190"
| height="160"></p>
| <p id="logoP2">People or Policy</p>
| <p id="logoP3">Observations on the pendulum</p>
| </div>
| <div id="hdrText">
| <!-- #BeginEditable "hdrText" --> <!-- #EndEditable -->
| </div>
| </div>
| <!-- #BeginEditable "navBar" --> <!-- #EndEditable -->
| <div id="pageMain">
| <hr>
| <div id="colLeft">
| <!-- #BeginEditable "colLeft" --> <!-- #EndEditable --></div>
| <div id="colRight">
| <!-- #BeginEditable "colRight" --> <!-- #EndEditable --></div>
| <div id="colCenter">
| <!-- #BeginEditable "colCenter" --> <!-- #EndEditable --></div>
| </div>
| <div id="pageFooter"></div>
| </div>
| </div>
| </body>
|
| The code is being generated right above the <div id="pageMain">. The only
| thing I can see is that the editable region "navBar" is not contained in a
| div specified in the DWT. Instead, this first line of html in the pages that
| have the DWT attached is a <div>. It is followed by a simple unorder list.
| I've checked and all the pages have the closing </div> and the <ul> plus all
| the <li> are closed properly.
|
| Since each page that uses the DWT follows the same convention for this
| editable region (it's the inline navigation bar area) I probably could put
| the <div></div> tags in the DWT, but I'd rather not until I understand why
| the code is being generated.
|
| Like with the original occurance that started this thread, I can delete the
| generated <p>&nbsp</p> from the page. But since it is seen as being part of
| the DWT, even if I force accept, it comes back the next time the DWT is
| updated.
|
| Thanks
|
| Tom
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

dwt after crash 6
.DWT updating problem 3
Manage Editable Regions - DWT 3
FP 2003 - Detaching DWTs 5
Nested DWT 3
Can I attach a dwt page that has frames? 2
Formating Editable Region in DWT 4
Problems with DWT 8

Top