Disable link check?

For technical support for all editions of CSS HTML Validator. Includes bug reports.
Post Reply
Kalkas
Rank 0 - Newcomer
Rank 0 - Newcomer
Posts: 3
Joined: Tue Jun 03, 2014 2:08 pm

Disable link check?

Post by Kalkas » Tue Jun 03, 2014 2:18 pm

Hello,

Is it possible to disable link check? At the start of writing a web article, I usually write a table of content, with links to various headings that I plan to have. Since those sections of the article are planned, they are not yet written. So the links on in the Content will refer to non-existent sections. At this stage of writing, I prefer not to check links. Is it possible?

Best regards,

Aleksandar

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

Re: Disable link check?

Post by Albert Wiersch » Tue Jun 03, 2014 3:47 pm

Hello,

I assume that you are referring to internal links like this:

Code: Select all

<a href="#internallink">internal link text</a>
If so, then it should be possible to create some custom user functions to disable this message if you have a special comment in the document. You can remove the comment when you want to enable the checking for that document.

This will require the pro edition or higher because of the custom functions.

If you think this might work then let me know and I can look into what user functions you would need. It should be relatively simple.
Image
Albert Wiersch

Kalkas
Rank 0 - Newcomer
Rank 0 - Newcomer
Posts: 3
Joined: Tue Jun 03, 2014 2:08 pm

Re: Disable link check?

Post by Kalkas » Tue Jun 03, 2014 5:52 pm

Hello,

Thanks for your reply. Yes, I am thinking about internal links in the document. I am planning to buy the pro edition. As I see it, you can use html validator to write web documents as well, correct? Is it not CSE HTML Validator also a powerful HTML Text Editor?

If it is complicated to make a custom user function, I think that I have to write headings in advance. I usually identify the unique headings, sections and pragraphs with id tag. For instance,

Code: Select all

<h2 id="heading2">Unique Heading 2</h2>
I do not see that this important tag is among shortcut tags. I see that span tag is presented with,

Code: Select all

<span id="...">...</span>
but not id as an independent tag. Is it possible to create a shortcut for it, or for other tags, such as class?

By the way, I am not sure about the difference between Standards compliant check, Nsgmls message only and JSLint messages only.

(I come across CSE HTML Validator in my search for a Windows version of BBEdit, which is a powerful text editor for OS X. Its validator is very good. Many Windows text editors uses as usual Tidy, which is not good when it comes to texts that uses Eastern European characters. It simply does not know how to treat such characters and automatically changes them into unrecognizable codes. CSE HTML Validator does not have such behavior; it treats those characters as normal.)

Best regards,

Aleksandar

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

Re: Disable link check?

Post by Albert Wiersch » Tue Jun 03, 2014 9:38 pm

Kalkas wrote:As I see it, you can use html validator to write web documents as well, correct? Is it not CSE HTML Validator also a powerful HTML Text Editor?
Yes, you can use it as an HTML and text editor.
Kalkas wrote:If it is complicated to make a custom user function, I think that I have to write headings in advance. I usually identify the unique headings, sections and pragraphs with id tag. For instance,

Code: Select all

<h2 id="heading2">Unique Heading 2</h2>
I do not see that this important tag is among shortcut tags. I see that span tag is presented with,

Code: Select all

<span id="...">...</span>
but not id as an independent tag. Is it possible to create a shortcut for it, or for other tags, such as class?
Sure. You can use the 'User Inserter'. Choose View->Toolbars->Inserters->User. Then from the 'User Inserter' toolbar, select User->Edit Configuration. You can add something like this:

Code: Select all

<tag menu='H' flags='32' inserttext='<h2 id="">|</h2>' hint='h2 with id attribute.'/>
Save the config file and choose User->Reload Configuration. The inserter should then be updated with the above change.
Kalkas wrote:By the way, I am not sure about the difference between Standards compliant check, Nsgmls message only and JSLint messages only.
Here is a documentation page that should help explain the validation modes:
http://www.htmlvalidator.com/v140/docs/ ... _modes.htm
Kalkas wrote:(I come across CSE HTML Validator in my search for a Windows version of BBEdit, which is a powerful text editor for OS X. Its validator is very good. Many Windows text editors uses as usual Tidy, which is not good when it comes to texts that uses Eastern European characters. It simply does not know how to treat such characters and automatically changes them into unrecognizable codes. CSE HTML Validator does not have such behavior; it treats those characters as normal.)
Great. I'm glad you came across CSE HTML Validator and that you find that it works properly with those characters. May I ask how you came across it in more detail? For example, did you search for a specific phrase on a search engine and was CSE HTML Validator one of the results?

I will work on a user function solution to your original question and post it tomorrow.
Image
Albert Wiersch

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

Re: Disable link check?

Post by Albert Wiersch » Wed Jun 04, 2014 12:26 pm

Hello,

Here are the user functions that you can use to disable internal link checking when a certain comment is present:

Code: Select all

function onCommentHTML() {
 if $commentstring==="!--CSEMYCONFIG_DISABLEINTERNALREFCHECKING--" {
  MessageEx(13,2014060401,MSG_MESSAGE,'Disabling internal link checking.');
  $myuserconfig.disablebadinternalrefmsgs=true;
 }
}

function onMessageID_2014060400() {
 if isSet($myuserconfig.disablebadinternalrefmsgs) {
  $omid_cancel=true;
 }
}
When using the above, you can then include this comment in the HTML document to disable the internal link checking error messages:

Code: Select all

<!--CSEMYCONFIG_DISABLEINTERNALREFCHECKING-->
Simply copy and paste the above functions into a text file and call it something like "myuserfunctions.cfg". Then specify this file in the Validator Engine Options in the Validator Engine->Config File page.

I did run into an issue with the message that you want to disable not having a message ID, so in the next update it will now have a message ID. Therefore the above won't work until that update but I can send you a pre-release version if you'd like, and then it should work.

An alternate option might be to change the messages to non-error & non-warning messages instead of disabling them altogether. You can do this by using $omid_msgtype=MSG_MESSAGE instead of $omid_cancel=true.
Image
Albert Wiersch

Kalkas
Rank 0 - Newcomer
Rank 0 - Newcomer
Posts: 3
Joined: Tue Jun 03, 2014 2:08 pm

Re: Disable link check?

Post by Kalkas » Fri Jun 06, 2014 5:36 pm

Hello,

Thanks for your reply and the provided codes!

I came across CSE HTML Validator when I was very frustrated by Tidy validator. I had to try a couple of other HTML editors before I found your site. I did find your site when searching for an advanced HTML text editor that has a built-in validator.

The thing is that when I searched only for an advanced html text editor, I could not find you. I came across something called HTML-Kit tools or Notepad++, but both programs have not built-in keyboard shortcuts for standard tags, as BBEdit (in OS X) or HTML Validator have. I think that your site is hard to find when searching only for a HTML text editor, but it was easily found when searching for a HTML validator on google. You were then on top results. For this reason, your product should also be advertised as a HTML/CSS text editor, and not just as a validator.

Best regards,

Aleksandar

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

Re: Disable link check?

Post by Albert Wiersch » Fri Jun 06, 2014 6:33 pm

Thanks for the feedback. I really appreciate the details in how you found CSE HTML Validator. It sounds like I should promote the editor more even though the primary purpose of the program is to be a great validator.
Image
Albert Wiersch

Post Reply