WebGUI 2.5.0 release
This commit is contained in:
parent
6286f9bfaf
commit
00aec56a04
65 changed files with 3006 additions and 369 deletions
|
|
@ -17,9 +17,7 @@ use WebGUI::Session;
|
|||
sub process {
|
||||
my ($output);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^\@(.*?)\;/) {
|
||||
$output =~ s/\^\@(.*?)\;/$session{user}{username}/;
|
||||
}
|
||||
$output =~ s/\^\@\;/$session{user}{username}/g;
|
||||
#---everything below this line will go away in a later rev.
|
||||
if ($output =~ /\^\@/) {
|
||||
$output =~ s/\^\@/$session{user}{username}/g;
|
||||
|
|
|
|||
|
|
@ -17,9 +17,7 @@ use WebGUI::Session;
|
|||
sub process {
|
||||
my ($output);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^\\(.*?)\;/) {
|
||||
$output =~ s/\^\\(.*?)\;/$session{page}{url}/;
|
||||
}
|
||||
$output =~ s/\^\\\;/$session{page}{url}/g;
|
||||
#---everything below this line will go away in a later rev.
|
||||
if ($output =~ /\^\\/) {
|
||||
$output =~ s/\^\\/$session{page}{url}/g;
|
||||
|
|
|
|||
|
|
@ -31,14 +31,18 @@ sub _recurseCrumbTrail {
|
|||
return $output;
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub _replacement {
|
||||
my (@param, $temp);
|
||||
$temp = '<span class="crumbTrail">'._recurseCrumbTrail($session{page}{parentId}).'<a href="'.$session{page}{url}.'">'.$session{page}{title}.'</a></span>';
|
||||
return $temp;
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output, $temp);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^C(.*?)\;/) {
|
||||
$temp = '<span class="crumbTrail">'._recurseCrumbTrail($session{page}{parentId}).'<a href="'.$session{page}{url}.'">'.$session{page}{title}.'</a></span>';
|
||||
$output =~ s/\^C(.*?)\;/$temp/;
|
||||
}
|
||||
$output =~ s/\^C\;/_replacement()/ge;
|
||||
#---everything below this line will go away in a later rev.
|
||||
if ($output =~ /\^C/) {
|
||||
$temp = '<span class="crumbTrail">'._recurseCrumbTrail($session{page}{parentId}).'<a href="'.$session{page}{url}.'">'.$session{page}{title}.'</a></span>';
|
||||
|
|
|
|||
|
|
@ -14,19 +14,24 @@ use strict;
|
|||
use WebGUI::DateTime;
|
||||
use WebGUI::Macro;
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub _replacement {
|
||||
my (@param, $temp);
|
||||
@param = WebGUI::Macro::getParams($_[0]);
|
||||
if ($param[0] ne "") {
|
||||
$temp = epochToHuman(time(),$param[0]);
|
||||
} else {
|
||||
$temp = localtime(time());
|
||||
}
|
||||
return $temp;
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output, $temp, @param);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^D(.*?)\;/) {
|
||||
@param = WebGUI::Macro::getParams($1);
|
||||
if ($param[0] ne "") {
|
||||
$temp = epochToHuman(time(),$param[0]);
|
||||
} else {
|
||||
$temp = localtime(time());
|
||||
}
|
||||
$output =~ s/\^D(.*?)\;/$temp/;
|
||||
}
|
||||
$output =~ s/\^D\((.*?)\)\;/_replacement($1)/ge;
|
||||
$output =~ s/\^D\;/_replacement()/ge;
|
||||
#---everything below this line will go away in a later rev.
|
||||
if ($output =~ /\^D(.*)\^\/D/) {
|
||||
$temp = epochToHuman(time(),$1);
|
||||
|
|
|
|||
|
|
@ -15,21 +15,26 @@ use WebGUI::International;
|
|||
use WebGUI::Macro;
|
||||
use WebGUI::Session;
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub _replacement {
|
||||
my (@param, $temp);
|
||||
@param = WebGUI::Macro::getParams($1);
|
||||
$temp = '<a class="homeLink" href="'.$session{env}{SCRIPT_NAME}.'/home">';
|
||||
if ($param[0] ne "") {
|
||||
$temp .= $param[0];
|
||||
} else {
|
||||
$temp .= WebGUI::International::get(47);
|
||||
}
|
||||
$temp .= '</a>';
|
||||
return $temp;
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output, $temp, @param);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^H(.*?)\;/) {
|
||||
@param = WebGUI::Macro::getParams($1);
|
||||
$temp = '<a class="homeLink" href="'.$session{env}{SCRIPT_NAME}.'/home">';
|
||||
if ($param[0] ne "") {
|
||||
$temp .= $param[0];
|
||||
} else {
|
||||
$temp .= WebGUI::International::get(47);
|
||||
}
|
||||
$temp .= '</a>';
|
||||
$output =~ s/\^H(.*?)\;/$temp/;
|
||||
}
|
||||
$output =~ s/\^H\((.*?)\)\;/_replacement($1)/ge;
|
||||
$output =~ s/\^H\;/_replacement()/ge;
|
||||
#---everything below this line will go away in a later rev.
|
||||
if ($output =~ /\^H(.*)\^\/H/) {
|
||||
$temp = '<a class="homeLink" href="'.$session{env}{SCRIPT_NAME}.'/home">'.$1.'</a>';
|
||||
|
|
|
|||
|
|
@ -17,9 +17,7 @@ use WebGUI::Session;
|
|||
sub process {
|
||||
my ($output);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^\#(.*?)\;/) {
|
||||
$output =~ s/\^\#(.*?)\;/$session{user}{userId}/;
|
||||
}
|
||||
$output =~ s/\^\#\;/$session{user}{userId}/g;
|
||||
#---everything below this line will go away in a later rev.
|
||||
if ($output =~ /\^\#/) {
|
||||
$output =~ s/\^\#/$session{user}{userId}/g;
|
||||
|
|
|
|||
|
|
@ -16,33 +16,37 @@ use WebGUI::International;
|
|||
use WebGUI::Macro::Backslash_pageUrl;
|
||||
use WebGUI::Session;
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub _replacement {
|
||||
my ($temp);
|
||||
$temp = '<div class="loginBox">';
|
||||
if ($session{var}{sessionId}) {
|
||||
$temp .= WebGUI::International::get(48);
|
||||
$temp .= ' <a href="'.$session{page}{url}.'?op=displayAccount">'.$session{user}{username}.'</a>.';
|
||||
$temp .= WebGUI::International::get(49);
|
||||
$temp = WebGUI::Macro::Backslash_pageUrl::process($temp);
|
||||
} else {
|
||||
$temp .= '<form method="post" action="'.$session{page}{url}.'"> ';
|
||||
$temp .= WebGUI::Form::hidden("op","login").'<span class="formSubtext">';
|
||||
$temp .= WebGUI::International::get(50);
|
||||
$temp .= '<br></span>';
|
||||
$temp .= WebGUI::Form::text("username",12,30).'<span class="formSubtext"><br>';
|
||||
$temp .= WebGUI::International::get(51);
|
||||
$temp .= '<br></span>';
|
||||
$temp .= WebGUI::Form::password("identifier",12,30).'<span class="formSubtext"><br></span>';
|
||||
$temp .= WebGUI::Form::submit(WebGUI::International::get(52));
|
||||
$temp .= '</form>';
|
||||
$temp .= '<a href="'.$session{page}{url}.'?op=createAccount">Click here to register.</a>';
|
||||
}
|
||||
$temp .= '</div>';
|
||||
return $temp;
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output, $temp);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^L(.*?)\;/) {
|
||||
$temp = '<div class="loginBox">';
|
||||
if ($session{var}{sessionId}) {
|
||||
$temp .= WebGUI::International::get(48);
|
||||
$temp .= ' <a href="'.$session{page}{url}.'?op=displayAccount">'.$session{user}{username}.'</a>. ';
|
||||
$temp .= WebGUI::International::get(49);
|
||||
$temp = WebGUI::Macro::Backslash_pageUrl::process($temp);
|
||||
} else {
|
||||
$temp .= '<form method="post" action="'.$session{page}{url}.'"> ';
|
||||
$temp .= WebGUI::Form::hidden("op","login").'<span class="formSubtext">';
|
||||
$temp .= WebGUI::International::get(50);
|
||||
$temp .= '<br></span>';
|
||||
$temp .= WebGUI::Form::text("username",12,30).'<span class="formSubtext"><br>';
|
||||
$temp .= WebGUI::International::get(51);
|
||||
$temp .= '<br></span>';
|
||||
$temp .= WebGUI::Form::password("identifier",12,30).'<span class="formSubtext"><br></span>';
|
||||
$temp .= WebGUI::Form::submit(WebGUI::International::get(52));
|
||||
$temp .= '</form>';
|
||||
$temp .= '<a href="'.$session{page}{url}.'?op=createAccount">Click here to register.</a>';
|
||||
}
|
||||
$temp .= '</div>';
|
||||
$output =~ s/\^L(.*?)\;/$temp/;
|
||||
}
|
||||
$output =~ s/\^L\;/_replacement()/ge;
|
||||
#---everything below this line will go away in a later rev.
|
||||
if ($output =~ /\^L/) {
|
||||
$temp = '<div class="loginBox">';
|
||||
|
|
|
|||
|
|
@ -15,21 +15,26 @@ use WebGUI::Macro;
|
|||
use WebGUI::Macro::Shared;
|
||||
use WebGUI::Session;
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub _replacement {
|
||||
my ($output, $temp, @param);
|
||||
@param = WebGUI::Macro::getParams($_[0]);
|
||||
$temp = '<span class="verticalMenu">';
|
||||
if ($param[0] ne "") {
|
||||
$temp .= traversePageTree($session{page}{pageId},0,$param[0]);
|
||||
} else {
|
||||
$temp .= traversePageTree($session{page}{pageId},0,1);
|
||||
}
|
||||
$temp .= '</span>';
|
||||
return $temp;
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output, $temp, @param);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^M(.*?)\;/) {
|
||||
@param = WebGUI::Macro::getParams($1);
|
||||
$temp = '<span class="verticalMenu">';
|
||||
if ($param[0] ne "") {
|
||||
$temp .= traversePageTree($session{page}{pageId},0,$param[0]);
|
||||
} else {
|
||||
$temp .= traversePageTree($session{page}{pageId},0,1);
|
||||
}
|
||||
$temp .= '</span>';
|
||||
$output =~ s/\^M(.*?)\;/$temp/;
|
||||
}
|
||||
$output =~ s/\^M\((.*?)\)\;/_replacement($1)/ge;
|
||||
$output =~ s/\^M\;/_replacement()/ge;
|
||||
#---everything below this line will go away in a later rev.
|
||||
if ($output =~ /\^M(.*)\^\/M/) {
|
||||
$temp = '<span class="verticalMenu">';
|
||||
|
|
|
|||
|
|
@ -16,20 +16,25 @@ use WebGUI::Macro::Shared;
|
|||
use WebGUI::Session;
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output, $temp, @param);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^P(.*?)\;/) {
|
||||
@param = WebGUI::Macro::getParams($1);
|
||||
$temp = '<span class="verticalMenu">';
|
||||
if ($param[0] ne "") {
|
||||
$temp .= traversePageTree($session{page}{parentId},0,$param[0]);
|
||||
} else {
|
||||
$temp .= traversePageTree($session{page}{parentId},0,1);
|
||||
}
|
||||
$temp .= '</span>';
|
||||
$output =~ s/\^P(.*?)\;/$temp/;
|
||||
sub _replacement {
|
||||
my ($temp, @param);
|
||||
@param = WebGUI::Macro::getParams($_[0]);
|
||||
$temp = '<span class="verticalMenu">';
|
||||
if ($param[0] ne "") {
|
||||
$temp .= traversePageTree($session{page}{parentId},0,$param[0]);
|
||||
} else {
|
||||
$temp .= traversePageTree($session{page}{parentId},0,1);
|
||||
}
|
||||
$temp .= '</span>';
|
||||
return $temp;
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output,$temp);
|
||||
$output = $_[0];
|
||||
$output =~ s/\^P\((.*?)\)\;/_replacement($1)/ge;
|
||||
$output =~ s/\^P\;/_replacement()/ge;
|
||||
#---everything below this line will go away in a later rev.
|
||||
if ($output =~ /\^P(.*)\^\/P/) {
|
||||
$temp = '<span class="verticalMenu">';
|
||||
|
|
|
|||
33
lib/WebGUI/Macro/Question_search.pm
Normal file
33
lib/WebGUI/Macro/Question_search.pm
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
package WebGUI::Macro::Question_search;
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
# WebGUI is Copyright 2001 Plain Black Software.
|
||||
#-------------------------------------------------------------------
|
||||
# Please read the legal notices (docs/legal.txt) and the license
|
||||
# (docs/license.txt) that came with this distribution before using
|
||||
# this software.
|
||||
#-------------------------------------------------------------------
|
||||
# http://www.plainblack.com info@plainblack.com
|
||||
#-------------------------------------------------------------------
|
||||
|
||||
use strict;
|
||||
use WebGUI::Form;
|
||||
use WebGUI::International;
|
||||
use WebGUI::Session;
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output, $temp);
|
||||
$output = $_[0];
|
||||
$temp = '<form class="searchBox" method="post" action="'.$session{page}{url}.'">';
|
||||
$temp .= WebGUI::Form::hidden("op","search");
|
||||
$temp .= WebGUI::Form::text("keywords",10,100,$session{form}{keywords});
|
||||
$temp .= WebGUI::Form::submit(WebGUI::International::get(364));
|
||||
$temp .= '</form>';
|
||||
$output =~ s/\^\?\;/$temp/g;
|
||||
return $output;
|
||||
}
|
||||
|
||||
|
||||
|
||||
1;
|
||||
|
|
@ -18,22 +18,27 @@ use WebGUI::Session;
|
|||
use WebGUI::SQL;
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output, $temp, @param, @data);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^S(.*?)\;/) {
|
||||
@param = WebGUI::Macro::getParams($1);
|
||||
if ($param[1] eq "") {
|
||||
$param[1] = 0;
|
||||
}
|
||||
@data = WebGUI::SQL->quickArray("select pageId,title,urlizedTitle from page where urlizedTitle='$param[0]'",$session{dbh});
|
||||
$temp = '<span class="verticalMenu">';
|
||||
if (defined $data[0] && WebGUI::Privilege::canViewPage($data[0])) {
|
||||
$temp .= traversePageTree($data[0],1,$param[1]);
|
||||
}
|
||||
$temp .= '</span>';
|
||||
$output =~ s/\^S(.*?)\;/$temp/;
|
||||
sub _replacement {
|
||||
my ($temp, @param, @data);
|
||||
@param = WebGUI::Macro::getParams($_[0]);
|
||||
if ($param[1] eq "") {
|
||||
$param[1] = 0;
|
||||
}
|
||||
@data = WebGUI::SQL->quickArray("select pageId,title,urlizedTitle from page where urlizedTitle='$param[0]'",$session{dbh});
|
||||
$temp = '<span class="verticalMenu">';
|
||||
if (defined $data[0] && WebGUI::Privilege::canViewPage($data[0])) {
|
||||
$temp .= traversePageTree($data[0],1,$param[1]);
|
||||
}
|
||||
$temp .= '</span>';
|
||||
return $temp;
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output,$temp, @param, @data);
|
||||
$output = $_[0];
|
||||
$output =~ s/\^S\((.*?)\)\;/_replacement($1)/ge;
|
||||
$output =~ s/\^S\;/_replacement()/ge;
|
||||
#---everything below this line will go away in a later rev.
|
||||
my ($pageTitle, $depth);
|
||||
if ($output =~ /\^S(.*)\^\/S/) {
|
||||
|
|
|
|||
|
|
@ -40,7 +40,7 @@ sub traversePageTree {
|
|||
while (@data = $sth->array) {
|
||||
if (WebGUI::Privilege::canViewPage($data[2])) {
|
||||
$output .= $depth.'<a class="verticalMenu" href="'.$session{env}{SCRIPT_NAME}.'/'.$data[0].'">'.$data[1].'</a><br>';
|
||||
$output .= traversePageTree($data[2],$_[1]+1,$_[2]);
|
||||
$output .= traversePageTree($data[2],$_[1]+1,$toLevel);
|
||||
}
|
||||
}
|
||||
$sth->finish;
|
||||
|
|
|
|||
27
lib/WebGUI/Macro/Slash_gatewayUrl.pm
Normal file
27
lib/WebGUI/Macro/Slash_gatewayUrl.pm
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
package WebGUI::Macro::Slash_gatewayUrl;
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
# WebGUI is Copyright 2001 Plain Black Software.
|
||||
#-------------------------------------------------------------------
|
||||
# Please read the legal notices (docs/legal.txt) and the license
|
||||
# (docs/license.txt) that came with this distribution before using
|
||||
# this software.
|
||||
#-------------------------------------------------------------------
|
||||
# http://www.plainblack.com info@plainblack.com
|
||||
#-------------------------------------------------------------------
|
||||
|
||||
use strict;
|
||||
use WebGUI::Session;
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output);
|
||||
$output = $_[0];
|
||||
$output =~ s/\^\/\;/$session{ENV}{SCRIPT_NAME}/g;
|
||||
return $output;
|
||||
}
|
||||
|
||||
|
||||
|
||||
1;
|
||||
|
||||
|
|
@ -15,18 +15,23 @@ use WebGUI::Macro;
|
|||
use WebGUI::Utility;
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output, $temp, @param);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^\*(.*?)\;/) {
|
||||
@param = WebGUI::Macro::getParams($1);
|
||||
if ($param[0] ne "") {
|
||||
$temp = round(rand()*$1);
|
||||
} else {
|
||||
$temp = round(rand()*1000000000);
|
||||
}
|
||||
$output =~ s/\^\*(.*?)\;/$temp/;
|
||||
sub _replacement {
|
||||
my ($temp, @param);
|
||||
@param = WebGUI::Macro::getParams($_[0]);
|
||||
if ($param[0] ne "") {
|
||||
$temp = round(rand()*$1);
|
||||
} else {
|
||||
$temp = round(rand()*1000000000);
|
||||
}
|
||||
return $temp;
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output,$temp);
|
||||
$output = $_[0];
|
||||
$output =~ s/\^\*\((.*?)\)\;/_replacement($1)/ge;
|
||||
$output =~ s/\^\*\;/_replacement()/ge;
|
||||
#---everything below this line will go away in a later rev.
|
||||
if ($output =~ /\^\*(.*)\^\/\*/) {
|
||||
$temp = round(rand()*$1);
|
||||
|
|
|
|||
|
|
@ -15,20 +15,25 @@ use WebGUI::Macro;
|
|||
use WebGUI::Macro::Shared;
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output, $temp, @param);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^T(.*?)\;/) {
|
||||
@param = WebGUI::Macro::getParams($1);
|
||||
$temp = '<span class="verticalMenu">';
|
||||
if ($param[0] ne "") {
|
||||
$temp .= traversePageTree(1,0,$param[0]);
|
||||
} else {
|
||||
$temp .= traversePageTree(1,0,1);
|
||||
}
|
||||
$temp .= '</span>';
|
||||
$output =~ s/\^T(.*?)\;/$temp/;
|
||||
sub _replacement {
|
||||
my ($temp, @param);
|
||||
@param = WebGUI::Macro::getParams($_[0]);
|
||||
$temp = '<span class="verticalMenu">';
|
||||
if ($param[0] ne "") {
|
||||
$temp .= traversePageTree(1,0,$param[0]);
|
||||
} else {
|
||||
$temp .= traversePageTree(1,0,1);
|
||||
}
|
||||
$temp .= '</span>';
|
||||
return $temp;
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output,$temp);
|
||||
$output = $_[0];
|
||||
$output =~ s/\^T\((.*?)\)\;/_replacement($1)/ge;
|
||||
$output =~ s/\^T\;/_replacement()/ge;
|
||||
#---everything below this line will go away in a later rev.
|
||||
if ($output =~ /\^T(.*)\^\/T/) {
|
||||
$temp = '<span class="verticalMenu">';
|
||||
|
|
|
|||
|
|
@ -16,20 +16,25 @@ use WebGUI::Macro;
|
|||
use WebGUI::Session;
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output, $temp, @param);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^a(.*?)\;/) {
|
||||
@param = WebGUI::Macro::getParams($1);
|
||||
$temp = '<a class="myAccountLink" href="'.$session{page}{url}.'?op=displayAccount">';
|
||||
if ($param[0] ne "") {
|
||||
$temp .= $param[0];
|
||||
} else {
|
||||
$temp .= WebGUI::International::get(46);
|
||||
}
|
||||
$temp .= '</a>';
|
||||
$output =~ s/\^a(.*?)\;/$temp/;
|
||||
sub _replacement {
|
||||
my (@param, $temp);
|
||||
@param = WebGUI::Macro::getParams($_[0]);
|
||||
$temp = '<a class="myAccountLink" href="'.$session{page}{url}.'?op=displayAccount">';
|
||||
if ($param[0] ne "") {
|
||||
$temp .= $param[0];
|
||||
} else {
|
||||
$temp .= WebGUI::International::get(46);
|
||||
}
|
||||
$temp .= '</a>';
|
||||
return $temp;
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output, $temp);
|
||||
$output = $_[0];
|
||||
$output =~ s/\^a\((.*?)\)\;/_replacement($1)/ge;
|
||||
$output =~ s/\^a\;/_replacement()/ge;
|
||||
#---everything below this line will go away in a later rev.
|
||||
if ($output =~ /\^a(.*)\^\/a/) {
|
||||
$temp = '<a class="myAccountLink" href="'.$session{page}{url}.'?op=displayAccount">'.$1.'</a>';
|
||||
|
|
@ -43,3 +48,4 @@ sub process {
|
|||
|
||||
1;
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -17,9 +17,7 @@ use WebGUI::Session;
|
|||
sub process {
|
||||
my ($output);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^c(.*?)\;/) {
|
||||
$output =~ s/\^c(.*?)\;/$session{setting}{companyName}/;
|
||||
}
|
||||
$output =~ s/\^c\;/$session{setting}{companyName}/g;
|
||||
#---everything below this line will go away in a later rev.
|
||||
if ($output =~ /\^c/) {
|
||||
$output =~ s/\^c/$session{setting}{companyName}/g;
|
||||
|
|
|
|||
|
|
@ -17,9 +17,7 @@ use WebGUI::Session;
|
|||
sub process {
|
||||
my ($output);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^e(.*?)\;/) {
|
||||
$output =~ s/\^e(.*?)\;/$session{setting}{companyEmail}/;
|
||||
}
|
||||
$output =~ s/\^e\;/$session{setting}{companyEmail}/g;
|
||||
#---everything below this line will go away in a later rev.
|
||||
if ($output =~ /\^e/) {
|
||||
$output =~ s/\^e/$session{setting}{companyEmail}/g;
|
||||
|
|
|
|||
|
|
@ -15,28 +15,32 @@ use WebGUI::Privilege;
|
|||
use WebGUI::Session;
|
||||
use WebGUI::SQL;
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub _replacement {
|
||||
my ($temp, @data, $sth, $first);
|
||||
$temp = '<span class="horizontalMenu">';
|
||||
$first = 1;
|
||||
$sth = WebGUI::SQL->read("select title,urlizedTitle,pageId from page where parentId=$session{page}{pageId} order by sequenceNumber",$session{dbh});
|
||||
while (@data = $sth->array) {
|
||||
if (WebGUI::Privilege::canViewPage($data[2])) {
|
||||
if ($first) {
|
||||
$first = 0;
|
||||
} else {
|
||||
$temp .= " · ";
|
||||
}
|
||||
$temp .= '<a class="horizontalMenu" href="'.$session{env}{SCRIPT_NAME}.'/'.$data[1].'">'.$data[0].'</a>';
|
||||
}
|
||||
}
|
||||
$sth->finish;
|
||||
$temp .= '</span>';
|
||||
return $temp;
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output, $temp, @data, $sth, $first);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^m(.*?)\;/) {
|
||||
$temp = '<span class="horizontalMenu">';
|
||||
$first = 1;
|
||||
$sth = WebGUI::SQL->read("select title,urlizedTitle,pageId from page where parentId=$session{page}{pageId} order by sequenceNumber",$session{dbh});
|
||||
while (@data = $sth->array) {
|
||||
if (WebGUI::Privilege::canViewPage($data[2])) {
|
||||
if ($first) {
|
||||
$first = 0;
|
||||
} else {
|
||||
$temp .= " · ";
|
||||
}
|
||||
$temp .= '<a class="horizontalMenu" href="'.$session{env}{SCRIPT_NAME}.'/'.$data[1].'">'.$data[0].'</a>';
|
||||
}
|
||||
}
|
||||
$sth->finish;
|
||||
$temp .= '</span>';
|
||||
$output =~ s/\^m(.*?)\;/$temp/;
|
||||
}
|
||||
$output =~ s/\^m\;/_replacement()/ge;
|
||||
#---everything below this line will go away in a later rev.
|
||||
if ($output =~ /\^m/) {
|
||||
$temp = '<span class="horizontalMenu">';
|
||||
|
|
|
|||
|
|
@ -16,28 +16,32 @@ use WebGUI::Privilege;
|
|||
use WebGUI::Session;
|
||||
use WebGUI::SQL;
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub _replacement {
|
||||
my ($temp, @data, $sth, $first);
|
||||
$temp = '<span class="horizontalMenu">';
|
||||
$first = 1;
|
||||
$sth = WebGUI::SQL->read("select title,urlizedTitle,pageId from page where parentId=$session{page}{parentId} order by sequenceNumber",$session{dbh});
|
||||
while (@data = $sth->array) {
|
||||
if (WebGUI::Privilege::canViewPage($data[2])) {
|
||||
if ($first) {
|
||||
$first = 0;
|
||||
} else {
|
||||
$temp .= " · ";
|
||||
}
|
||||
$temp .= '<a class="horizontalMenu" href="'.$session{env}{SCRIPT_NAME}.'/'.$data[1].'">'.$data[0].'</a>';
|
||||
}
|
||||
}
|
||||
$sth->finish;
|
||||
$temp .= '</span>';
|
||||
return $temp;
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output, $temp, @data, $sth, $first);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^p(.*?)\;/) {
|
||||
$temp = '<span class="horizontalMenu">';
|
||||
$first = 1;
|
||||
$sth = WebGUI::SQL->read("select title,urlizedTitle,pageId from page where parentId=$session{page}{parentId} order by sequenceNumber",$session{dbh});
|
||||
while (@data = $sth->array) {
|
||||
if (WebGUI::Privilege::canViewPage($data[2])) {
|
||||
if ($first) {
|
||||
$first = 0;
|
||||
} else {
|
||||
$temp .= " · ";
|
||||
}
|
||||
$temp .= '<a class="horizontalMenu" href="'.$session{env}{SCRIPT_NAME}.'/'.$data[1].'">'.$data[0].'</a>';
|
||||
}
|
||||
}
|
||||
$sth->finish;
|
||||
$temp .= '</span>';
|
||||
$output =~ s/\^p(.*?)\;/$temp/;
|
||||
}
|
||||
$output =~ s/\^p\;/_replacement()/ge;
|
||||
#---everything below this line will go away in a later rev.
|
||||
if ($output =~ /\^p/) {
|
||||
$temp = '<span class="horizontalMenu">';
|
||||
|
|
|
|||
|
|
@ -17,21 +17,26 @@ use WebGUI::Session;
|
|||
use WebGUI::Utility;
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output, $temp, @param);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^r(.*?)\;/) {
|
||||
@param = WebGUI::Macro::getParams($1);
|
||||
$temp = appendToUrl($session{env}{REQUEST_URI},'makePrintable=1');
|
||||
$temp = '<a class="makePrintableLink" href="'.$temp.'">';
|
||||
if ($param[0] ne "") {
|
||||
$temp .= $param[0];
|
||||
} else {
|
||||
$temp .= WebGUI::International::get(53);
|
||||
}
|
||||
$temp .= '</a>';
|
||||
$output =~ s/\^r(.*?)\;/$temp/;
|
||||
sub _replacement {
|
||||
my ($temp, @param);
|
||||
@param = WebGUI::Macro::getParams($_[0]);
|
||||
$temp = appendToUrl($session{env}{REQUEST_URI},'makePrintable=1');
|
||||
$temp = '<a class="makePrintableLink" href="'.$temp.'">';
|
||||
if ($param[0] ne "") {
|
||||
$temp .= $param[0];
|
||||
} else {
|
||||
$temp .= WebGUI::International::get(53);
|
||||
}
|
||||
$temp .= '</a>';
|
||||
return $temp;
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output, $temp);
|
||||
$output = $_[0];
|
||||
$output =~ s/\^r\((.*?)\)\;/_replacement($1)/ge;
|
||||
$output =~ s/\^r\;/_replacement()/ge;
|
||||
#---everything below this line will go away in a later rev.
|
||||
if ($output =~ /\^r(.*)\^\/r/) {
|
||||
$temp = appendToUrl($session{env}{REQUEST_URI},'makePrintable=1');
|
||||
|
|
|
|||
|
|
@ -17,29 +17,34 @@ use WebGUI::Session;
|
|||
use WebGUI::SQL;
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output, $temp, @data, $pageTitle, $parentId, $sth, $first);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^s(.*?)\;/) {
|
||||
$pageTitle = $1;
|
||||
$temp = '<span class="horizontalMenu">';
|
||||
$first = 1;
|
||||
($parentId) = WebGUI::SQL->quickArray("select pageId from page where urlizedTitle='$pageTitle'",$session{dbh});
|
||||
$sth = WebGUI::SQL->read("select title,urlizedTitle,pageId from page where parentId='$parentId' order by sequenceNumber",$session{dbh});
|
||||
while (@data = $sth->array) {
|
||||
if (WebGUI::Privilege::canViewPage($data[2])) {
|
||||
if ($first) {
|
||||
$first = 0;
|
||||
} else {
|
||||
$temp .= " · ";
|
||||
}
|
||||
$temp .= '<a class="horizontalMenu" href="'.$session{env}{SCRIPT_NAME}.'/'.$data[1].'">'.$data[0].'</a>';
|
||||
sub _replacement {
|
||||
my ($temp, @data, $pageTitle, $parentId, $sth, $first);
|
||||
$pageTitle = $1;
|
||||
$temp = '<span class="horizontalMenu">';
|
||||
$first = 1;
|
||||
($parentId) = WebGUI::SQL->quickArray("select pageId from page where urlizedTitle='$pageTitle'",$session{dbh});
|
||||
$sth = WebGUI::SQL->read("select title,urlizedTitle,pageId from page where parentId='$parentId' order by sequenceNumber",$session{dbh});
|
||||
while (@data = $sth->array) {
|
||||
if (WebGUI::Privilege::canViewPage($data[2])) {
|
||||
if ($first) {
|
||||
$first = 0;
|
||||
} else {
|
||||
$temp .= " · ";
|
||||
}
|
||||
$temp .= '<a class="horizontalMenu" href="'.$session{env}{SCRIPT_NAME}.'/'.$data[1].'">'.$data[0].'</a>';
|
||||
}
|
||||
$sth->finish;
|
||||
$temp .= '</span>';
|
||||
$output =~ s/\^s(.*?)\;/$temp/;
|
||||
}
|
||||
$sth->finish;
|
||||
$temp .= '</span>';
|
||||
return $temp;
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output,@data, $pageTitle, $parentId, $sth, $first, $temp);
|
||||
$output = $_[0];
|
||||
$output =~ s/\^s\((.*?)\)\;/_replacement($1)/ge;
|
||||
$output =~ s/\^s\;/_replacement()/ge;
|
||||
#---everything below this line will go away in a later rev.
|
||||
if ($output =~ /\^s(.*)\^\/s/) {
|
||||
$pageTitle = $1;
|
||||
|
|
|
|||
|
|
@ -15,28 +15,32 @@ use WebGUI::Privilege;
|
|||
use WebGUI::Session;
|
||||
use WebGUI::SQL;
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub _replacement {
|
||||
my ($temp, @data, $sth, $first);
|
||||
$temp = '<span class="horizontalMenu">';
|
||||
$first = 1;
|
||||
$sth = WebGUI::SQL->read("select title,urlizedTitle,pageId from page where parentId=1 order by sequenceNumber",$session{dbh});
|
||||
while (@data = $sth->array) {
|
||||
if (WebGUI::Privilege::canViewPage($data[2])) {
|
||||
if ($first) {
|
||||
$first = 0;
|
||||
} else {
|
||||
$temp .= " · ";
|
||||
}
|
||||
$temp .= '<a class="horizontalMenu" href="'.$session{env}{SCRIPT_NAME}.'/'.$data[1].'">'.$data[0].'</a>';
|
||||
}
|
||||
}
|
||||
$sth->finish;
|
||||
$temp .= '</span>';
|
||||
return $temp;
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output, $temp, @data, $sth, $first);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^t(.*?)\;/) {
|
||||
$temp = '<span class="horizontalMenu">';
|
||||
$first = 1;
|
||||
$sth = WebGUI::SQL->read("select title,urlizedTitle,pageId from page where parentId=1 order by sequenceNumber",$session{dbh});
|
||||
while (@data = $sth->array) {
|
||||
if (WebGUI::Privilege::canViewPage($data[2])) {
|
||||
if ($first) {
|
||||
$first = 0;
|
||||
} else {
|
||||
$temp .= " · ";
|
||||
}
|
||||
$temp .= '<a class="horizontalMenu" href="'.$session{env}{SCRIPT_NAME}.'/'.$data[1].'">'.$data[0].'</a>';
|
||||
}
|
||||
}
|
||||
$sth->finish;
|
||||
$temp .= '</span>';
|
||||
$output =~ s/\^t(.*?)\;/$temp/;
|
||||
}
|
||||
$output =~ s/\^t\;/_replacement()/ge;
|
||||
#---everything below this line will go away in a later rev.
|
||||
if ($output =~ /\^t/) {
|
||||
$temp = '<span class="horizontalMenu">';
|
||||
|
|
|
|||
|
|
@ -15,11 +15,9 @@ use WebGUI::Session;
|
|||
|
||||
#-------------------------------------------------------------------
|
||||
sub process {
|
||||
my ($output, $temp, @data, $sth, $first);
|
||||
my ($output);
|
||||
$output = $_[0];
|
||||
while ($output =~ /\^u(.*?)\;/) {
|
||||
$output =~ s/\^u(.*?)\;/$session{setting}{companyURL}/;
|
||||
}
|
||||
$output =~ s/\^u\;/$session{setting}{companyURL}/g;
|
||||
#---everything below this line will go away in a later rev.
|
||||
if ($output =~ /\^u/) {
|
||||
$output =~ s/\^u/$session{setting}{companyURL}/g;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue