|
Posted by billb on 05/27/07 14:15
On 25 May, 16:11, Toby A Inkster <usenet200...@tobyinkster.co.uk>
wrote:
> billb wrote:
> > // in perl this would take these 2 variables and put them in the '?'
> > of the sql bit
> > $perl->eval('$sth->bind_param(1, $easting)');
> > $perl->eval('$sth->bind_param(2, $northing)');
>
> Brute force: before the part above, add:
>
> $perl->eval("\$easting = '$easting'");
> $perl->eval("\$northing = '$northing'");
>
> This will create two Perl variables called $easting and $northing and
> assign to them the values of the PHP variables of the same name.
>
> However, I'm sure your Perl extension offers a saner way of passing
> variables between the languages. Read the documentation thoroughly.
>
> --
> Toby A Inkster BSc (Hons) ARCS
> [Geek of HTML/SQL/Perl/PHP/Python/Apache/Linux]
> [OS: Linux 2.6.12-12mdksmp, up 90 days, 22:53.]
>
> Non-Intuitive Surnames
> http://tobyinkster.co.uk/blog/2007/05/25/non-intuitive-surnames/
OK, thanks. The brute force way works. Didn't consider using \$ (ie
the backslash).
I'm not sure if the documentation gives me a better way see :
http://devzone.zend.com/node/view/id/1712
will investigate the fopen() as suggested as well. may get back to you
on this.
[Back to original message]
|