Can't delete CR at end of document...

D

Dave

Hi folks --

This is my first time creating a web page template for a client that
wants to make her own changes to her web site, but needs to do the
markup in Word.

It's not the most elegant solution in the world, but I'm using PHP to
include the Word doc (saved as filtered html) inside a header and a
footer, html/body tags and all. It worked surprisingly well, except I
keep getting a space between the Word-generated page and the footer.

I tracked this down to an html paragraph/font tag set that was being
generated by Word, due to a carriage return after the last table on the
page in the original document. As a test I manually deleted the
paragraph/font tags in the exported html document and it worked fine.

Different story when I tried to delete the carriage return in Word.
Reveal definitely shows a paragraph/CR there, I just can't find a way
to delete it. Selecting it, backspace, nothing worked.

Does Word *have* to have a CR after a table at the end of document? If
so, does it have to export it as a "<p>" tag in html? Any suggestions
are appreciated, especially since I'm so close to making this work.

Thanks!

-- Dave
 
L

Lynn

Hi Dave - Word always has a paragraph mark after a table and also
always at the end of a document. If you just open a blank document
from scratch and click the Show/Hide button, you will see a lone
paragraph mark. You cannot remove it. You can reset it's font size to
1 so it is very very small so it looks invisible on the screen, but I
am not sure how this will affect your html page though. Hope this is
helpful.
 
D

Dave

Hi Lynn, thanks very much for the quick response. It's frustrating
that it forces carriage returns.

Your answer did get me on the right track though. I played with the
font size, and even 1 left a noticable gap. But then it occured to me
to leave it at 12 and fill that line with dashes to push the CR all the
way to the right margin. I then set the fill to white and the text
color to white so they blended in with the background, and voila. It's
a little more of a hack than I was planning on, but whatever works.

Thanks again!

-- Dave
 
C

Charles Kenyon

Check the paragraph formatting of the last paragraph. Get rid of space
before or after.
--
Charles Kenyon

Word New User FAQ & Web Directory: http://addbalance.com/word

Intermediate User's Guide to Microsoft Word (supplemented version of
Microsoft's Legal Users' Guide) http://addbalance.com/usersguide




--------- --------- --------- --------- --------- ---------
This message is posted to a newsgroup. Please post replies
and questions to the newsgroup so that others can learn
from my ignorance and your wisdom.
 
D

Dave

Hi Charles, thanks for the reply.

Unfortunately, just the existence of a carriage return causes the Word
html export filter to put a <p> tag into the html code, and that's what
was causing the problem. Fortunately, it seems to be fixed (at least
in my case) by my hack above.

Thanks again,

-- Dave
 

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

Top