This is my TTXticket.pm:
# ======================================================================= ticket
sub ticket {
my ($cfg, $query, $data) = @_;
checkgroups($cfg);
TTXCommon::tickedvars($cfg, $data);
$data->{THE_PORT} = $ENV{SERVER_PORT};
if ($query->param('cancel') ne undef) {
if ($query->param('sid') ne undef) {
$query->param(-name => 'tid', -value=> '');
$query->param(-name => 'do', -value=> '');
return 'helpdesk';
This is my newticket.html snippet:
</script>
<script language="JavaScript"><!--
function preview(){
hwstring="scrollbars=yes,width=600,height=500,resizable=yes,toolbar=no,menubar=no";
var newwin = window.open('', 'winpreview', hwstring);
newwin.focus();
document.forms['preview'].msg.value = document.forms['newticket'].problem.value;
document.forms['preview'].submit();
return false;
}
portSSL = "(%THE_PORT%)";
//--></script>
And this is my 'View source' output from ttx.cgi:
<script language="JavaScript"><!--
function preview(){
hwstring="scrollbars=yes,width=600,height=500,resizable=yes,toolbar=no,menubar=no";
var newwin = window.open('', 'winpreview', hwstring);
newwin.focus();
document.forms['preview'].msg.value = document.forms['newticket'].problem.value;
document.forms['preview'].submit();
return false;
}
portSSL = "";
//--></script>
There's no chance of typos, because I'm not the one typing it. Strict copy and paste.