Re: Error from Tidy

Bischoff, Alex wrote:
> 
> > I also want to change the default settings for Tidy. Could someone
> > explain in *very simple terms* how I set the environmental variable
> > HTML_TIDY in Windows 98 please. What exactly do I need to type and in
> > which file?
>... 

Hi folks,

As (nearly) always in programming, there are different ways to get to
the same result...

> 
> 1. Using Notepad.exe, open "autoexec.bat" in your root directory. For

But I don't think that hacking the system startup files is an excellent
idea.

On my behalf, I'd prefer creating "ad hoc" "bat" files, as I did before
getting rid if the Micro$oft systems. You don't need to reboot the
system, and you simply declare the HTML_TIDY variable at the very moment
you need it, then "undeclare it" just afterwards.

So your "personalized_tidy.bat" file may look like this :

SET HTML_TIDY="this_is_your_html_tidy_value"
rem declare the html_tidy variable
your_tidy_path\tidy.exe %1 -your_tidy_command_line_options
rem run tidy with the html_tidy variable set by invoking:
rem "personalized_tidy.bat yourpath\yourfile.htm"
SET HTML_TIDY=""
rem unset the html_tidy variable

So, you can open an MSDOS window, execute the .BAT file and "that's all
folks" ;-)
By the way, you can create lots of different .bat files as you see fit,
e.g. a "tidy_to_html_4_but_not_clean.bat" file, a "tidy_xml_output.bat"
file, or a "tidy_no_warnings.bat" file etc.... as many as you need...

I think this method will work on all M$Windows releases.

The only problem to be aware of is that your .BAT files and the TIDY.EXE
program MUST NOT have the same name, if they reside in the same
directory. If you have a directory which contains "tidy.exe" *AND*
"tidy.bat" , invoking "tidy" will execute the "tidy.exe" file (i.e. all
options set to "default"), *NOT* the "tidy.bat" file.

Have a nice day

Norbert

-- 
*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*
  (o_    This was The Megabyte Text Magician - http://tmtm.free.fr
  //\               "Les peripheriques vous parlent"
  V_/_    http://www.globenet.org/periph    -    TUX powered  ;-)
*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*

Received on Monday, 23 October 2000 16:08:10 UTC