problem of transmiting variabl into another page?

problem of transmiting variabl into another page?

am 02.12.2005 11:30:12 von Mohamed Yusuf

------=_Part_41276_6026953.1133519412417
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

I am transmitting variable from one of my pages and I would like to match
that variable into mysql data. it won't return data.
my code is this.

echo "| |";
if ($j == Z) {
break;
}
} ?>
this code in my index page prints alphabetical letters from A-Z. and I woul
like to transmit that variable into my alpha.php page and select mysql
database what ever the value of $j is, but i have problem I can't figured
out what is wrong. can somebody help me.

------=_Part_41276_6026953.1133519412417--

RE: problem of transmiting variabl into another page?

am 02.12.2005 14:06:00 von Bastien Koert

echo "| ";

} ?>

You need to use the ORD function to get the numerical ascii equivalent of
the letter and the CHR function to go back the other way.

Bastien


>From: Mohamed Yusuf
>To: php-db@lists.php.net
>Subject: [PHP-DB] problem of transmiting variabl into another page?
>Date: Fri, 2 Dec 2005 12:30:12 +0200
>
>I am transmitting variable from one of my pages and I would like to match
>that variable into mysql data. it won't return data.
>my code is this.
>
> > echo "| |";
> if ($j == Z) {
> break;
> }
> } ?>
>this code in my index page prints alphabetical letters from A-Z. and I woul
>like to transmit that variable into my alpha.php page and select mysql
>database what ever the value of $j is, but i have problem I can't figured
>out what is wrong. can somebody help me.

--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Re: problem of transmiting variabl into another page?

am 02.12.2005 14:24:17 von Cal Evans

Using the code below, when you click on the link for A it will go to

alpha.php?artist=A

In alpha.php, you should be able to query $_GET['artist'] to get the
letter clicked on. You could also check $_REQUEST['artist'] for the same
info.

Is that what you needed or are you having other problems?

=C=
|
| Cal Evans
| http://www.calevans.com
|

Mohamed Yusuf wrote:
> I am transmitting variable from one of my pages and I would like to match
> that variable into mysql data. it won't return data.
> my code is this.
>
> > echo "| |";
> if ($j == Z) {
> break;
> }
> } ?>
> this code in my index page prints alphabetical letters from A-Z. and I woul
> like to transmit that variable into my alpha.php page and select mysql
> database what ever the value of $j is, but i have problem I can't figured
> out what is wrong. can somebody help me.
>

--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

RE: problem of transmiting variabl into another page?

am 07.12.2005 18:31:58 von M.Ford

On 02 December 2005 13:06, Bastien Koert wrote:

> > echo "| > href=3D'alpha.php?artist=3D".chr($j)."'>".chr($j)." ";
>=20
> } ?>
>=20
> You need to use the ORD function to get the numerical ascii
> equivalent of the letter and the CHR function to go back the other
> way.

Gak! That's almost worse than the original!!

>=20
> Bastien
>=20
>=20
> > From: Mohamed Yusuf
> > To: php-db@lists.php.net
> > Subject: [PHP-DB] problem of transmiting variabl into another page?
> > Date: Fri, 2 Dec 2005 12:30:12 +0200
> >=20
> > I am transmitting variable from one of my pages and I would like to
> > match that variable into mysql data. it won't return data.
> > my code is this.
> >=20
> > > > echo "| |";
> > if ($j == Z) {
> > break;
> > }
> > } ?>

1. You have unquoted strings -- should be 'A' and 'Z'.

2. The test condition in your for is wrong (and either that or the break is=
redundant).

Here's how I'd write it:

for ($j=3D'A'; $j!=3D'AA'; $j++):
echo "| |";
endfor;

Cheers!

Mike

------------------------------------------------------------ ---------
Mike Ford, Electronic Information Services Adviser,
Learning Support Services, Learning & Information Services,
JG125, James Graham Building, Leeds Metropolitan University,
Headingley Campus, LEEDS, LS6 3QS, United Kingdom
Email: m.ford@leedsmet.ac.uk
Tel: +44 113 283 2600 extn 4730 Fax: +44 113 283 3211=20



To view the terms under which this email is distributed, please go to http:=
//disclaimer.leedsmet.ac.uk/email.htm

--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php