User:Scsbot/formtools/formgettmpfile

tag=$1 fieldname=$2

td=td$tag

if test ! -d $td then echo "$tag not set up" &gt;&amp;2 exit 1 fi

if test ! -f $td/.cur then echo "$tag: no form selected" &gt;&amp;2 exit 1 fi

formid=`cat $td/.cur`

if test ! -d $td/$formid -o ! -f $td/$formid/.toc then echo "$tag: form not set up" &gt;&amp;2 exit 1 fi


 * 1) actually, don't really need TOC yet...

if test -f $td/$formid/$fieldname then echo $td/$formid/$fieldname exit 0 else # maybe print error message, though need -q to turn off # (see wpSummary fetch in wikised) exit 1 fi