4

Do people think there is any need of a good analogue of HTML Tidy for .NET?

I am looking to create a product that will do things like filter HTML syntax for documents, performing various tasks, such as: cleaning up HTML generated by MicroSoft Word, converting HTML to XHTML, stripping out certain elements, etc.

What other possible common functions would be expected from an HTML tidier?

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
Raymond
  • 21
  • 3
  • I think you need to include some more information on your goal, is this something you want from an editor, is this something you want your program to have as part of it's editor? – Chris Marisic May 04 '11 at 18:31
  • I'm developing the product in C# to clean, filter and replace tags in HTML. And for me is very interesting what is the most helpful functions which are necessary to include? – Raymond May 05 '11 at 10:48

3 Answers3

0

I haven't tried any of these, but there are a couple of links here: http://tidyfornet.sourceforge.net/

Let us know what kind of success you have with any of them. This is a good question to know the answer to.

matt
  • 9,113
  • 3
  • 44
  • 46
  • That appears to be a .NET wrapper for HTML Tidy. It sounds like @Raymond is asking for a tool similar to Tidy that understands .NET-specific constructs like server tags. – Katie Kilian May 04 '11 at 18:38
  • I'm collecting a list with functions which analogue of Tidy for .Net has to include. Do you know the most important? – Raymond May 05 '11 at 10:50
0

You can achieve some cleanliness by using the built-in HTML formatting tool in Visual Studio.

http://weblogs.asp.net/scottgu/archive/2006/07/07/Tip_2F00_Trick_3A00_-Custom-formatting-HTML-in-Visual-Web-Developer-and-Visual-Studio-2005.aspx

Ryan Kohn
  • 13,079
  • 14
  • 56
  • 81
0

I had used LINQ to XML with connection to HTMLAgilityPack for importing HTML into a WPF application which in turn reads specific information from a HTML file.

You may use it to perform the corrections in formatting or highlighting the HTML syntax. You can find more information about Html Agility Pack on Codeplex.

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
Pank
  • 670
  • 5
  • 12