PHP "GET" Error?

PHP "GET" Error?

am 25.02.2010 19:32:41 von Alice Wei

--_31e5fa9f-ae7f-4f52-8b64-9e016fb5bf8a_
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable


Hi,

I have done something wrong here=2C because when I have my variables de=
clared in my PHP:

$people_from =3D $_GET['people_from']=3B
$state_colors=3D $_GET['state_colors']=3B

I get this url: http://localhost/generic.php?people_from=3DAdair=2C OK-Al=
falfa=2C OK-Atoka=2C OK-Beaver=2C OK-Beckham=2C OK-Blaine=2C OK-Bryan=2C OK=
-Caddo=2C OK-Canadian=2C OK-Carter=2C OK-Cherokee=2C OK-Choctaw=2C OK-Cimar=
ron=2C OK-Cleveland=2C OK-Coal=2C OK&state_colors=3D#FFFFCC-#FFFFCC-#FFCCCC=
-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FF CCCC-#FFCCCC-#F=
FCCCC-#FFCCCC-#FFCCCC-#FFCCCC

The result? I don't get any colors on the screen as I have here in the url=
..=20
However=2C if I do:
=20
$people_from =3D "Adair=2C OK-Alfalfa=2C OK-Atoka=2C OK-Beaver=2C OK-Beckha=
m=2C OK-Blaine=2C OK-Bryan=2C OK-Caddo=2C OK-Canadian=2C OK-Carter=2C OK-Ch=
erokee=2C OK-Choctaw=2C OK-Cimarron=2C OK-Cleveland=2C OK-Coal=2C OK"=3B
$state_colors=3D "#FFFFCC-#FFFFCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#=
FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCC CC"=3B

I get the correct result. In total=2C there are 77 entries (I only put 15 h=
ere). Is there a length limit for what I pass to the url? If not=2C how com=
e there are no colors showing up in my image as I desired according to my u=
rl?

Thanks for your help.

Alice
=20
____________________________________________________________ _____
Hotmail: Free=2C trusted and rich email service.
http://clk.atdmt.com/GBL/go/201469228/direct/01/=

--_31e5fa9f-ae7f-4f52-8b64-9e016fb5bf8a_--

Re: PHP "GET" Error?

am 25.02.2010 19:45:28 von Ashley Sheridan

--=-6E2i4xUxWp4Mbrwt6rNy
Content-Type: text/plain
Content-Transfer-Encoding: 7bit

On Thu, 2010-02-25 at 13:32 -0500, Alice Wei wrote:

> Hi,
>
> I have done something wrong here, because when I have my variables declared in my PHP:
>
> $people_from = $_GET['people_from'];
> $state_colors= $_GET['state_colors'];
>
> I get this url: http://localhost/generic.php?people_from=Adair, OK-Alfalfa, OK-Atoka, OK-Beaver, OK-Beckham, OK-Blaine, OK-Bryan, OK-Caddo, OK-Canadian, OK-Carter, OK-Cherokee, OK-Choctaw, OK-Cimarron, OK-Cleveland, OK-Coal, OK&state_colors=#FFFFCC-#FFFFCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFC CCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC- #FFCCCC-#FFCCCC-#FFCCCC
>
> The result? I don't get any colors on the screen as I have here in the url.
> However, if I do:
>
> $people_from = "Adair, OK-Alfalfa, OK-Atoka, OK-Beaver, OK-Beckham, OK-Blaine, OK-Bryan, OK-Caddo, OK-Canadian, OK-Carter, OK-Cherokee, OK-Choctaw, OK-Cimarron, OK-Cleveland, OK-Coal, OK";
> $state_colors= "#FFFFCC-#FFFFCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FF CCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC ";
>
> I get the correct result. In total, there are 77 entries (I only put 15 here). Is there a length limit for what I pass to the url? If not, how come there are no colors showing up in my image as I desired according to my url?
>
> Thanks for your help.
>
> Alice
>
> ____________________________________________________________ _____
> Hotmail: Free, trusted and rich email service.
> http://clk.atdmt.com/GBL/go/201469228/direct/01/


OK, a few things wrong with your URL here. URL's cant contain spaces,
they have to be escaped as %20. Also, the # is a special character in a
URL, as it marks an anchor in a page.

Lastly, yes, there is a limit to data sent in a URL. It varies slightly
from browser to browser, but I would try not to go over a couple of
hundred characters.

Thanks,
Ash
http://www.ashleysheridan.co.uk



--=-6E2i4xUxWp4Mbrwt6rNy--

Re: PHP "GET" Error?

am 25.02.2010 19:49:20 von Shawn McKenzie

Alice Wei wrote:
> Hi,
>
> I have done something wrong here, because when I have my variables declared in my PHP:
>
> $people_from = $_GET['people_from'];
> $state_colors= $_GET['state_colors'];
>
> I get this url: http://localhost/generic.php?people_from=Adair, OK-Alfalfa, OK-Atoka, OK-Beaver, OK-Beckham, OK-Blaine, OK-Bryan, OK-Caddo, OK-Canadian, OK-Carter, OK-Cherokee, OK-Choctaw, OK-Cimarron, OK-Cleveland, OK-Coal, OK&state_colors=#FFFFCC-#FFFFCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFC CCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC- #FFCCCC-#FFCCCC-#FFCCCC
>
> The result? I don't get any colors on the screen as I have here in the url.
> However, if I do:
>
> $people_from = "Adair, OK-Alfalfa, OK-Atoka, OK-Beaver, OK-Beckham, OK-Blaine, OK-Bryan, OK-Caddo, OK-Canadian, OK-Carter, OK-Cherokee, OK-Choctaw, OK-Cimarron, OK-Cleveland, OK-Coal, OK";
> $state_colors= "#FFFFCC-#FFFFCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FF CCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC ";
>
> I get the correct result. In total, there are 77 entries (I only put 15 here). Is there a length limit for what I pass to the url? If not, how come there are no colors showing up in my image as I desired according to my url?
>
> Thanks for your help.
>
> Alice
>
> ____________________________________________________________ _____
> Hotmail: Free, trusted and rich email service.
> http://clk.atdmt.com/GBL/go/201469228/direct/01/

