FartStopper
FartStopper

Reputation: 121

Copy/Paste From Word To Expression

When I copy/paste from a word doc into Expressions Web, I get strange behavior. My screenshot from word below, sometimes it will place the top line in one <span> tag and the rest in a separate <span> tag causing a slight gap between the two. Is this becoming the new norm of how to code using HTML or do I have hidden characters/breaks in my word doc that I do not see. For example, a straight copy/paste presents this HTML

<p class="MsoNormal"><b><u>This is the top row of my information<o:p>
</o:p></u></b></p>
<span style="font-size:12.0pt;font-family:&quot;
Times New Roman&quot;;mso-fareast-font-family:
&quot;Times New Roman&quot;;mso-ansi-language:EN-US;
mso-fareast-language:EN-US;
mso-bidi-language:AR-SA">This is information that should come 
up under the top 
row and I am just trying to span it for more than 1 line, 
maybe go to 2 or three 
or four or five or six.<span style="mso-spacerun: yes">&nbsp; </span>
Oh here comes 
more and more and more and more and more and more and more and more.
<span style="mso-spacerun: yes">&nbsp;
</span>Oh I am not done yet, not yet not yet.
<span style="mso-spacerun: yes">&nbsp;
</span>Okay I think this is enough once I reach one more last line.
<span style="mso-spacerun: yes">&nbsp;
</span>Almost to the end, yes I hit it!</span>

Which to me the exact same can be achieved by simply using this syntax:

<p><strong><u>This is the top row of my information</u></strong><br>
This is information that should come up under the top row and I am just
trying to span it for more than 1 line, maybe go to 2 or three or four or
five or six.  Oh here comes more and more and more 
and more and more and more and more and more.  Oh I am not done yet, 
not yet not yet.  Okay I think this is enough once I reach one more last   
line. Almost to the end, yes I hit it!</p>

Why all of the extra syntax with Expressions?

Word Screenshot Expression Design View Expression HTML View

Upvotes: 0

Views: 1664

Answers (1)

Lexi
Lexi

Reputation: 324

I could be wrong, but I believe that usually copy and pasting from Microsoft Word can cause issues with Expression Web. I will do some more reason as to exactly why, but when I was in college, I was specifically told that we should copy and paste from a program like Notepad if we were to do this.

According to Microsoft, it seems a straight copy/paste is not recommended. If you haven't already, try pasting with the formatting. See here for more information.

There is also another link here to a Microsoft forum that states that Word has horrible web mark-ups because it is not a web design tool.

Upvotes: 2

Related Questions