WebGUI 3.5.1 release
This commit is contained in:
parent
0df316d3f0
commit
19fa8be10f
9 changed files with 99 additions and 62 deletions
|
|
@ -1,5 +1,5 @@
|
|||
package WebGUI;
|
||||
our $VERSION = "3.5.0";
|
||||
our $VERSION = "3.5.1";
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
# WebGUI is Copyright 2001-2002 Plain Black Software.
|
||||
|
|
|
|||
|
|
@ -98,11 +98,16 @@ sub copy {
|
|||
$newNode = WebGUI::Node->new($_[1],$_[2]);
|
||||
$a = FileHandle->new($_[0]->getPath,"r");
|
||||
$b = FileHandle->new(">".$newNode->getPath.'/'.$_[0]->getFilename);
|
||||
binmode($a);
|
||||
binmode($b);
|
||||
cp($a,$b);
|
||||
$a->close;
|
||||
$b->close;
|
||||
if (defined $a) {
|
||||
binmode($a);
|
||||
$b = FileHandle->new(">".$newNode->getPath.'/'.$_[0]->getFilename);
|
||||
if (defined $b) {
|
||||
binmode($b);
|
||||
cp($a,$b);
|
||||
$b->close;
|
||||
}
|
||||
$a->close;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ sub _recurseCrumbTrail {
|
|||
if ($data{pageId} > 1) {
|
||||
$output .= _recurseCrumbTrail($data{parentId},$_[1]);
|
||||
}
|
||||
if ($data{title} ne "") {
|
||||
if ($data{menuTitle} ne "") {
|
||||
$output .= '<a class="crumbTrail" href="'.WebGUI::URL::gateway($data{urlizedTitle})
|
||||
.'">'.$data{menuTitle}.'</a>'.$_[1];
|
||||
}
|
||||
|
|
@ -42,7 +42,7 @@ sub _replacement {
|
|||
$delimeter = " ".$param[0]." ";
|
||||
}
|
||||
$temp = '<span class="crumbTrail">'._recurseCrumbTrail($session{page}{parentId},$delimeter).
|
||||
'<a href="'.WebGUI::URL::page().'">'.$session{page}{title}.'</a></span>';
|
||||
'<a href="'.WebGUI::URL::page().'">'.$session{page}{menuTitle}.'</a></span>';
|
||||
return $temp;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ sub getStyle {
|
|||
if ($session{form}{makePrintable}) {
|
||||
%style = WebGUI::SQL->quickHash("select header,footer,styleSheet from style where styleId=3");
|
||||
$header = '<html><!-- WebGUI '.$session{wg}{version}.' -->'."\n";
|
||||
$header .= '<head><title>'.$session{page}{title}.'</title>';
|
||||
$header .= '<head><title>'.$session{page}{title}.' - '.$session{setting}{companyName}.'</title>';
|
||||
$header .= $style{styleSheet}.'</head>'.$style{header};
|
||||
$footer = $style{footer}.'</html>';
|
||||
} else {
|
||||
|
|
@ -32,11 +32,7 @@ sub getStyle {
|
|||
<html>
|
||||
<head>
|
||||
<title>';
|
||||
if ($session{page}{pageId} == 1) {
|
||||
$header .= $session{setting}{companyName}.' - '.$session{page}{title};
|
||||
} else {
|
||||
$header .= $session{page}{title};
|
||||
}
|
||||
$header .= $session{page}{title}.' - '.$session{setting}{companyName};
|
||||
$header .= '</title>'
|
||||
.$style{styleSheet}
|
||||
.$session{page}{metaTags};
|
||||
|
|
|
|||
|
|
@ -542,7 +542,7 @@ sub www_moveDownloadUp {
|
|||
|
||||
#-------------------------------------------------------------------
|
||||
sub www_view {
|
||||
my ($url, @row, $i, $p, $search, %data, @test, $file, $alt1, $alt2, $output, $sth,
|
||||
my ($url, @row, $head, $searchForm, $i, $p, $search, %data, @test, $file, $alt1, $alt2, $output, $sth,
|
||||
%download, $flag, $sort, $sortDirection);
|
||||
tie %download, 'Tie::CPHash';
|
||||
tie %data, 'Tie::CPHash';
|
||||
|
|
@ -555,11 +555,11 @@ sub www_view {
|
|||
if ($data{description} ne "") {
|
||||
$output .= $data{description}.'<p>';
|
||||
}
|
||||
$output .= formHeader();
|
||||
$output .= WebGUI::Form::text("keyword",20,50);
|
||||
$output .= WebGUI::Form::submit(WebGUI::International::get(170));
|
||||
$output .= '</form>';
|
||||
$output .= '<table cellpadding="3" cellspacing="1" border="0" width="100%">';
|
||||
$searchForm = formHeader();
|
||||
$searchForm .= WebGUI::Form::text("keyword",20,50);
|
||||
$searchForm .= WebGUI::Form::submit(WebGUI::International::get(170));
|
||||
$searchForm .= '</form>';
|
||||
$head = '<table cellpadding="3" cellspacing="1" border="0" width="100%">';
|
||||
if ($session{form}{keyword} ne "") {
|
||||
$search = " and (fileTitle like '%".$session{form}{keyword}.
|
||||
"%' or downloadFile like '%".$session{form}{keyword}.
|
||||
|
|
@ -578,7 +578,7 @@ sub www_view {
|
|||
$sortDirection = $session{form}{sortDirection};
|
||||
$url = WebGUI::URL::append($url,"sortDirection=".$session{form}{sortDirection});
|
||||
}
|
||||
$output .= '<tr><td class="tableHeader">'.
|
||||
$head .= '<tr><td class="tableHeader">'.
|
||||
sortByColumn("fileTitle",WebGUI::International::get(14,$namespace)).
|
||||
'</td><td class="tableHeader">'.
|
||||
sortByColumn("briefSynopsis",WebGUI::International::get(15,$namespace)).
|
||||
|
|
@ -633,6 +633,8 @@ sub www_view {
|
|||
WebGUI::International::get(19,$namespace).'</td></tr>';
|
||||
}
|
||||
$p = WebGUI::Paginator->new($url,\@row,$data{paginateAfter});
|
||||
$output .= $searchForm if ($p->getNumberOfPages > 1);
|
||||
$output .= $head;
|
||||
$output .= $p->getPage($session{form}{pn});
|
||||
$output .= '</table>';
|
||||
$output .= $p->getBarTraditional($session{form}{pn});
|
||||
|
|
|
|||
|
|
@ -117,7 +117,7 @@ sub www_addSave {
|
|||
my ($widgetId, $displayTitle, $image, $attachment);
|
||||
if (WebGUI::Privilege::canEditPage()) {
|
||||
$widgetId = create($session{page}{pageId},$session{form}{widget},$session{form}{title},$session{form}{displayTitle},$session{form}{description},$session{form}{processMacros},$session{form}{templatePosition});
|
||||
WebGUI::SQL->write("insert into SiteMap values ($widgetId, '$session{form}{startAtThisLevel}', '$session{form}{depth}', '$session{form}{indent}', ".quote($session{form}{bullet}).", '$session{form}{lineSpacing}', '$session{form}{displaySynopsis})");
|
||||
WebGUI::SQL->write("insert into SiteMap values ($widgetId, '$session{form}{startAtThisLevel}', '$session{form}{depth}', '$session{form}{indent}', ".quote($session{form}{bullet}).", '$session{form}{lineSpacing}', '$session{form}{displaySynopsis}')");
|
||||
return "";
|
||||
} else {
|
||||
return WebGUI::Privilege::insufficient();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue