Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: SSC Archive help files now available in HTML


From   Marcello Pagano <[email protected]>
To   [email protected]
Subject   st: SSC Archive help files now available in HTML
Date   Thu, 02 Apr 2009 11:48:34 -0400

For Ben:

---------- Forwarded message ----------
From: Ben Jann <[email protected]>
Date: Thu, Apr 2, 2009 at 10:40 AM
Subject: RE: SSC Archive help files now available in HTML
To: statalist <[email protected]>


I sent this before, but it seems it did not get through:

It is possible to translate the hyperrefs using the undocumented -log
webhtml- command and doing some post-processing. Here's a (simplified)
copy of the code I use to translate the helpfiles for the -estout-
website, e.g. http://repec.org/bocode/e/estout/hlp_esttab.html.

<--->
capt prog drop myfilefilter
prog myfilefilter
 syntax anything [ , * ]
 tempfile tmp
 qui filefilter `anything' `"`tmp'"', `options'
 qui copy `"`tmp'"' `anything', replace
end

log webhtml esttab.hlp hlp_esttab.html, ll(79) replace yebf
foreach cmd in estout esttab eststo estadd estpost {
 myfilefilter hlp_esttab.html, replace from("/help.cgi?`cmd'")
to("hlp_`cmd'.html")
}
myfilefilter hlp_esttab.html, replace from("/help.cgi?")
to("http://www.stata.com/help.cgi?";)
<--->

The link produced by -log webhtml- is hardcoded to be "/help.cgi?.."
and I use filefilter to translate this to either a relative path to
one of the -estout- help files or to "http://www.stata.com/help.cgi?";.

ben

On Sun, Mar 29, 2009 at 6:31 PM, Newson, Roger B
<[email protected]> wrote:
Thanks to Kit for the info. What we need now (as Maarten says, and in case any StataCorp people are listening) is a way to translate a group of .sthlp files to .html, translating the .smcl hyperrefs to corresponding .html hyperrefs. That would be particularly helpful for people like me, who typically document a large comprehensive package with a whole tree of .sthlp files referring to each other. I do not know how feasible this is.

*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index