[Templates] soaplite

Mark Proctor m.proctor@bigfoot.com
Tue, 21 Jan 2003 20:45:05 -0000


I'm having problems using soaplite with template toolkit. I've run the
example code below for illustration purpses. If I remove the code
between the  comments the template processes fine. If  I put the soap
stuff back in, there are no errors, but no output either, the soap call
returns the correct value - I have tried a string as a third parameter,
that also is blank.

Regards

Mark

sub process {
	my ($self) = @_;
	$self->{template}->process($self->{page}, $self->{vars}) || die
"Template process files: ", $self->{template}->error(), "\n";
#----------------------------------------------
      use SOAP::Lite +autodispatch =>
      uri      => 'http://mproctor:xxx@istore-alpha:8083/',
      proxy    =>
'http://mproctor:xxx@istore-alpha:8083/cgi-bin/soap.mod_cgi', # local
CGI server
      on_fault => sub { my($soap, $res) = @_;
                    die ref $res ? "error:" .  $res->faultdetail :
"error:" . $soap->transport->status, "\n";
                  };
      use Mdf::MetaData;
      my $mdf = Mdf::MetaData->SOAP::new();
      $mdf->SOAP::getHandle("istore", {siteName => 'mproctor',
                                              folderId => 1,
                                              pageId   => 2,
                                              itemId   => 3});

      print $mdf->{applicationId};
#----------------------------------------------
}