[OpenSIPS-Users] a simple perl question

Alex R.S.M alex_rsm at hotmail.com
Wed Nov 12 22:21:22 CET 2008


I've tried it before 

# perl
OpenSIPS::AVP::add(4,$x);

#config file
xlog ("$avp(i:4)");

but I am getting error: 
perl error: Undefined subroutine &OpenSIPS::AVP::add called line 84.  

Also: is there any list with all pseudo-variables in OpenSIPS ?


> Date: Wed, 12 Nov 2008 16:11:57 -0500
> From: abalashov at evaristesys.com
> To: axisml at gmail.com
> CC: users at lists.opensips.org
> Subject: Re: [OpenSIPS-Users] a simple perl question
> 
> Chris wrote:
> > On Wednesday 12 November 2008 1:50:59 pm Robert R wrote:
> >> How can I return a string value from perl function in openSER?
> >>
> >> return $x;   is not working.
> > 
> > Here's the way I'm doing it...from my Perl script code:
> > 
> > if ($routeid) {
> > 	# set AVP variable with the destination route ID to route call to
> >       	OpenSIPS::AVP::add(369,$routeid);
> > }
> > 
> > And then  in the OpenSIPS script opensips.cfg, I can read it:
> > 
> > if ($avp(i:369) == "whatever") {
> > 	......
> > }
> 
> Ditto.  That is the only way I have gotten it to work.
> 
> 
> -- 
> Alex Balashov
> Evariste Systems
> Web    : http://www.evaristesys.com/
> Tel    : (+1) (678) 954-0670
> Direct : (+1) (678) 954-0671
> Mobile : (+1) (706) 338-8599
> 
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users

_________________________________________________________________
Windows Live Hotmail now works up to 70% faster.
http://windowslive.com/Explore/Hotmail?ocid=TXT_TAGLM_WL_hotmail_acq_faster_112008
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.opensips.org/pipermail/users/attachments/20081112/8c51be1a/attachment.htm 


More information about the Users mailing list