forward port of placeholder parameter fix
This commit is contained in:
parent
23f32fd1e9
commit
7c8fde9aa6
3 changed files with 9 additions and 4 deletions
|
|
@ -31,6 +31,7 @@
|
|||
- fix: WebGUI::Text::splitCsv no longer removes trailing empty fields
|
||||
- fix: Product add-to-group would always try to add a user to a group
|
||||
- Made many minor changes recommended by Perl::Critic.
|
||||
- fix: No Integers or Strings as Placeholder Parameters
|
||||
- Made many minor code efficiency changes.
|
||||
- fix: Two cookies and incorrect Last-Modified date in HTTP header
|
||||
- WebGUI::Text no longer spits out a billion warnings
|
||||
|
|
|
|||
|
|
@ -515,8 +515,9 @@ sub _parsePlaceholderParams {
|
|||
my $params = shift;
|
||||
my @placeholderParams;
|
||||
foreach my $row (split(/\n/,$params)) {
|
||||
chop($row) if ($row =~ m/\s+$/);
|
||||
next if ($row =~ /^\s*$/);
|
||||
$row =~ s/^\s+//;
|
||||
$row =~ s/\s+$//;
|
||||
next if ($row eq '');
|
||||
my ($type,$field) = split(/:/,$row);
|
||||
my $param;
|
||||
if($type =~ /^form/) {
|
||||
|
|
@ -524,6 +525,9 @@ sub _parsePlaceholderParams {
|
|||
} elsif ($type =~ /^query(\d)/) {
|
||||
$param = $self->{_query}{$1}{rowData}{$field};
|
||||
}
|
||||
else {
|
||||
$param = $row;
|
||||
}
|
||||
WebGUI::Macro::process($self->session,\$param);
|
||||
push(@placeholderParams, $param);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -56,9 +56,9 @@ Placeholder Parameters: query1:pageId<br />form:field1</p>
|
|||
</div>
|
||||
<p>In this example the first question mark will contain the field value of pageId in query1,
|
||||
while the second question mark will contain the form variable "field1".</p>
|
||||
<p>Place one Placeholder Parameter on each line.</p>
|
||||
<p>Place one Placeholder Parameter on each line. Leading and trailing whitespace will be trimmed from each parameter.</p>
|
||||
|,
|
||||
lastUpdated => 1146785541,
|
||||
lastUpdated => 1162613239,
|
||||
},
|
||||
|
||||
'15 description' => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue