[PHP] Getting values from the Javascript namespace

2005-03-27 Thread Daniel Lahey
Is there any way to get values from the Javascript namespace into PHP? I want to use a value passed into a Javascript function in a query within some PHP code in the function which is used to dynamically populate a select's options. TIA -- PHP General Mailing List (http://www.php.net/) To

[PHP] Re: So this isnt a bug?

2005-03-27 Thread Aaron
Ive made it clear. If I use the success_box function that uses java to redirect it works perfectly, but if I use the header command the variables are stripped. This is only when a $_FILE is passed. A. S. Milnes [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Aaron wrote:

[PHP] Illegal string offset error in array

2005-03-27 Thread Johannes Findeisen
Hello all, sorry if this has been asked allready but i didn't find any usefull information in the web. Why is this function not working in PHP5? function getNavigationContent($content_path) { $i = 0; $dir = opendir($content_path); while ($file = readdir ($dir)){ if

[PHP] Re: Avoiding SQL injections: htmlentities() ?

2005-03-27 Thread Raj Shekhar
[EMAIL PROTECTED] writes: So if I could broaden the question and ask, in general, what people recommend for pre-processing data before it goes into a SQL statement.. for security and for things like making sure singlequotes and other special characters are escaped properly?

[PHP] world write access

2005-03-27 Thread Evert - Rooftop Solutions
Hi people, I'm trying to think of a way to make an auto-updater for my distributed scripts. If I wanted to do this, I'd have to give write access to the php scripts to the apache user or world. Everywhere I read that you shouldn't to that, but I'm thinking that if you script your stuff right,

[PHP] trustudio - eclipse IDE + CVS

2005-03-27 Thread D_C
I am using the trustudio IDE (an eclipse plugin basically) it has a really nice feature where it will give popups for argument list for your functions. however, when i am using a project from CVS rather than the local file system, this breaks, and i get an error "The resource

Re: [PHP] world write access

2005-03-27 Thread Johannes Findeisen
Hello, It is generally not a good idea to make scripts to everybody writeable. I think that if you're implementing auto-update features in PHP scripts they only could be insecure. Okay, you have one more feature but what if this feature goes out of control? Be really carefull when writing such

[PHP] Still fighting setcookie

2005-03-27 Thread John Hinton
OK, I created this most simplistic script.. Begin Script--- ?php if(isset($value)) { setcookie(mycookie,$value); } define (Login, 0); define (DataReturn, 1); function login() { echo form ACTION=\$_SERVER[PHP_SELF]?action=1\ METHOD=\post\

Re: [PHP] setcookie issue

2005-03-27 Thread Chris Shiflett
John Hinton wrote: The thing is, on the next action switch print_r($_COOKIE); returns empty until I refresh the browser. So, thusly, the second page load brings in the cookies. $_COOKIES is a convenient array that contains the contents of the Cookie header, nicely parsed. Whenever you set a

[PHP] Maximum Execution Time Exceeded

2005-03-27 Thread mikeytf
I would like to know if you could help me.. I don't understand what is wrong! I made a file that is supposed to list 2 categories with the boards that go to them under them. I get a Fatal Error: Maxmimum execution time of 30 seconds exceeded. Here is the file that gives me the error:

Re: [PHP] world write access

2005-03-27 Thread Evert | Rooftop Solutions
Thanx Johannes, how about making the webserver the owner of the files? Would that be a good idea? The problem is that I have a framework deployed at several clients. Because this are some big clients and demand high security they won't give me a login to their ftp or consoles. Understandable,

[PHP] Re: Getting values from the Javascript namespace

2005-03-27 Thread Jasper Bryant-Greene
Daniel Lahey wrote: Is there any way to get values from the Javascript namespace into PHP? I want to use a value passed into a Javascript function in a query within some PHP code in the function which is used to dynamically populate a select's options. TIA JavaScript is parsed on the client

[PHP] Re: Illegal string offset error in array

2005-03-27 Thread Jasper Bryant-Greene
Johannes Findeisen wrote: Hello all, sorry if this has been asked allready but i didn't find any usefull information in the web. Why is this function not working in PHP5? [snip] /* * This line does not work in PHP5 cause off

[PHP] mysql_fetch_row not working?

2005-03-27 Thread mikeytf
?php $category=mysql_query(SELECT * FROM categories ORDER BY catid ASC) or die(mysql_error()); while($get_cat=mysql_fetch_row($category)) $board=mysql_query(SELECT * FROM boards WHERE hidden='No' AND catid='.$get_cat[0].' ORDER BY boardid ASC) or die(mysql_error());

[PHP] Re: Still fighting setcookie

2005-03-27 Thread Jasper Bryant-Greene
John Hinton wrote: OK, I created this most simplistic script.. [snip] I would expect the return on action=1 to report the set cookie, but instead, it has no data. If I then reload the browser, the cookie appears. How can I get the cookie to set without this reload? What am I missing? Thanks a

[PHP] Re: Still fighting setcookie

2005-03-27 Thread Jasper Bryant-Greene
Jasper Bryant-Greene wrote: [snip] function setcookie2($name, $value=, $expire=, $path=, $domain=, $secure=false) { $_COOKIES[$name] = $value; return setcookie($name, $value, $expire, $path, $domain, $secure); } [snip] Sorry, that should be: $_COOKIE[$name] = $value; -- Jasper

Re: [PHP] Re: Illegal string offset error in array

2005-03-27 Thread Rasmus Lerdorf
Jasper Bryant-Greene wrote: Johannes Findeisen wrote: Hello all, sorry if this has been asked allready but i didn't find any usefull information in the web. Why is this function not working in PHP5? [snip] /* * This line does

Re: [PHP] Re: Illegal string offset error in array

2005-03-27 Thread Jasper Bryant-Greene
Rasmus Lerdorf wrote: Jasper Bryant-Greene wrote: You can't access string offsets with square brackets [] in PHP5. You need to use curly braces {} instead. Not sure where you got that idea. This is not true. -Rasmus Actually, it is. See the following URL:

Re: [PHP] Re: Illegal string offset error in array

2005-03-27 Thread Rasmus Lerdorf
Jasper Bryant-Greene wrote: Rasmus Lerdorf wrote: Jasper Bryant-Greene wrote: You can't access string offsets with square brackets [] in PHP5. You need to use curly braces {} instead. Not sure where you got that idea. This is not true. -Rasmus Actually, it is. See the following URL:

Re: [PHP] Re: Illegal string offset error in array

2005-03-27 Thread Jasper Bryant-Greene
Rasmus Lerdorf wrote: Jasper Bryant-Greene wrote: You can't access string offsets with square brackets [] in PHP5. You need to use curly braces {} instead. Not sure where you got that idea. This is not true. -Rasmus Actually, it is. See the following URL:

Re: [PHP] Re: Illegal string offset error in array

2005-03-27 Thread Rasmus Lerdorf
Jasper Bryant-Greene wrote: Rasmus Lerdorf wrote: Jasper Bryant-Greene wrote: You can't access string offsets with square brackets [] in PHP5. You need to use curly braces {} instead. Not sure where you got that idea. This is not true. -Rasmus Actually, it is. See the following URL:

Re: [PHP] Re: Illegal string offset error in array

2005-03-27 Thread James Kaufman
On Mon, Mar 28, 2005 at 11:29:28AM +1200, Jasper Bryant-Greene wrote: Rasmus Lerdorf wrote: Jasper Bryant-Greene wrote: You can't access string offsets with square brackets [] in PHP5. You need to use curly braces {} instead. Not sure where you got that idea. This is not true. -Rasmus

[PHP] Converting hexadecimal string

2005-03-27 Thread Ashley M. Kirchner
Short (possibly simple) question: How do I convert a hexadecimal string back into it's ascii representation? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] array sorting

2005-03-27 Thread Merlin
Hi there, I would like to save some db power by putting values into a file which are often used. They basicly populate a select field. So I placed those values into associative arrays: $code[language] = array(1= php, 2= asp); Now I would like to sort those for displaying after my preference, not