advertisement

Article:
  Build a Dashboard Widget
Subject:   It doesn't work
Date:   2005-06-14 11:33:30
From:   TimGrant
Response to: It doesn't work

What you're describing happened to me too. I made some changes to the JavaScript and now it works a little bit better:


function getManPage()
{
if (document.getElementById('programName').value != null)
{
var commandLine = 'groff -mandoc -Tascii -P-b -P-c `/usr/bin/man -w "' + document.getElementById('programName').value+'"`' + ' | col -b '
document.getElementById('outputArea').value = "Processing..."
var output = widget.system(commandLine, myEventHandler);
}
}


function myEventHandler(cmd)
{
document.getElementById('outputArea').value=cmd.outputString;
cmd.close
}


It still only works on some terms, though, e.g., "chown" but not "chmod".


1 to 2 of 2
  1. It doesn't work
    2007-03-23 20:01:10  jeffclough [View]

  2. The Working JavaScript Function and Explanation of Error in Article
    2005-06-30 00:59:51  maymay [View]

1 to 2 of 2