|
Posted by Robert Cummings on 10/10/05 09:44
On Mon, 2005-10-10 at 02:33, Kristopher Kane wrote:
> I am currently in Afghanistan and don't have much access to look these
> questions up. I consider them basic and regret having to post them here.
> When passing variables using GET as in:
> index.php?first=value?second=value
> My script is reading the first value, however through an included file and
> another function, it can't read the second. What scope do these variables
> have? Or what other reasons for not being able to read the variables might
> there be?
Register globals is set to OFF, which is good unless your script
previously relied on it being set to ON. To access the values use the
super global $_GET:
$first = isset( $_GET['first'] ) ? $_GET['first'] : '';
$second = isset( $_GET['second'] ) ? $_GET['second'] : '';
> Second:
> When dynamcially creating an image:
> I am drawing an image based on data retreived from a mySQL resource.
> However, my DB code is in the same file as the php image file and I get the
> non-descriptive error of "Error in the image 'url'" Are you allowed to do
> any other functions inside an image header other than image functions?
> (Functions being; open a connection to mySQL and do queries)
Is the error a PHP error or a browser error? You can do any PHP code you
want in an image generating page.
Cheers,
Rob.
--
..------------------------------------------------------------.
| InterJinn Application Framework - http://www.interjinn.com |
:------------------------------------------------------------:
| An application and templating framework for PHP. Boasting |
| a powerful, scalable system for accessing system services |
| such as forms, properties, sessions, and caches. InterJinn |
| also provides an extremely flexible architecture for |
| creating re-usable components quickly and easily. |
`------------------------------------------------------------'
Navigation:
[Reply to this message]
|