Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Unknown HTML Tag Query

6 views
Skip to first unread message

Mike Copeland

unread,
Jun 4, 2022, 3:56:56 PM6/4/22
to

I recently received code for a Web site I've been asked to maintain.
It uses a tag I don't understand, nor can I find explanations of it. It
is used thusly:

<o:p></o:p></p>

In the CSS style thaere is no "o" declaration, so I'm mystified. Any
ideas? Please advise. TIA

--
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus

😉 Good Guy 😉

unread,
Jun 4, 2022, 5:05:44 PM6/4/22
to
On 04/06/2022 20:56, Mike Copeland wrote:
   I recently received code for a Web site I've been asked to maintain.  
It uses a tag I don't understand, nor can I find explanations of it.  It 
is used thusly:

<o:p></o:p></p>

   In the CSS style thaere is no "o" declaration, so I'm mystified.  Any 
ideas?  Please advise.  TIA

It could be something to do with Microsoft Office filter package that converts a word/excel document to html and vice versa.

Sometimes people will just copy and paste the text from a word document into a graphical html IDE/editor and this creates a useless bloat in html file.

You just need to clean the file so that it uses standard html5 tags.



--
Similar to Windows 11 Home edition, Windows 11 Pro edition now requires internet connectivity during the initial device setup (OOBE) only. If you choose to setup device for personal use, MSA will be required for setup as well. You can expect Microsoft Account to be required in subsequent WIP flights.

Now this is not the end. It is not even the beginning of the end. But it is, perhaps, the end of the beginning

J𝕒𝕞𝕖𝕤 𝕂𝕚𝕣𝕜

unread,
Jun 4, 2022, 6:12:06 PM6/4/22
to
In Message <MPG.3d0566ee6...@news.eternal-september.org>
On Saturday Jun 04, 2022 3:56 pm -04:00
Mike Copeland <mrc...@cox.net> wrote:

> I recently received code for a Web site I've been asked to
> maintain. It uses a tag I don't understand, nor can I find
> explanations of it. It is used thusly:

> <o:p></o:p></p>

> In the CSS style thaere is no "o" declaration, so I'm mystified.
> Any ideas? Please advise. TIA

It's been a while since I have seen html generated by word, but that I
think my be left over from that process.

If there is no style or js for it, you should be able to remove it
safely. Perhaps even run it through HTML tidy.

--
J𝕒𝕞𝕖𝕤 𝕂𝕚𝕣𝕜

JJ

unread,
Jun 5, 2022, 6:10:25 AM6/5/22
to
On Sat, 4 Jun 2022 12:56:52 -0700, Mike Copeland wrote:
> I recently received code for a Web site I've been asked to maintain.
> It uses a tag I don't understand, nor can I find explanations of it. It
> is used thusly:
>
> <o:p></o:p></p>
>
> In the CSS style thaere is no "o" declaration, so I'm mystified. Any
> ideas? Please advise. TIA

Escape the colon character. e.g.

o\:p { background: red }

Jukka K. Korpela

unread,
Jun 5, 2022, 1:31:31 PM6/5/22
to
J𝕒𝕞𝕖𝕤 𝕂𝕚𝕣𝕜 wrote:

> It's been a while since I have seen html generated by word, but that I
> think my be left over from that process.

The accepted answer to a question that is essentially the same
says about the same, with some extra information. Microsoft software
creates tags like <o:p> in generated HTML to ensure that the HTML
document can be converted back to an Office format without losing anything.
https://stackoverflow.com/questions/7808968/what-do-op-elements-do-anyway

However, the answer is over ten years old, and things have probably
changed. Office 365 does not seem to generate such tags. It generates
bulky data in the <head> part, presumably serving similar purposes.

So when you see <o:p>, the document was probably generated by an old
version of Office software (most probably Word). It serves no other
purpose than letting Office somehow restore the Office document from
which it was generated – and even this may fail nowadays. Web browsers
simply ignore the tags as unknown. Well, to be exact, not quite.
Browsers generate an element node in the document tree in the internal
representation (DOM tree). This has no affect as such, but if you e.g.
traverse the tree in JavaScript, such nodes will be encountered. Or you
could even style them yourself. But I cannot imagine a situation where
you might want to do that.

Yucca, https://jkorpela.fi
0 new messages