[ic] split or \$myvar is not parsing or interpolte in a right way
jojospace
info at ebusiness-leidinger.de
Fri Dec 5 19:42:47 UTC 2008
Hi @all,
I try to use the split function in a perl tag. The split function is not
working right. The same as an (global) usertag. But for this case, I've
a workaround. But I found an other case of trouble, how to use a normal
perl codes as an usertag.
A code like
my $recipient = SOAP::Data->name("Recipient", \$mydata);
is not working properly. A "\" in front of "$mydata" make me mad.
The resulting output of the SOAP is therefore broken.
I've no clue, why this both happens! Am I missing something information
for both cases?
I use
OS: FreeBSD Version 8.0
Perl: Version 5.8.8
IC: Version 5.6.0
Any tips, tricks and helps, would be appreciated!
With finest Regards,
Joachim
Sample codes:
----------------------------
<html>
<body>
TEST<br>
[seti splittest]1111\n2222\n3333\n[/seti]
Input: [scratch splittest]<br>
<br>
<br>
The result is fine!!!
<br>
[perl]
my @list = "";
my $result = "";
@list = split("\n", "1111\n2222\n3333\n");
foreach (@list) {
$result = $result. "list1 = " . $_ . "<br>";
}
return $result;
[/perl]
<br>
Bug or features???
<br>
[perl]
my @list = "";
my $result = "";
my $result = "Where is the result?<br>" . $Scratch->{splittest} . "<br>";
@list = split("\n", $Scratch->{splittest});
foreach (@list) {
$result = $result. "list2 = " . $_ . "<br>";
}
return $result;
[/perl]
<br>
<br>
</body>
</html>
----------------------------
Output:
----------------------------
TEST
Input: 1111\n2222\n3333\n
The result is fine!!!
list1 = 1111
list1 = 2222
list1 = 3333
Bug or features???
Where is the result?
1111\n2222\n3333\n
list2 = 1111\n2222\n3333\n
----------------------------
More information about the interchange-users
mailing list