On Wednesday 15 June 2005 13:14, Brian Roy wrote:
> Since this list has seen a brief resurgence I thought I might bring
> up an old problem that I (and others) have had. I posted this back in
> '04 and didn't find any resolution so I just used a hack with
> underscores. It still annoys me to this day so I was wondering if
> anyone has a fix for it.
>
> Whenever I do something like....
>
> $AGI->set_variable('CALLERIDNAME',"Brian Roy");
>
> the channel variable only gets everything up until the space. I've
> tried different enclosure methods ()'s '''s etc, and no luck.
>
> Maybe someone (Tilghman I see you are on this list) might be willing
> to fix this in the source? I obviously don't have the skills for
> this, but I like to hack around with perl AGI's.
Well, uh, first of all, CALLERIDNAME is a builtin variable that cannot
be set directly. You need to use the v1-0 SetCIDName(Brian Roy)
application or the CVS-HEAD Set(CALLERID(name)=Brian Roy) application.
But beyond that, you need to quote your string, so it can see the whole
thing:
$AGI->set_variable("somevar", "\"Brian Roy\"");
If we can get James' blessing, I could be persuaded to take over
development of the Asterisk-perl modules and get some new releases
done.
--
Tilghman