Open in editor? dialog for html when viewing IE source

For technical support and bug reports for all editions of CSS HTML Validator, including htmlval for Linux and Mac.
Post Reply
User avatar
RSteinwand
Rank VI - Professional
Posts: 596
Joined: Mon Jun 09, 2008 2:12 pm
Location: Fargo, ND
Contact:

Open in editor? dialog for html when viewing IE source

Post by RSteinwand »

Hi Albert,

I have CSE configured to open source from IE and each time I get the unrecognizable file type.

Couldn't you do a quick test for html from the first 20 characters and determine if it's html from that? Seems to me you had a check for html in v.16 when monitoring the clipboard. I would think that would be an easy fix. I wouldn't mind if it was only 90% accurate. :D

Thanks.
Rick
User avatar
Albert Wiersch
Site Admin
Posts: 3785
Joined: Sat Dec 11, 2004 9:23 am
Location: Near Dallas, TX
Contact:

Re: Open in editor? dialog for html when viewing IE source

Post by Albert Wiersch »

Hi Rick,

Sure. I will look into this for v17. I don't think it should be too difficult. :)
Albert Wiersch, CSS HTML Validator Developer • Download CSS HTML Validator FREE Trial
User avatar
RSteinwand
Rank VI - Professional
Posts: 596
Joined: Mon Jun 09, 2008 2:12 pm
Location: Fargo, ND
Contact:

Re: Open in editor? dialog for html when viewing IE source

Post by RSteinwand »

Thanks Albert.
Rick
User avatar
Albert Wiersch
Site Admin
Posts: 3785
Joined: Sat Dec 11, 2004 9:23 am
Location: Near Dallas, TX
Contact:

Re: Open in editor? dialog for html when viewing IE source

Post by Albert Wiersch »

RSteinwand wrote:Thanks Albert.
You're welcome! I worked on this yesterday. If the file extension is unknown then CSE HTML Validator v17 will read a little of the file (up to 2048 bytes) and do some quick & simple tests to see if it looks like HTML. If it does look like HTML then it will open the file. I think this will resolve the issue you are having.
Albert Wiersch, CSS HTML Validator Developer • Download CSS HTML Validator FREE Trial
User avatar
RSteinwand
Rank VI - Professional
Posts: 596
Joined: Mon Jun 09, 2008 2:12 pm
Location: Fargo, ND
Contact:

Re: Open in editor? dialog for html when viewing IE source

Post by RSteinwand »

Cool! Are you also checking for file size? I had a snippet that showed up in CSE yesterday and it was only the html5 doctype.

Code: Select all

<!doctype html>
Since it contains "html>", I figured that was about the minimum requirement.

To be a valid web page, I would think it would need to be at least 200 bytes. What do you think?
Rick
User avatar
Albert Wiersch
Site Admin
Posts: 3785
Joined: Sat Dec 11, 2004 9:23 am
Location: Near Dallas, TX
Contact:

Re: Open in editor? dialog for html when viewing IE source

Post by Albert Wiersch »

No, I'm not checking for file size but just copying the DOCTYPE should probably not trigger the clipboard feature. I'll look into that.

By the way, there is an option to only trigger the clipboard feature for documents starting with <cseclip>, which is good to use when using the Easy Copy Firefox extension. I'm not sure if the BETA version you have has that option though (I don't think it does).
Albert Wiersch, CSS HTML Validator Developer • Download CSS HTML Validator FREE Trial
Post Reply