There are characters in the URL that have a meaning within a URL itself
(such as #). Use urlencode() before putting the data in the URL.

--
Thanks!
-Shawn
http://www.spidean.com

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

Re: PHP "GET" Error?

am 25.02.2010 20:03:57 von Shawn McKenzie

Shawn McKenzie wrote:
> Alice Wei wrote:
>> Hi,
>>
>> I have done something wrong here, because when I have my variables declared in my PHP:
>>
>> $people_from = $_GET['people_from'];
>> $state_colors= $_GET['state_colors'];
>>
>> I get this url: http://localhost/generic.php?people_from=Adair, OK-Alfalfa, OK-Atoka, OK-Beaver, OK-Beckham, OK-Blaine, OK-Bryan, OK-Caddo, OK-Canadian, OK-Carter, OK-Cherokee, OK-Choctaw, OK-Cimarron, OK-Cleveland, OK-Coal, OK&state_colors=#FFFFCC-#FFFFCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFC CCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC- #FFCCCC-#FFCCCC-#FFCCCC
>>
>> The result? I don't get any colors on the screen as I have here in the url.
>> However, if I do:
>>
>> $people_from = "Adair, OK-Alfalfa, OK-Atoka, OK-Beaver, OK-Beckham, OK-Blaine, OK-Bryan, OK-Caddo, OK-Canadian, OK-Carter, OK-Cherokee, OK-Choctaw, OK-Cimarron, OK-Cleveland, OK-Coal, OK";
>> $state_colors= "#FFFFCC-#FFFFCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FF CCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC ";
>>
>> I get the correct result. In total, there are 77 entries (I only put 15 here). Is there a length limit for what I pass to the url? If not, how come there are no colors showing up in my image as I desired according to my url?
>>
>> Thanks for your help.
>>
>> Alice
>>
>> ____________________________________________________________ _____
>> Hotmail: Free, trusted and rich email service.
>> http://clk.atdmt.com/GBL/go/201469228/direct/01/
>
> There are characters in the URL that have a meaning within a URL itself
> (such as #). Use urlencode() before putting the data in the URL.
>

FWIW, how I would probably handle this is to have an array of
$people_from and an array of $state_colors and then serialize() them and
run through urlencode(). Then you have an array on the next page. Much
easier to work with:

$people_from = array('K-Alfalfa', 'OK-Atoka'); //etc...
$state_colors = array('#FFFFCC', '#FFFFCC'); //etc...

Then the link would be:

$url =
'generic.php?people_from='.urlencode(serialize($people_from) ).'&state_colors'.urlencode(serialize($state_colors));

You then have a $_GET['people_from'] and $_GET['state_colors'] array on
the next page.

--
Thanks!
-Shawn
http://www.spidean.com

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

RE: PHP "GET" Error?

am 25.02.2010 20:25:04 von Alice Wei

--_87a3501a-ee76-4ea2-8eb2-5784d44f1d93_
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable


Hi,

I forgot to mention that the url is formed from Actionscript=2C I am just=
using PHP to do the "I/O" because Actionscript does not have this option.=
=20

So=2C I guess I cannot do the serialize here like you suggested. I have c=
hanged # to 0x for now=2C and that does not seem to help yet.=20
BTW=2C below is the complete code=2C would this help with my choices?


header("Content-type: image/svg+xml")=3B //Outputting an SVG=20

$from =3D $_GET['from']=3B
$state_colors=3D $_GET['state_colors']=3B

$from =3D explode("-"=2C $from)=3B
$state_colors=3D explode("-"=2C $state_colors)=3B

#Load the Map
$ourFileName=3D "USA_Counties_with_FIPS_and_names.svg"=3B
$fh =3D fopen($ourFileName=2C "r") or die("Can't open file")=3B
$contents =3D fread($fh=2Cfilesize($ourFileName))=3B
$lines2=3D file($ourFileName)=3B

foreach ($lines2 as $line_num =3D> $line2) {=20

$style_line_num =3D $line_num+3=3B
$line2 =3D trim($line2)=3B

if(preg_match("/^style/"=2C$line2)) {

$rest =3D substr($line2=2C0=2C-1)=3B =20

for ($j=3D$line_num=3B$j<=3D$style_line_num=3B$j++){
if(preg_match("/inkscape:label/"=2C$lines2[$j])) { =20
$location =3D explode("=3D"=2C$lines2[$j])=3B
$location2 =3D substr($location[1]=2C1=2C-6)=3B =20
=20
if(in_array($patient_location2=2C $patient_from)) {
=20
$key=3D array_search($location2=2C$from)=3B //Find out the pos=
ition of the index in the array
$colors_style =3D "=3Bfill:" . $state_colors[$key]=3B //Use t=
he index from array_search to apply to the color index
$rest2 =3D substr($line2=2C0=2C-1). $colors_style . "\""=3B =
=20
echo $rest2 . "\n"=3B
}
else echo $line2 . "\n"=3B =20

} //end preg_match inkscape =20
} //end for loop
} //If preg_match style

else echo $line2 . "\n"=3B //else if preg_match style =20
} //end for each =20

fclose($fh)=3B
?>

Thanks for your help.=20

Alice

> Date: Thu=2C 25 Feb 2010 13:03:57 -0600
> From: nospam@mckenzies.net
> CC: ajwei@alumni.iu.edu=3B php-general@lists.php.net
> Subject: Re: PHP "GET" Error?
>=20
> Shawn McKenzie wrote:
> > Alice Wei wrote:
> >> Hi,
> >>
> >> I have done something wrong here=2C because when I have my variabl=
es declared in my PHP:
> >>
> >> $people_from =3D $_GET['people_from']=3B
> >> $state_colors=3D $_GET['state_colors']=3B
> >>
> >> I get this url: http://localhost/generic.php?people_from=3DAdair=2C =
OK-Alfalfa=2C OK-Atoka=2C OK-Beaver=2C OK-Beckham=2C OK-Blaine=2C OK-Bryan=
=2C OK-Caddo=2C OK-Canadian=2C OK-Carter=2C OK-Cherokee=2C OK-Choctaw=2C OK=
-Cimarron=2C OK-Cleveland=2C OK-Coal=2C OK&state_colors=3D#FFFFCC-#FFFFCC-#=
FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCC CC-#FFCCCC-#FFC=
CCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC
> >>
> >> The result? I don't get any colors on the screen as I have here in th=
e url.=20
> >> However=2C if I do:
> >> =20
> >> $people_from =3D "Adair=2C OK-Alfalfa=2C OK-Atoka=2C OK-Beaver=2C OK-B=
eckham=2C OK-Blaine=2C OK-Bryan=2C OK-Caddo=2C OK-Canadian=2C OK-Carter=2C =
OK-Cherokee=2C OK-Choctaw=2C OK-Cimarron=2C OK-Cleveland=2C OK-Coal=2C OK"=
=3B
> >> $state_colors=3D "#FFFFCC-#FFFFCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFC=
CCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC- #FFCCCC"=3B
> >>
> >> I get the correct result. In total=2C there are 77 entries (I only put=
15 here). Is there a length limit for what I pass to the url? If not=2C ho=
w come there are no colors showing up in my image as I desired according to=
my url?
> >>
> >> Thanks for your help.
> >>
> >> Alice
> >> =20
> >> ____________________________________________________________ _____
> >> Hotmail: Free=2C trusted and rich email service.
> >> http://clk.atdmt.com/GBL/go/201469228/direct/01/
> >=20
> > There are characters in the URL that have a meaning within a URL itself
> > (such as #). Use urlencode() before putting the data in the URL.
> >=20
>=20
> FWIW=2C how I would probably handle this is to have an array of
> $people_from and an array of $state_colors and then serialize() them and
> run through urlencode(). Then you have an array on the next page. Much
> easier to work with:
>=20
> $people_from =3D array('K-Alfalfa'=2C 'OK-Atoka')=3B //etc...
> $state_colors =3D array('#FFFFCC'=2C '#FFFFCC')=3B //etc...
>=20
> Then the link would be:
>=20
> $url =3D
> 'generic.php?people_from=3D'.urlencode(serialize($people_fro m)).'&state_c=
olors'.urlencode(serialize($state_colors))=3B
>=20
> You then have a $_GET['people_from'] and $_GET['state_colors'] array on
> the next page.
>=20
> --=20
> Thanks!
> -Shawn
> http://www.spidean.com
=20
____________________________________________________________ _____
Hotmail: Powerful Free email with security by Microsoft.
http://clk.atdmt.com/GBL/go/201469230/direct/01/=

--_87a3501a-ee76-4ea2-8eb2-5784d44f1d93_--

RE: PHP "GET" Error?

am 25.02.2010 20:28:44 von Alice Wei

--_8c4af6af-4d81-4816-9819-39bb2ea927f9_
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable



> Date: Thu=2C 25 Feb 2010 13:03:57 -0600
> From: nospam@mckenzies.net
> CC: ajwei@alumni.iu.edu=3B php-general@lists.php.net
> Subject: Re: PHP "GET" Error?
>=20
> Shawn McKenzie wrote:
> > Alice Wei wrote:
> >> Hi,
> >>
> >> I have done something wrong here=2C because when I have my variabl=
es declared in my PHP:
> >>
> >> $people_from =3D $_GET['people_from']=3B
> >> $state_colors=3D $_GET['state_colors']=3B
> >>
> >> I get this url: http://localhost/generic.php?people_from=3DAdair=2C =
OK-Alfalfa=2C OK-Atoka=2C OK-Beaver=2C OK-Beckham=2C OK-Blaine=2C OK-Bryan=
=2C OK-Caddo=2C OK-Canadian=2C OK-Carter=2C OK-Cherokee=2C OK-Choctaw=2C OK=
-Cimarron=2C OK-Cleveland=2C OK-Coal=2C OK&state_colors=3D#FFFFCC-#FFFFCC-#=
FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCC CC-#FFCCCC-#FFC=
CCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC
> >>
> >> The result? I don't get any colors on the screen as I have here in th=
e url.=20
> >> However=2C if I do:
> >> =20
> >> $people_from =3D "Adair=2C OK-Alfalfa=2C OK-Atoka=2C OK-Beaver=2C OK-B=
eckham=2C OK-Blaine=2C OK-Bryan=2C OK-Caddo=2C OK-Canadian=2C OK-Carter=2C =
OK-Cherokee=2C OK-Choctaw=2C OK-Cimarron=2C OK-Cleveland=2C OK-Coal=2C OK"=
=3B
> >> $state_colors=3D "#FFFFCC-#FFFFCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFC=
CCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC-#FFCCCC- #FFCCCC"=3B
> >>
> >> I get the correct result. In total=2C there are 77 entries (I only put=
15 here). Is there a length limit for what I pass to the url? If not=2C ho=
w come there are no colors showing up in my image as I desired according to=
my url?
> >>
> >> Thanks for your help.
> >>
> >> Alice
> >> =20
> >> ____________________________________________________________ _____
> >> Hotmail: Free=2C trusted and rich email service.
> >> http://clk.atdmt.com/GBL/go/201469228/direct/01/
> >=20
> > There are characters in the URL that have a meaning within a URL itself
> > (such as #). Use urlencode() before putting the data in the URL.
> >=20
>=20
> FWIW=2C how I would probably handle this is to have an array of
> $people_from and an array of $state_colors and then serialize() them and
> run through urlencode(). Then you have an array on the next page. Much
> easier to work with:
>=20
> $people_from =3D array('K-Alfalfa'=2C 'OK-Atoka')=3B //etc...
> $state_colors =3D array('#FFFFCC'=2C '#FFFFCC')=3B //etc...
>=20
> Then the link would be:
>=20
> $url =3D
> 'generic.php?people_from=3D'.urlencode(serialize($people_fro m)).'&state_c=
olors'.urlencode(serialize($state_colors))=3B
>=20
> You then have a $_GET['people_from'] and $_GET['state_colors'] array on
> the next page.

On another note=2C would this be different if I used POST instead of GET?=
(considering there are some limitation on the length of my url) I tried to=
look into that=2C but I don't see anything.=20

Alice

> --=20
> Thanks!
> -Shawn
> http://www.spidean.com
=20
____________________________________________________________ _____
Hotmail: Powerful Free email with security by Microsoft.
http://clk.atdmt.com/GBL/go/201469230/direct/01/=

--_8c4af6af-4d81-4816-9819-39bb2ea927f9_--

Re: PHP "GET" Error?

am 25.02.2010 20:50:16 von Shawn McKenzie

Alice Wei wrote:
> Hi,
>
> I forgot to mention that the url is formed from Actionscript, I am just using PHP to do the "I/O" because Actionscript does not have this option.
>
> So, I guess I cannot do the serialize here like you suggested. I have changed # to 0x for now, and that does not seem to help yet.
> BTW, below is the complete code, would this help with my choices?
>

I haven't used actionscript, but it's javascript basically yes?

Use encodeURI() or encodeURIComponent() on the data.


--
Thanks!
-Shawn
http://www.spidean.com

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

RE: PHP "GET" Error?

am 25.02.2010 21:01:09 von Alice Wei

--_52870067-8bc7-432c-b0b3-97235f7d46a1_
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable



> Date: Thu=2C 25 Feb 2010 13:50:16 -0600
> From: nospam@mckenzies.net
> To: ajwei@alumni.iu.edu
> CC: php-general@lists.php.net
> Subject: Re: PHP "GET" Error?
>=20
> Alice Wei wrote:
> > Hi,
> >=20
> > I forgot to mention that the url is formed from Actionscript=2C I am =
just using PHP to do the "I/O" because Actionscript does not have this opti=
on.=20
> >=20
> > So=2C I guess I cannot do the serialize here like you suggested. I ha=
ve changed # to 0x for now=2C and that does not seem to help yet.=20
> > BTW=2C below is the complete code=2C would this help with my choices?
> >=20
>=20
> I haven't used actionscript=2C but it's javascript basically yes?
>=20
> Use encodeURI() or encodeURIComponent() on the data.
>=20
>=20
Yes=2C and no. But=2C I did find the function in the Actionscript librar=
y=2C and I used the new url to pass through to PHP. Looks like it still did=
n't work=2C could the length be an issue?=20

BTW=2C these two variables start off from Actionscript as "arrays"=2C bu=
t would knowing this here help? It would be nice that I can just pass them =
on as arrays (I had to "turn them into strings" before I passed to PHP).=20

Thanks for your help.=20

Alice

> --=20
> Thanks!
> -Shawn
> http://www.spidean.com
=20
____________________________________________________________ _____
Your E-mail and More On-the-Go. Get Windows Live Hotmail Free.
http://clk.atdmt.com/GBL/go/201469229/direct/01/=

--_52870067-8bc7-432c-b0b3-97235f7d46a1_--

Re: RE: PHP "GET" Error?

am 25.02.2010 21:03:28 von Ashley Sheridan

--=-v6MmeZFM1VaYYt4IfOpv
Content-Type: text/plain
Content-Transfer-Encoding: 7bit

On Thu, 2010-02-25 at 15:01 -0500, Alice Wei wrote:

>
> > Date: Thu, 25 Feb 2010 13:50:16 -0600
> > From: nospam@mckenzies.net
> > To: ajwei@alumni.iu.edu
> > CC: php-general@lists.php.net
> > Subject: Re: PHP "GET" Error?
> >
> > Alice Wei wrote:
> > > Hi,
> > >
> > > I forgot to mention that the url is formed from Actionscript, I am just using PHP to do the "I/O" because Actionscript does not have this option.
> > >
> > > So, I guess I cannot do the serialize here like you suggested. I have changed # to 0x for now, and that does not seem to help yet.
> > > BTW, below is the complete code, would this help with my choices?
> > >
> >
> > I haven't used actionscript, but it's javascript basically yes?
> >
> > Use encodeURI() or encodeURIComponent() on the data.
> >
> >
> Yes, and no. But, I did find the function in the Actionscript library, and I used the new url to pass through to PHP. Looks like it still didn't work, could the length be an issue?
>
> BTW, these two variables start off from Actionscript as "arrays", but would knowing this here help? It would be nice that I can just pass them on as arrays (I had to "turn them into strings" before I passed to PHP).
>
> Thanks for your help.
>
> Alice
>
> > --
> > Thanks!
> > -Shawn
> > http://www.spidean.com
>
> ____________________________________________________________ _____
> Your E-mail and More On-the-Go. Get Windows Live Hotmail Free.
> http://clk.atdmt.com/GBL/go/201469229/direct/01/


Have you tried outputting the URL string to see if it's properly formed?
AS3 can still trace() can't it?

This link should give you an idea of the string limits of different
browsers and servers:

http://www.boutell.com/newfaq/misc/urllength.html

Thanks,
Ash
http://www.ashleysheridan.co.uk



--=-v6MmeZFM1VaYYt4IfOpv--

RE: RE: PHP "GET" Error?

am 25.02.2010 21:11:52 von Alice Wei

--_37c7ab3b-ce0d-4363-aecc-5715a5ddf7cd_
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable


Subject: Re: [PHP] RE: PHP "GET" Error?
From: ash@ashleysheridan.co.uk
To: ajwei@alumni.iu.edu
CC: nospam@mckenzies.net=3B php-general@lists.php.net
Date: Thu=2C 25 Feb 2010 20:03:28 +0000






=20
=20


On Thu=2C 2010-02-25 at 15:01 -0500=2C Alice Wei wrote:


> Date: Thu=2C 25 Feb 2010 13:50:16 -0600
> From: nospam@mckenzies.net
> To: ajwei@alumni.iu.edu
> CC: php-general@lists.php.net
> Subject: Re: PHP "GET" Error?
>=20
> Alice Wei wrote:
> > Hi,
> >=20
> > I forgot to mention that the url is formed from Actionscript=2C I am =
just using PHP to do the "I/O" because Actionscript does not have this opti=
on.=20
> >=20
> > So=2C I guess I cannot do the serialize here like you suggested. I ha=
ve changed # to 0x for now=2C and that does not seem to help yet.=20
> > BTW=2C below is the complete code=2C would this help with my choices?
> >=20
>=20
> I haven't used actionscript=2C but it's javascript basically yes?
>=20
> Use encodeURI() or encodeURIComponent() on the data.
>=20
>=20
Yes=2C and no. But=2C I did find the function in the Actionscript librar=
y=2C and I used the new url to pass through to PHP. Looks like it still did=
n't work=2C could the length be an issue?=20

BTW=2C these two variables start off from Actionscript as "arrays"=2C bu=
t would knowing this here help? It would be nice that I can just pass them =
on as arrays (I had to "turn them into strings" before I passed to PHP).=20

Thanks for your help.=20

Alice

> --=20
> Thanks!
> -Shawn
> http://www.spidean.com
=20
____________________________________________________________ _____
Your E-mail and More On-the-Go. Get Windows Live Hotmail Free.
http://clk.atdmt.com/GBL/go/201469229/direct/01/




Have you tried outputting the URL string to see if it's properly formed? AS=
3 can still trace() can't it?



This link should give you an idea of the string limits of different browser=
s and servers:



http://www.boutell.com/newfaq/misc/urllength.html

I have just done that=2C and here is the pathetically long url:

http://tdc-queuing/test/generic.php?from=3DAdair=2C%20OK-Alf alfa=2C%20OK-At=
oka=2C%20OK-Beaver=2C%20OK-Beckham=2C%20OK-Blaine=2C%20OK-Br yan=2C%20OK-Cad=
do=2C%20OK-Canadian=2C%20OK-Carter=2C%20OK-Cherokee=2C%20OK- Choctaw=2C%20OK=
-Cimarron=2C%20OK-Cleveland=2C%20OK-Coal=2C%20OK-Comanche=2C %20OK-Cotton=2C=
%20OK-Craig=2C%20OK-Creek=2C%20OK-Custer=2C%20OK-Delaware=2C %20OK-Dewey=2C%=
20OK-Ellis=2C%20OK-Garfield=2C%20OK-Garvin=2C%20OK-Grady=2C% 20OK-Grant=2C%2=
0OK-Greer=2C%20OK-Harmon=2C%20OK-Harper=2C%20OK-Haskell=2C%2 0OK-Hughes=2C%2=
0OK-Jackson=2C%20OK-Jefferson=2C%20OK-Johnston=2C%20OK-Kay=2 C%20OK-Kingfish=
er=2C%20OK-Kiowa=2C%20OK-Latimer=2C%20OK-Le%20Flore=2C%20OK- Lincoln=2C%20OK=
-Logan=2C%20OK-Love=2C%20OK-Major=2C%20OK-Marshall=2C%20OK-M ayes=2C%20OK-Mc=
Clain=2C%20OK-McCurtain=2C%20OK-McIntosh=2C%20OK-Murray=2C%2 0OK-Muskogee=2C=
%20OK-Noble=2C%20OK-Nowata=2C%20OK-Okfuskee=2C%20OK-Oklahoma =2C%20OK-Okmulg=
ee=2C%20OK-Osage=2C%20OK-Ottawa=2C%20OK-Pawnee=2C%20OK-Payne =2C%20OK-Pittsb=
urg=2C%20OK-Pontotoc=2C%20OK-Pottawatomie=2C%20OK-Pushmataha =2C%20OK-Roger%=
20Mills=2C%20OK-Rogers=2C%20OK-Seminole=2C%20OK-Sequoyah=2C% 20OK-Stephens=
=2C%20OK-Texas=2C%20OK-Tillman=2C%20OK-Tulsa=2C%20OK-Wagoner =2C%20OK-Washin=
gton=2C%20OK-Washita=2C%20OK-Woods=2C%20OK-Woodward=2C%20OK& state_colors=3D=
0xFFFFCC-0xFFFFCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFFCC CC-0xFFCCCC-0xF=
FCCCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFFCCCC- 0xFFCCCC-0xFF99=
99-0xFF9999-0xFF9999-0xFF9999-0xFF9999-0xFF9999-0xFF9999-0xF F9999-0xFF9999-=
0xFF9999-0xFF9999-0xFF9999-0xFF9999-0xFF9999-0xFF9999-0x0DCC FF-0x0DCCFF-0x0=
DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF- 0x0DCCFF-0x0DCC=
FF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x3333FF-0x3333FF-0x3 333FF-0x3333FF-=
0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333 FF-0x3333FF-0x3=
333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF- 0x3333FF-0x3333=
FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3 333FF-0x3333FF-=
0x3333FF-0x3333FF

This is generated from the encodeURI() Shawn was talking about. Does this s=
eem "well-formed" to you?

Thanks.

Alice




=20
____________________________________________________________ _____
Hotmail: Trusted email with powerful SPAM protection.
http://clk.atdmt.com/GBL/go/201469227/direct/01/=

--_37c7ab3b-ce0d-4363-aecc-5715a5ddf7cd_--

RE: RE: PHP "GET" Error?

am 25.02.2010 21:14:55 von Ashley Sheridan

--=-hEiGLw8VQFg0jsMJdWMy
Content-Type: text/plain
Content-Transfer-Encoding: quoted-printable

On Thu, 2010-02-25 at 15:11 -0500, Alice Wei wrote:

> Subject: Re: [PHP] RE: PHP "GET" Error?
> From: ash@ashleysheridan.co.uk
> To: ajwei@alumni.iu.edu
> CC: nospam@mckenzies.net; php-general@lists.php.net
> Date: Thu, 25 Feb 2010 20:03:28 +0000
>=20
>=20
>=20
>=20
>=20
>=20
> =20
> =20
>=20
>=20
> On Thu, 2010-02-25 at 15:01 -0500, Alice Wei wrote:
>=20
>=20
> > Date: Thu, 25 Feb 2010 13:50:16 -0600
> > From: nospam@mckenzies.net
> > To: ajwei@alumni.iu.edu
> > CC: php-general@lists.php.net
> > Subject: Re: PHP "GET" Error?
> >=20
> > Alice Wei wrote:
> > > Hi,=20
> > >=20
> > > I forgot to mention that the url is formed from Actionscript, I am =
just using PHP to do the "I/O" because Actionscript does not have this opti=
on.=20
> > >=20
> > > So, I guess I cannot do the serialize here like you suggested. I ha=
ve changed # to 0x for now, and that does not seem to help yet.=20
> > > BTW, below is the complete code, would this help with my choices?
> > >=20
> >=20
> > I haven't used actionscript, but it's javascript basically yes?
> >=20
> > Use encodeURI() or encodeURIComponent() on the data.
> >=20
> >=20
> Yes, and no. But, I did find the function in the Actionscript library,=
and I used the new url to pass through to PHP. Looks like it still didn't =
work, could the length be an issue?=20
>=20
> BTW, these two variables start off from Actionscript as "arrays", but =
would knowing this here help? It would be nice that I can just pass them on=
as arrays (I had to "turn them into strings" before I passed to PHP).=20
>=20
> Thanks for your help.=20
>=20
> Alice
>=20
> > --=20
> > Thanks!
> > -Shawn
> > http://www.spidean.com
> =20
> ____________________________________________________________ _____
> Your E-mail and More On-the-Go. Get Windows Live Hotmail Free.
> http://clk.atdmt.com/GBL/go/201469229/direct/01/
>=20
>=20
>=20
>=20
> Have you tried outputting the URL string to see if it's properly formed? =
AS3 can still trace() can't it?
>=20
>=20
>=20
> This link should give you an idea of the string limits of different brows=
ers and servers:
>=20
>=20
>=20
> http://www.boutell.com/newfaq/misc/urllength.html
>=20
> I have just done that, and here is the pathetically long url:
>=20
> http://tdc-queuing/test/generic.php?from=3DAdair,%20OK-Alfal fa,%20OK-Atok=
a,%20OK-Beaver,%20OK-Beckham,%20OK-Blaine,%20OK-Bryan,%20OK- Caddo,%20OK-Can=
adian,%20OK-Carter,%20OK-Cherokee,%20OK-Choctaw,%20OK-Cimarr on,%20OK-Clevel=
and,%20OK-Coal,%20OK-Comanche,%20OK-Cotton,%20OK-Craig,%20OK -Creek,%20OK-Cu=
ster,%20OK-Delaware,%20OK-Dewey,%20OK-Ellis,%20OK-Garfield,% 20OK-Garvin,%20=
OK-Grady,%20OK-Grant,%20OK-Greer,%20OK-Harmon,%20OK-Harper,% 20OK-Haskell,%2=
0OK-Hughes,%20OK-Jackson,%20OK-Jefferson,%20OK-Johnston,%20O K-Kay,%20OK-Kin=
gfisher,%20OK-Kiowa,%20OK-Latimer,%20OK-Le%20Flore,%20OK-Lin coln,%20OK-Loga=
n,%20OK-Love,%20OK-Major,%20OK-Marshall,%20OK-Mayes,%20OK-Mc Clain,%20OK-McC=
urtain,%20OK-McIntosh,%20OK-Murray,%20OK-Muskogee,%20OK-Nobl e,%20OK-Nowata,=
%20OK-Okfuskee,%20OK-Oklahoma,%20OK-Okmulgee,%20OK-Osage,%20 OK-Ottawa,%20OK=
-Pawnee,%20OK-Payne,%20OK-Pittsburg,%20OK-Pontotoc,%20OK-Pot tawatomie,%20OK=
-Pushmataha,%20OK-Roger%20Mills,%20OK-Rogers,%20OK-Seminole, %20OK-Sequoyah,=
%20OK-Stephens,%20OK-Texas,%20OK-Tillman,%20OK-Tulsa,%20OK-W agoner,%20OK-Wa=
shington,%20OK-Washita,%20OK-Woods,%20OK-Woodward,%20OK&stat e_colors=3D0xFF=
FFCC-0xFFFFCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0 xFFCCCC-0xFFCCC=
C-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFF CCCC-0xFF9999-0=
xFF9999-0xFF9999-0xFF9999-0xFF9999-0xFF9999-0xFF9999-0xFF999 9-0xFF9999-0xFF=
9999-0xFF9999-0xFF9999-0xFF9999-0xFF9999-0xFF9999-0x0DCCFF-0 x0DCCFF-0x0DCCF=
F-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x0D CCFF-0x0DCCFF-0=
x0DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x3333FF-0x3333FF-0x3333F F-0x3333FF-0x33=
33FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0 x3333FF-0x3333F=
F-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x33 33FF-0x3333FF-0=
x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333F F-0x3333FF-0x33=
33FF-0x3333FF
>=20
> This is generated from the encodeURI() Shawn was talking about. Does this=
seem "well-formed" to you?
>=20
> Thanks.
>=20
> Alice
>=20
>=20
>=20
>=20
> =20
> ____________________________________________________________ _____
> Hotmail: Trusted email with powerful SPAM protection.
> http://clk.atdmt.com/GBL/go/201469227/direct/01/


I can't see anything obviously wrong with the URL really. Is there no
way instead to send the data as post data from Flash? I know Flash can
make post requests, but I'm not sure how much more difficult it is.

Thanks,
Ash
http://www.ashleysheridan.co.uk



--=-hEiGLw8VQFg0jsMJdWMy--

Re: PHP "GET" Error?

am 25.02.2010 21:16:16 von Shawn McKenzie

Alice Wei wrote:
>
>> Date: Thu, 25 Feb 2010 13:50:16 -0600
>> From: nospam@mckenzies.net
>> To: ajwei@alumni.iu.edu
>> CC: php-general@lists.php.net
>> Subject: Re: PHP "GET" Error?
>>
>> Alice Wei wrote:
>>> Hi,
>>>
>>> I forgot to mention that the url is formed from Actionscript, I am just using PHP to do the "I/O" because Actionscript does not have this option.
>>>
>>> So, I guess I cannot do the serialize here like you suggested. I have changed # to 0x for now, and that does not seem to help yet.
>>> BTW, below is the complete code, would this help with my choices?
>>>
>> I haven't used actionscript, but it's javascript basically yes?
>>
>> Use encodeURI() or encodeURIComponent() on the data.
>>
>>
> Yes, and no. But, I did find the function in the Actionscript library, and I used the new url to pass through to PHP. Looks like it still didn't work, could the length be an issue?
>
> BTW, these two variables start off from Actionscript as "arrays", but would knowing this here help? It would be nice that I can just pass them on as arrays (I had to "turn them into strings" before I passed to PHP).
>
> Thanks for your help.

Those functions will work if you do it properly. As for arrays, the
only way I know of in js is to json encode them and then you can use the
PHP json_decode() to get them back. There is no native js function to
do this, however there may be one in the actionscript library or there
are some functions on the web that people have written.

Wait, I found this: http://code.google.com/p/as3corelib/

Functionality may already be in As, but may be of use.


--
Thanks!
-Shawn
http://www.spidean.com

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

RE: PHP "GET" Error?

am 25.02.2010 21:19:49 von Alice Wei

--_7e4cc2be-f119-4c72-83d1-ea12576822c3_
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable


>=20
> Alice Wei wrote:
> >=20
> >> Date: Thu=2C 25 Feb 2010 13:50:16 -0600
> >> From: nospam@mckenzies.net
> >> To: ajwei@alumni.iu.edu
> >> CC: php-general@lists.php.net
> >> Subject: Re: PHP "GET" Error?
> >>
> >> Alice Wei wrote:
> >>> Hi,
> >>>
> >>> I forgot to mention that the url is formed from Actionscript=2C I a=
m just using PHP to do the "I/O" because Actionscript does not have this op=
tion.=20
> >>>
> >>> So=2C I guess I cannot do the serialize here like you suggested. I =
have changed # to 0x for now=2C and that does not seem to help yet.=20
> >>> BTW=2C below is the complete code=2C would this help with my choice=
s?
> >>>
> >> I haven't used actionscript=2C but it's javascript basically yes?
> >>
> >> Use encodeURI() or encodeURIComponent() on the data.
> >>
> >>
> > Yes=2C and no. But=2C I did find the function in the Actionscript li=
brary=2C and I used the new url to pass through to PHP. Looks like it still=
didn't work=2C could the length be an issue?=20
> >=20
> > BTW=2C these two variables start off from Actionscript as "arrays"=
=2C but would knowing this here help? It would be nice that I can just pass=
them on as arrays (I had to "turn them into strings" before I passed to PH=
P).=20
> >=20
> > Thanks for your help.=20
>=20
> Those functions will work if you do it properly. As for arrays=2C the
> only way I know of in js is to json encode them and then you can use the
> PHP json_decode() to get them back. There is no native js function to
> do this=2C however there may be one in the actionscript library or there
> are some functions on the web that people have written.
>=20
> Wait=2C I found this: http://code.google.com/p/as3corelib/
>=20
> Functionality may already be in As=2C but may be of use.
>=20
>=20
When you meant function=2C do you mean the function from my PHP end to turn=
it into array=2C or Actionscript?=20
Based on the url I sent Ashley=2C do you think that is something that would=
work?=20

Thanks.=20
> --=20
> Thanks!
> -Shawn
> http://www.spidean.com
=20
____________________________________________________________ _____
Hotmail: Trusted email with powerful SPAM protection.
http://clk.atdmt.com/GBL/go/201469227/direct/01/=

--_7e4cc2be-f119-4c72-83d1-ea12576822c3_--

Re: RE: PHP "GET" Error?

am 25.02.2010 21:24:35 von Shawn McKenzie

Alice Wei wrote:
> Subject: Re: [PHP] RE: PHP "GET" Error?
> From: ash@ashleysheridan.co.uk
> To: ajwei@alumni.iu.edu
> CC: nospam@mckenzies.net; php-general@lists.php.net
> Date: Thu, 25 Feb 2010 20:03:28 +0000
>
>
>
>
>
>
>
>
>
>
> On Thu, 2010-02-25 at 15:01 -0500, Alice Wei wrote:
>
>
>> Date: Thu, 25 Feb 2010 13:50:16 -0600
>> From: nospam@mckenzies.net
>> To: ajwei@alumni.iu.edu
>> CC: php-general@lists.php.net
>> Subject: Re: PHP "GET" Error?
>>
>> Alice Wei wrote:
>>> Hi,
>>>
>>> I forgot to mention that the url is formed from Actionscript, I am just using PHP to do the "I/O" because Actionscript does not have this option.
>>>
>>> So, I guess I cannot do the serialize here like you suggested. I have changed # to 0x for now, and that does not seem to help yet.
>>> BTW, below is the complete code, would this help with my choices?
>>>
>> I haven't used actionscript, but it's javascript basically yes?
>>
>> Use encodeURI() or encodeURIComponent() on the data.
>>
>>
> Yes, and no. But, I did find the function in the Actionscript library, and I used the new url to pass through to PHP. Looks like it still didn't work, could the length be an issue?
>
> BTW, these two variables start off from Actionscript as "arrays", but would knowing this here help? It would be nice that I can just pass them on as arrays (I had to "turn them into strings" before I passed to PHP).
>
> Thanks for your help.
>
> Alice
>
>> --
>> Thanks!
>> -Shawn
>> http://www.spidean.com
>
> ____________________________________________________________ _____
> Your E-mail and More On-the-Go. Get Windows Live Hotmail Free.
> http://clk.atdmt.com/GBL/go/201469229/direct/01/
>
>
>
>
> Have you tried outputting the URL string to see if it's properly formed? AS3 can still trace() can't it?
>
>
>
> This link should give you an idea of the string limits of different browsers and servers:
>
>
>
> http://www.boutell.com/newfaq/misc/urllength.html
>
> I have just done that, and here is the pathetically long url:
>
> http://tdc-queuing/test/generic.php?from=Adair,%20OK-Alfalfa ,%20OK-Atoka,%20OK-Beaver,%20OK-Beckham,%20OK-Blaine,%20OK-B ryan,%20OK-Caddo,%20OK-Canadian,%20OK-Carter,%20OK-Cherokee, %20OK-Choctaw,%20OK-Cimarron,%20OK-Cleveland,%20OK-Coal,%20O K-Comanche,%20OK-Cotton,%20OK-Craig,%20OK-Creek,%20OK-Custer ,%20OK-Delaware,%20OK-Dewey,%20OK-Ellis,%20OK-Garfield,%20OK -Garvin,%20OK-Grady,%20OK-Grant,%20OK-Greer,%20OK-Harmon,%20 OK-Harper,%20OK-Haskell,%20OK-Hughes,%20OK-Jackson,%20OK-Jef ferson,%20OK-Johnston,%20OK-Kay,%20OK-Kingfisher,%20OK-Kiowa ,%20OK-Latimer,%20OK-Le%20Flore,%20OK-Lincoln,%20OK-Logan,%2 0OK-Love,%20OK-Major,%20OK-Marshall,%20OK-Mayes,%20OK-McClai n,%20OK-McCurtain,%20OK-McIntosh,%20OK-Murray,%20OK-Muskogee ,%20OK-Noble,%20OK-Nowata,%20OK-Okfuskee,%20OK-Oklahoma,%20O K-Okmulgee,%20OK-O
sage,%20OK-Ottawa,%20OK-Pawnee,%20OK-Payne,%20OK-Pittsburg,% 20OK-Pontotoc,%20OK-Pottawatomie,%20OK-Pushmataha,%20OK-Roge r%20Mills,%20OK-Rogers,%20OK-Seminole,%20OK-Sequoyah,%20OK-S tephens,%2
0OK-Texas,%20OK-Tillman,%20OK-Tulsa,%20OK-Wagoner,%20OK-Wash ington,%20OK-Washita,%20OK-Woods,%20OK-Woodward,%20OK&state_ colors=0xFFFFCC-0xFFFFCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFFCCCC -0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFFC CCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFF9999-0xFF9999-0xFF9999-0x FF9999-0xFF9999-0xFF9999-0xFF9999-0xFF9999-0xFF9999-0xFF9999 -0xFF9999-0xFF9999-0xFF9999-0xFF9999-0xFF9999-0x0DCCFF-0x0DC CFF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x 0DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF -0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x333 3FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x 3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF -0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x333 3FF-0x3333FF-0x3333F
F-0x3333FF-0x3333FF
>
> This is generated from the encodeURI() Shawn was talking about. Does this seem "well-formed" to you?
>
> Thanks.
>
> Alice
>

That URL works for me, however, why the 0x in the colors? # is URL
encoded as %23, so the color #FFFFFF would be %23FFFFFF.
--
Thanks!
-Shawn
http://www.spidean.com

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

RE: RE: PHP "GET" Error?

am 25.02.2010 21:37:19 von Alice Wei

--_a255d08d-824a-4631-b283-d6f9fd33fbec_
Content-Type: text/plain; charset="Windows-1252"
Content-Transfer-Encoding: quoted-printable


> Alice Wei wrote:
> > Hi,
> >=20
> > I forgot to mention that the url is formed from Actionscript=2C I am =
just using PHP to do the "I/O" because Actionscript does not have this opti=
on.=20
> >=20
> > So=2C I guess I cannot do the serialize here like you suggested. I ha=
ve changed # to 0x for now=2C and that does not seem to help yet.=20
> > BTW=2C below is the complete code=2C would this help with my choices?
> >=20
>=20
> I haven't used actionscript=2C but it's javascript basically yes?
>=20
> Use encodeURI() or encodeURIComponent() on the data.
>=20
>=20
Yes=2C and no. But=2C I did find the function in the Actionscript librar=
y=2C and I used the new url to pass through to PHP. Looks like it still did=
n't work=2C could the length be an issue?=20

BTW=2C these two variables start off from Actionscript as "arrays"=2C bu=
t would knowing this here help? It would be nice that I can just pass them =
on as arrays (I had to "turn them into strings" before I passed to PHP).=20

Thanks for your help.=20

Alice

> --=20
> Thanks!
> -Shawn
> http://www.spidean.com
=20


Have you tried outputting the URL string to see if it's properly formed? AS=
3 can still trace() can't it?
This link should give you an idea of the string limits of different browser=
s and servers:


http://www.boutell.com/newfaq/misc/urllength.html

I have just done that=2C and here is the pathetically long url:

http://tdc-queuing/test/generic.php?from=3DAdair=2C%20OK-Alf alfa=2C%20OK-At=
oka=2C%20OK-Beaver=2C%20OK-Beckham=2C%20OK-Blaine=2C%20OK-Br yan=2C%20OK-Cad=
do=2C%20OK-Canadian=2C%20OK-Carter=2C%20OK-Cherokee=2C%20OK- Choctaw=2C%20OK=
-Cimarron=2C%20OK-Cleveland=2C%20OK-Coal=2C%20OK-Comanche=2C %20OK-Cotton=2C=
%20OK-Craig=2C%20OK-Creek=2C%20OK-Custer=2C%20OK-Delaware=2C %20OK-Dewey=2C%=
20OK-Ellis=2C%20OK-Garfield=2C%20OK-Garvin=2C%20OK-Grady=2C% 20OK-Grant=2C%2=
0OK-Greer=2C%20OK-Harmon=2C%20OK-Harper=2C%20OK-Haskell=2C%2 0OK-Hughes=2C%2=
0OK-Jackson=2C%20OK-Jefferson=2C%20OK-Johnston=2C%20OK-Kay=2 C%20OK-Kingfish=
er=2C%20OK-Kiowa=2C%20OK-Latimer=2C%20OK-Le%20Flore=2C%20OK- Lincoln=2C%20OK=
-Logan=2C%20OK-Love=2C%20OK-Major=2C%20OK-Marshall=2C%20OK-M ayes=2C%20OK-Mc=
Clain=2C%20OK-McCurtain=2C%20OK-McIntosh=2C%20OK-Murray=2C%2 0OK-Muskogee=2C=
%20OK-Noble=2C%20OK-Nowata=2C%20OK-Okfuskee=2C%20OK-Oklahoma =2C%20OK-Okmulg=
ee=2C%20OK-Osage=2C%20OK-Ottawa=2C%20OK-Pawnee=2C%20OK-Payne =2C%20OK-Pittsb=
urg=2C%20OK-Pontotoc=2C%20OK-Pottawatomie=2C%20OK-Pushmataha =2C%20OK-Roger%=
20Mills=2C%20OK-Rogers=2C%20OK-Seminole=2C%20OK-Sequoyah=2C% 20OK-Stephens=
=2C%20OK-Texas=2C%20OK-Tillman=2C%20OK-Tulsa=2C%20OK-Wagoner =2C%20OK-Washin=
gton=2C%20OK-Washita=2C%20OK-Woods=2C%20OK-Woodward=2C%20OK& state_colors=3D=
0xFFFFCC-0xFFFFCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFFCC CC-0xFFCCCC-0xF=
FCCCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFFCCCC-0xFFCCCC- 0xFFCCCC-0xFF99=
99-0xFF9999-0xFF9999-0xFF9999-0xFF9999-0xFF9999-0xFF9999-0xF F9999-0xFF9999-=
0xFF9999-0xFF9999-0xFF9999-0xFF9999-0xFF9999-0xFF9999-0x0DCC FF-0x0DCCFF-0x0=
DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF- 0x0DCCFF-0x0DCC=
FF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x0DCCFF-0x3333FF-0x3333FF-0x3 333FF-0x3333FF-=
0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333 FF-0x3333FF-0x3=
333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF- 0x3333FF-0x3333=
FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3333FF-0x3 333FF-0x3333FF-=
0x3333FF-0x3333FF

This is generated from the encodeURI() Shawn was talking about. Does this s=
eem "well-formed" to you?

Thanks.

Alice
=20
____________________________________________________________ _____
Hotmail: Trusted email with powerful SPAM protection.
http://clk.atdmt.com/GBL/go/201469227/direct/01/


I can't see anything obviously wrong with the URL really. Is there no way i=
nstead to send the data as post data from Flash? I know Flash can make post=
requests=2C but I'm not sure how much more difficult it is.

I had it using POST before=2C but from the PHP point of view=2C it does no=
t matter how I make the request=2C does it? I mean=2C if the variables are =
problematic=2C would it matter if I use POST or GET?

Thanks.=20





=20
____________________________________________________________ _____
Hotmail: Trusted email with Microsoft=92s powerful SPAM protection.
http://clk.atdmt.com/GBL/go/201469226/direct/01/=

--_a255d08d-824a-4631-b283-d6f9fd33fbec_--

Re: RE: PHP "GET" Error?

am 25.02.2010 22:04:46 von Shawn McKenzie

Alice Wei wrote:
> I can't see anything obviously wrong with the URL really. Is there no
> way instead to send the data as post data from Flash? I know Flash
> can make post requests, but I'm not sure how much more difficult it
> is.
>
> I had it using POST before, but from the PHP point of view, it does
> not matter how I make the request, does it? I mean, if the variables
> are problematic, would it matter if I use POST or GET?
>

All seems fine to me. You can use post, but what's not working? Try
trimming back to just 2 from and colors and test it. What does
var_dump($_GET) show on the PHP page?

-Shawn


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

RE: RE: PHP "GET" Error?

am 25.02.2010 22:21:34 von Alice Wei

--_ced76fb4-1320-4e13-9abb-7604b16a7d71_
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable



> Date: Thu=2C 25 Feb 2010 15:04:46 -0600
> From: nospam@mckenzies.net
> To: ajwei@alumni.iu.edu
> CC: ash@ashleysheridan.co.uk=3B php-general@lists.php.net
> Subject: Re: [PHP] RE: PHP "GET" Error?
>=20
> Alice Wei wrote:
> > I can't see anything obviously wrong with the URL really. Is there no
> > way instead to send the data as post data from Flash? I know Flash
> > can make post requests=2C but I'm not sure how much more difficult it
> > is.
> >
> > I had it using POST before=2C but from the PHP point of view=2C it does
> > not matter how I make the request=2C does it? I mean=2C if the variable=
s
> > are problematic=2C would it matter if I use POST or GET?
> >
>=20
> All seems fine to me. You can use post=2C but what's not working? Try
> trimming back to just 2 from and colors and test it. What does
> var_dump($_GET) show on the PHP page?
>=20
> -Shawn
>=20
Too bad that Actionscript does not encode special characters=2C I had to us=
e string replacement to replace it.=20
However=2C now it looks like my PHP is now fine=2C and my image does displa=
y correctly.=20

Thanks for your help!

Alice
=20
____________________________________________________________ _____
Hotmail: Trusted email with powerful SPAM protection.
http://clk.atdmt.com/GBL/go/201469227/direct/01/=

--_ced76fb4-1320-4e13-9abb-7604b16a7d71_--