Win a copy of Getting started with Java on the Raspberry Pi this week in the Raspberry Pi forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Tim Cooke
  • Jeanne Boyarsky
Sheriffs:
  • Rob Spoor
  • Devaka Cooray
  • Liutauras Vilda
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Piet Souris

META tag is getting added while parsing HTML

 
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I'm trying to read/write a simple HTML file using "javax.xml.parsers". I get all details(nodes and attributes) when i read that file as an XML document. After modifying some tag values, I write the changes to the same file using "javax.xml.transform". But, in between <head> ... </head> tags, "<META http-equiv="Content-Type" content="text/html; charset=UTF-8">" is getting added which fails the parser in my next attempt.

kindly tell me how can I avoid generation of this <META> tag . . .

Thank you in advance . . . .
 
Marshal
Posts: 27900
94
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
But that's well-formed HTML. So if some parser is failing to parse it, then it's the fault of that parser. (Or were you trying to parse the HTML with an XML parser?)
 
Would you like to try a free sample? Today we are featuring tiny ads:
Low Tech Laboratory
https://www.kickstarter.com/projects/paulwheaton/low-tech-0
reply
    Bookmark Topic Watch Topic
  • New Topic