htmlArea

A directory of browser-based WYSIWYG editors

  MAIN
INDEX
SEARCH
POSTS
WHO'S
ONLINE
LOG
IN

Home: htmlArea 3 (beta): htmlArea 2 & 3 archive (read only): htmlArea v3.0 - Add-Ons:
Has anyone gotten HTML Tidy to work on IIS?


The htmlArea 2 & 3 editors have been discontinued.

We've made these forums available as a read-only reference and knowledge-base for people using or developing editors based on htmlArea 2 or 3.

Anyone who is interested in taking over version 2 or 3 is free to do so. All we ask is that you choose a new name that doesn't have "htmlarea" in it to avoid confusion with this site. We'll even give you a link in the directory to make it easier for people to find you. If you are developing or hosting an htmlArea based-editor under a new name, please submit it to our directory.

 


DarrylB
User

Feb 2, 2005, 7:06 PM

Post #1 of 6 (84420 views)
Shortcut
Has anyone gotten HTML Tidy to work on IIS? Can't Post

Hey all,

has anyone gotten htmltidy to work on Windows 2000 or Windows 2003? Im having troubles gettign this to work with IIS...

Any help would be appreciated...

Thanks!


whazup
New User

Feb 3, 2005, 10:50 AM

Post #2 of 6 (84382 views)
Shortcut
Re: [DarrylB] Has anyone gotten HTML Tidy to work on IIS? [In reply to] Can't Post

Yeah, I got it working here. I copied tidy.exe into the same folder as the plugin code, then changed html-tidy-logic.php as follows:


Code
        $source = stripslashes($source); 

// Open a tidy process - I hope it's installed!
$descriptorspec = array(
0 => array("pipe", "r"),
1 => array("pipe", "w"),
- 2 => array("file", "/dev/null", "a")
+ 2 => array("file", "null", "w")
);
- $process = proc_open("tidy -config html-tidy-config.cfg", $descriptorspec, $pipes);
+ $process = proc_open("\"" . getcwd() . "/tidy\"", $descriptorspec, $pipes);
+ // -config html-tidy-config.cfg

// Make sure the program started and we got the hooks...
// Either way, get some source code into $source
@@ -56,7 +57,7 @@

// Create a set of javascript code to compile a new source string
foreach ($srcLines as $line) {
- $jsMakeSrc .= "\tns += '" . str_replace("'","\'",$line) . "\\n';\n";
+ $jsMakeSrc .= "\tns += '" . str_replace("'","\'",trim($line)) . "\\n';\n";
}
?>


I believe that's all I did.

Mark Bradshaw
http://www.dream3.org/

(This post was edited by whazup on Feb 7, 2005, 7:10 AM)


whazup
New User

Feb 3, 2005, 10:51 AM

Post #3 of 6 (84381 views)
Shortcut
Re: [whazup] Has anyone gotten HTML Tidy to work on IIS? [In reply to] Can't Post

By the way, that's a diff above. You should remove (or comment out) any line that starts with a minus, and add any line that starts with a +.

Mark Bradshaw
http://www.dream3.org/

(This post was edited by whazup on Feb 7, 2005, 7:10 AM)


DarrylB
User

Feb 3, 2005, 6:41 PM

Post #4 of 6 (84355 views)
Shortcut
Re: [whazup] Has anyone gotten HTML Tidy to work on IIS? [In reply to] Can't Post

Do you know if this requires cmd.exe?

I dont feel comfortable giving IIS access to that file....


whazup
New User

Feb 4, 2005, 4:14 AM

Post #5 of 6 (84333 views)
Shortcut
Re: [DarrylB] Has anyone gotten HTML Tidy to work on IIS? [In reply to] Can't Post

Not to my knowledge. I'm not 100% sure how proc_open launches processes, but I don't believe cmd.exe is involved.

Mark Bradshaw
http://www.dream3.org/


DarrylB
User

Feb 7, 2005, 6:24 PM

Post #6 of 6 (84276 views)
Shortcut
Re: [whazup] Has anyone gotten HTML Tidy to work on IIS? [In reply to] Can't Post

Well, i tried to reproduce what you said you did...
No errors, except that proc_open doesnt run.

With research i found out that it does indeed need cmd.exe

Last i heard about cmd.exe being in a position where it can be accessed from by php, is a security issue (very minor, but one none-the-less)...

:(

Anyone know of a replacement?

 
 
 


Search for (options)