Rendering issues with Hebrew

M

Marius Greuel

Hello Group,

I am trying to display some HTML code in IE, and I noticed a text alignment
problem that I cannot explain. As a sidenote, Firefox behaves the same, so I
am not sure were the problem lies:

The following HTML code (generated by MS-Word) displays the XYZ right of the
Hebrew text. In MS-Word the XYZ text is left of the Hebrew text, which is
what I expect.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<META http-equiv="Content-Type" content="text/html; charset=windows-1255">
<TITLE>úöåâú</TITLE>
</HEAD>
<BODY>
<P dir="RTL"><SPAN dir="RTL">úöåâú</SPAN><SPAN dir="LTR">XYZ</SPAN></P>
</BODY>
</HTML>

Now if I change the P to the following, the text shows correctly:
<P dir="RTL"><SPAN>úöåâú</SPAN><SPAN dir="LTR">XYZ</SPAN></P>

Can someone please explain the why this happens? Is the behavior correct?

I simply assumed that the Hebrew text is already RTL since the P is RTL, so
an extra SPAN with the RTL attribute would not hurt. Of course, I know
diddly squad about HTML rendering, nor do I know Hebrew :)

I would appreciate any clues.

Thanks,
Marius
 
R

Rob Parsons

Hi Marius,

I think the problem lies with how Word is generating the HTML source, not
how the browsers are rendering it.

Word is notorious for generating excessive amounts of formatting in HTML
documents and very few would use it as a web page editor. Depending upon
your target audience (Internet or intranet with word installed) you may
consider publishing your word documents as .doc files that uses can download
and read with word. If your target audience is the general public you may be
better off generating your html documents with a HTML editor (FrontPage is
bundled with Office).

Regards.
 
M

Marius Greuel

Hi Rob,

Thanks for your reply.
I think the problem lies with how Word is generating the HTML source, not
how the browsers are rendering it.
This is exactly the question. However, looking at the HTML code, it seems to
me it is a browser issue.
Word is notorious for generating excessive amounts of formatting in HTML
documents and very few would use it as a web page editor...
Generally speaking, that's true. Yet, I have seen very few examples where
Word (2003) generates *incorrect* HTML code. I am just trying to figure out
who to blame, since our tool depends on the Word HTML export feature. If it
turned out that Word generates incorrect code, I would need to know why it
is incorrect, so that I can make the necessary changes for the work-around.

I have not much experience using RTL text, nor about the HTML layout of the
same, but I know that this is not a trivial question. Do you know who
(newsgroup) would be knowledgeable to answer this kind of question?

Regards,
Marius
 
R

Rob Parsons

Hi Marius,

Sorry for the late reply... lost the thread.

That both IE and FF render the Word HTML version the same (incorrect)
indicates to me that the browser is not the problem. The nesting of the tags
(spans) in the Word HTML appear to me to be as they would be rendered by the
Browser.

I am not sure which newsgroup you could try. My opinion that it is a Word
problem. You could try one of the MS Office newsgroups.

Regards.
 

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