package MyHTMLApplication @ISA = qw() sub CSSPath return shift->{CSSPath}; sub WebRoot return shift->{WebRoot}; sub CGIPath return shift->{CGIPath}; sub BEGIN sub new my ($module, $app) = @_; # $this->SUPER::new( return $this; sub DESTROY my $this = shift; # $this->SUPER::DESTROY( sub MenuMode return shift->{MenuMode}; sub SetMenuMode sub SetMenuMode { my ($this, $mode) = return $this->{MenuMode} = $mode; sub ConvertToHTML my ($this, $s) = @_; return $s; sub GetCSSKeys my ($App, $pParams, $SpanID, $SpanClass) = @_; return ("", "", "", ""); return ('', '', '', ''); sub GetMainMenuKeys my ($App, $pParams) = @_; return ($MainPre, "$MainPos

", $pre, $pos) if($MainPre ne ''); return ($MainPre, $MainPos, $pre, $pos); sub GetSubMenuKeys my ($App, $pParams) = @_; return ($MainPre, "$MainPos

", $pre, $pos) if($MainPre ne ''); return ($MainPre, $MainPos, $pre, $pos); sub SetHTMLHeader my ($this, $Title, $WebCharSet, $LinkTarget, $CSS, %args) = @_; sub SetHTMLInitialized my ($this, $f) = @_; return $this->{HTMLInitialized} = $f; sub PrintWithHTMLTag my ($this, $tag, @s) = @_; my $i = 0 ; $i < @s ; $i++) { my $s = $s[$i]; $s = Utils::ConvertToHTMLString($s); $this->PrintRawHTML("<$tag>$s\n"); } } else { $this->print(@s); } } #sub PrintWithHTMLTag #{ # my ($this, @args) = @_; return $this->print2(0, @args); sub PrintRawHTML my ($this, @args) = @_; sub ShowBlankPage my ($this, $title, $charset) = @_; sub IsFrameMode return (shift->{pFrameModeHash})? 1 : 0; sub GetFrameMode my ($this) = @_; return $this->pParams()->{FrameMode} if($this->pParams()->{FrameMode}); return $FrameMode; sub SetFrameMode my ($this, %args) = @_; sub InitHTMLFramePage my ($this, $WebCharSet, $PrintHTMLHeader, $pHash) = @_; sub GetURLServerName my ($this) = @_; return $head; sub GetCGIParameters my ($this, $pModifiedParams, $pKeys, $DefaultTarget, $DefaultFrameTarget, $ForFrame, $phash) = @_; return ($this->BuildCGIOption($pModifiedParams, $pKeys, $ForFrame), $target, $phash); sub BuildCGIOption my ($this, $pModifiedParams, $pKeys, $ForFrame, $phash) = @_; return $Option; sub GetClassIDOption my ($this, %args) = @_; return $option; sub BuildLinkOption my ($this, %args) = @_; return $option; sub OnOffToNum my ($App, $val) = (@_); return $val if($val =~ /^[\-\+]?\d+$/); return 0 if(!defined $val or uc $val eq 'OFF'); return 1 if(uc $val eq 'ON'); return 0; sub NumToOnOff my ($App, $val, $on, $off) = (@_); return $on if($val); return $off; sub MakeDownloadLink my ($App, $pParams, $path, $label) = @_; sub MakeHRefLinkString my ($App, $pParams, $link, $label, %args) = @_; return $s; sub MakeImageLinkString my ($App, $pParams, $src, $border, $width, %args) = @_; return $s; sub ShowImageHTML my ($this, $pParams, $Path, $border, $width, %args) = @_; sub ShowImage my ($this, $pParams, $Path) = @_; return; sub PrintFormHiddenParameter my ($this, $name, $value, $type) = @_; sub HiddenParameter my ($App, $pParams, $VarName, $CurVal, %args) = @_; return "$s\n"; sub BeginForm my ($App, $pParams, $ScriptPath, $Method, $Target, $UseUploadFile, %args) = @_; ($App, $ScriptPath, $Method, $Target, $UseUploadFile) = sub BeginForm_old my ($this, $ScriptPath, $Method, $Target, $ForFileUpload) = @_; sub EndForm my ($App, $pParams, $pModifiedParams, $pKeys) = @_; $App->EndForm_old( sub EndForm_old my ($this, $pModifiedParams, $pKeys, $SubmitButtonName, $SubmitButtonValue) = @_; sub PrintFormButton my ($this, $name, $value, $type) = @_; sub Button my ($App, $pParams, $VarName, $CurVal, %args) = @_; return "$s\n"; sub BeginItem my ($this, $IsNumbered) = @_; sub EndItem my ($this, $IsNumbered) = @_; sub PrintItem my ($this, $str) = @_; sub BeginItemElement my ($this) = @_; sub EndItemElement my ($this) = @_; sub BeginTable my ($this, $border, $nColumns, %args) = @_; sub EndTable my ($this) = @_; sub BeginTableHeader my ($this) = @_; sub EndTableHeader my ($this) = @_; sub BeginTableBody my ($this) = @_; sub EndTableBody my ($this) = @_; sub BeginTableItem my ($this) = @_; return if($this->{nColumns} == 0); sub EndTableItem my ($this) = @_; return if($this->{nColumns} == 0); sub BeginRow my ($this) = @_; sub EndRow my ($this) = @_; return if($this->{nRow} <= 0); sub BeginTableRow my ($this, $pRows) = @_; sub EndTableRow my ($this, $pRows) = @_; sub TableRow my ($this, $pRows, $format, $idx) = @_; sub TableCell my ($this, $Label, $pHash, $bra, $ket, $format, $idx) = @_; return if(lc $option eq 'none'); sub TableRowByArray my ($this, $pArray, $pHash, $bra, $ket, $format, $idx) = @_; sub TableRowByDefinition my ($this, $pDef, $idx, $pHash, $bra, $ket, $format) = @_; sub PrintRadioItem my ($this, $FormName, $Value, $Label, $Checked) = @_; sub Checkbox my ($App, $VarName, $CurVal, $label, $charcode, %args) = @_; return "$s\n"; sub BuildCheckboxString my ($App, $VarName, $CurVal, $label, $charcode, %args) = @_; return "$label"; sub GetCheckboxListString my ($this, $pParams, $pArray, $Key) = @_; return $pArray->[$i+1]{$lang}; return $Key; sub GetCheckboxListFormString my ($this, $pParams, $pArray, $CurVal, $pre, $post, %args) = @_; return $s; my ($this, $pParams, $pArray, $CurVal) = @_; return $s; my ($this, $pParams, $pArray, $Key) = @_; return $pArray->[$i+1]{$lang}; return $Key; sub PrintCheckbox my ($this, $FormName, $Value, $Label, $Checked) = @_; sub FillCheckboxParams my ($this, $pParams, $pArray, $value) = @_; sub TextArea my ($App, $pParams, $VarName, $CurVal, $rows, $cols, %args) = @_; return "$s\n"; sub Textbox my ($App, $VarName, $Width, $CurVal, $label, $charcode, %args) = @_; return "$s\n"; sub BuildTextboxString my ($App, $VarName, $Width, $CurVal, $charcode, %args) = @_; return ""; sub FileSubmitbox my ($App, $VarName, $Width, $CurVal, $label, $charcode, %args) = @_; return "$s\n"; sub BuildFileSubmitboxString my ($App, $VarName, $Width, $CurVal, $charcode, %args) = @_; return ""; sub PasswordTextbox my ($App, $VarName, $Width, $CurVal, $label, $charcode, %args) = @_; return "$s\n"; sub BuildPasswordTextboxString my ($App, $VarName, $Width, $CurVal, $charcode, %args) = @_; return ""; sub GetGenderSelectionFormString my ($App, $pParams, $FormName, $curval, %args) = @_; return $App->GetSelectionFormString($pParams, $FormName, $curval, \@GenderSelection, undef, undef, %args); sub GenderString my ($App, $pParams, $sel, $code) = @_; return $s; sub GetnLanguage my ($App) = @_; return int(@$plist / 2); sub GetLanguageSelectFormString my ($App, %args) = @_; return $str; sub YesNoByLanguage my ($App, $g) = @_; return $g if($App->Language() eq 'en'); return "はい" if($g =~ /Ye/i); return "いいえ" if($g =~ /No/i); return "選択されていません"; sub GenderByLanguage my ($App, $g) = @_; return $g if($App->Language() eq 'en'); return "女性" if($g =~ /female/i); return "男性" if($g =~ /male/i); return "選択されていません"; sub GetSelectionListStringByArray my ($this, $pParams, $pArray, $Key) = @_; return '' if($Key eq ''); return $pArray->[$1]; return $Key; sub GetSelectionListFormStringByArray my ($this, $pParams, $pArray, $FormName, $CurVal, $pAdditionalSelections) = @_; return $str; sub GetFileSelectFormString my ($App, $pParams, $dir, $fmask, $FormName, $CurVal, $pAdditionalSelections, %args) = @_; return $s; sub GetSelectionListString my ($this, $pParams, $pArray, $Key) = @_; return '' if($Key eq ''); return $pArray->[$i+1]->{$lang}; return $Key; sub GetSelectionListFormStringBySimpleArray my ($App, $pParams, $pArray, $FormName, $CurVal, $pAdditionalSelections, %args) = @_; return $str; sub GetSelectionListFormString my ($App, $pParams, $pArray, $FormName, $CurVal, $pAdditionalSelections, %args) = @_; return $str; sub GetSelectionFormString my ($App, $pParams, $FormName, $curval, $pSelection, $pPre, $pPost, %args) = @_; return $pPre->{$lang} . $str . $pPost->{$lang}; sub GetStringByArray my ($App, $pParams, $sel, $pSelection, $default) = @_; return $pSelection->[$i+1]->{$lang}; return $default; sub BuildDropdownListboxString my ($App, $FormName, $CurVal, $pSel, $charcode, $lang, %args) = @_; return $s; sub BuildDropdownListboxStringByArray my ($App, $FormName, $CurVal, $pSel, $charcode, $lang, %args) = @_; return $s; sub BuildFormSelectString0 my ($App, $FormName, $CurVal, $PreMessage, $PostMessage, $pSel, $charcode, %args) = @_; return $s; sub BuildFormSelectString my ($App, $FormName, $CurVal, $PreMessage, $PostMessage, $pSel, $charcode, %args) = @_; return '' if(@$pSel <= 0); return $s; sub BuildFormSelectString2 my ($App, $FormName, $CurVal, $PreMessage, $PostMessage, $pSel1, $pSel2, $charcode, %args) = @_; return $App->BuildFormSelectString($FormName, $CurVal, $PreMessage, $PostMessage, \@List, $charcode, %args); sub BeginMenu my ($this, $IDName) = @_; return if($IDName eq ''); sub EndMenu my ($this, $classname) = @_; sub BeginDiv my ($this, $IDName) = @_; sub EndDiv my ($this, $classname) = @_; sub BeginSpan my ($this, $IDName) = @_; sub EndSpan my ($this, $classname) = @_; sub UploadFile my ($App, $pParams, $form, %args) = @_; ($App, $form, %args) = return undef; return ('', "CGIFormError:$form->cgi_error"); return ('', "TransferError:$max"); return ('', 'CantGetUploadInfo'); return ('', "TooLarge:$sizestr,$max"); return ('', "CantGetLocalFileName:$ClientFilePath"); return ('', "InvalidFileType:$ext,$mimetype"); return ('', "InvalidFileType:$ext,$mimetype"); return ('', "Error in ConfApp3::UploadFile: SaveError: $ServerFilePath"); return ('', "CloseFileError:$ServerFilePath"); return ($ServerFilePath, "OK"); sub UploadFile_old my ($App, $form, %args) = @_; return ('', "FileNameError: File name not specified"); return ('', $err); return ('', "TransferError:$max"); return ('', '') if(!defined $inf); return ('', "TooLarge:$sizestr,$max"); return ('', 'CantGetLocalFileName'); return ('', "InvalidFileType:$error"); return ('', "InvalidFileType:$error"); return ('', 'UniqueFileNameError'); return ('', 'SaveError'); return ('', 'CloseFileError'); return ($ServerFile, ''); sub DownloadFile my ($App, $LocalPath, $DownloadFileName, $Contents) = @_; my $pParams = $App->pParams(); #$App->print("ref: ", $App, " l[$LocalPath]\n"); if($LocalPath =~ /=HASH\(/) { # if(ref $LocalPath eq 'HASH') { my $a; ($a, $App, $pParams) = @_; return; return 1;