I am wondering how to invoke some of Unix's shorter functions from inside
.mt script that we would run on a web server..

e.g.

to insert the date into a web page one can put this Server Side Include in
the html text:

<!--#config timefmt="%B %e, %Y" -->

but there will instances where I would rather now have such comments in the
code of the html document and would rather get the date and insert it
directly


  --Next we get today's date items
  put the long date into tToday
  put item 3 of tToday into tYear
  put word 1 of item 2 of tToday into tMonth
  put word 2 of item 2 of tToday into tDay
  if tDay is in (1,2,3,4,5,6,7,8,9) then put "0" before tDay
  put tMonth & " " & tDay & ", " & tYear into tDate
  replace "### the date ###" with tDate in tFileToServe

Question is: that's six lines of xTalk (maybe because of my poor scripting?)
vs 1 line of unix:

<!--#config timefmt="%B %e, %Y" -->

is there a way to, from within the .mt script to "send" a unix function
request and thereby shorten the code? And if so, how would be it done.

If I had one sample, that would help, then by extension I can incorporate
more "raw unix script" from within the .mt script as the need arises...

Of course one might as well also just learn to write shell script and use
those as cgi.. but there are occasions where we will want to be able to
combine the two.

Hinduism Today

Sivakatirswami
Editor's Assistant/Production Manager
[EMAIL PROTECTED] 
www.HinduismToday.com, www.HimalayanAcademy.com,
www.Gurudeva.org, www.hindu.org



Archives: http://www.mail-archive.com/[email protected]/
Info: http://www.xworlds.com/metacard/mailinglist.htm
Please send bug reports to <[EMAIL PROTECTED]>, not this list.

Reply via email to