php-general Digest 10 Sep 2009 16:21:47 -0000 Issue 6332

2009-09-10 Thread php-general-digest-help
php-general Digest 10 Sep 2009 16:21:47 - Issue 6332 Topics (messages 297849 through 297869): Re: Performance of while(true) loop 297849 by: Eddie Drapkin 297850 by: APseudoUtopia 297851 by: Eddie Drapkin 297852 by: Ben Dunlap header problem 297853

[PHP] header problem

2009-09-10 Thread A.a.k
hello I recentrly uploaded my project from localhost to a hosting and found many errors and warnings which didnt have in local. one of the most annoying one is header('Location xxx'). I have used header to redirect users from pages, and kinda used it alot. i know about the whitespace causing

Re: [PHP] header problem

2009-09-10 Thread George Langley
Hi Blueman. As soon as ANYTHING has been drawn to the browser, you cannot use a header command. So you need to work through all of your code, and ensure that all of your logic that could result in a header call is run BEFORE you send any html code. Is going to be tricky if mixing html and

[PHP] upgrade php4 to php5

2009-09-10 Thread madunix
how can i upgrade my php4 to php5? [r...@intra /]# uname -a Linux intra 2.6.9-5.ELsmp #1 SMP Wed Jan 5 19:30:39 EST 2005 i686 i686 i386 GNU/Linux /usr/local/apache/bin/apachectl stop cd /downloads/ cd php-4.4.3 ./configure --with-apxs2=/usr/local/apache/bin/apxs --with-mysql=/usr/local/mysql

Re: [PHP] upgrade php4 to php5

2009-09-10 Thread Eddie Drapkin
On Thu, Sep 10, 2009 at 2:51 AM, madunix madu...@gmail.com wrote: how can i upgrade my php4 to php5? [r...@intra /]# uname -a Linux intra 2.6.9-5.ELsmp #1 SMP Wed Jan 5 19:30:39 EST 2005 i686 i686 i386 GNU/Linux /usr/local/apache/bin/apachectl stop cd /downloads/ cd php-4.4.3 ./configure

Re: [PHP] header problem

2009-09-10 Thread A.a.k
is there any alternative to header() for redirect users? George Langley george.lang...@shaw.ca wrote in message news:b1b897d4-7448-4b71-bffc-3addc27ce...@shaw.ca... Hi Blueman. As soon as ANYTHING has been drawn to the browser, you cannot use a header command. So you need to work through all

Re: [PHP] header problem

2009-09-10 Thread Marcus Gnaß
A.a.k wrote: is there any alternative to header() for redirect users? As far as I know there isn't. Is the header-error the first error on the page? If not, the other error message itself is the reason for the header-error and will be solved if you solve the other error. -- PHP General

Re: [PHP] header problem

2009-09-10 Thread Ashley Sheridan
On Thu, 2009-09-10 at 08:57 +0200, A.a.k wrote: is there any alternative to header() for redirect users? George Langley george.lang...@shaw.ca wrote in message news:b1b897d4-7448-4b71-bffc-3addc27ce...@shaw.ca... Hi Blueman. As soon as ANYTHING has been drawn to the browser, you cannot

Re: [PHP] header problem

2009-09-10 Thread HostWare Kft.
Usually, when I have to redirect the user AFTER headers has been sent (like showing an error message), I write this: SCRIPTlocation=page_to_send.html/SCRIPT But this will redirect the user at once. If you want the user to read the page, you should do something in Javascript with

Re: [PHP] header problem

2009-09-10 Thread Ashley Sheridan
On Thu, 2009-09-10 at 09:04 +0200, Sándor Tamás (HostWare Kft.) wrote: Usually, when I have to redirect the user AFTER headers has been sent (like showing an error message), I write this: SCRIPTlocation=page_to_send.html/SCRIPT But this will redirect the user at once. If you want the user

RE: [PHP] header problem

2009-09-10 Thread Arno Kuhl
-Original Message- From: A.a.k [mailto:blue...@gmail.com] Sent: 10 September 2009 08:27 AM To: php-general@lists.php.net Subject: [PHP] header problem hello I recentrly uploaded my project from localhost to a hosting and found many errors and warnings which didnt have in local. one of

[PHP] Hoping for a hand with a login script

2009-09-10 Thread Watson Blair
Hey guys,This is a simple issue I'm sure, however I'm having one hell of a time seeing my way clear of it. I appreciate any support you guys could throw my way. So I'm trying to set up a small website that includes a store ( www.rareintaglio.com), i have all of my HTML hammed out and now I'm

Re: [PHP] Hoping for a hand with a login script

2009-09-10 Thread Tommy Pham
--- On Thu, 9/10/09, Watson Blair bestudios...@gmail.com wrote: From: Watson Blair bestudios...@gmail.com Subject: [PHP] Hoping for a hand with a login script To: php-general@lists.php.net Date: Thursday, September 10, 2009, 4:06 AM Hey guys,This is a simple issue I'm sure, however I'm

Re: [PHP] Hoping for a hand with a login script

2009-09-10 Thread Tommy Pham
--- On Thu, 9/10/09, Tommy Pham tommy...@yahoo.com wrote: From: Tommy Pham tommy...@yahoo.com Subject: Re: [PHP] Hoping for a hand with a login script To: php-general@lists.php.net Date: Thursday, September 10, 2009, 4:13 AM --- On Thu, 9/10/09, Watson Blair bestudios...@gmail.com wrote:

[PHP] Re: Hoping for a hand with a login script

2009-09-10 Thread Tony Marston
You are constructing your query in $qury yet you are trying to read it from $query. Because they have different spellings they are treated as different variables. -- Tony Marston http://www.tonymarston.net http://www.radicore.org Watson Blair bestudios...@gmail.com wrote in message

Re: [PHP] Hoping for a hand with a login script

2009-09-10 Thread Watson Blair
Hey Tommy,Thanks for the link, I found a few typos in my variables, and Query. but now it's returning: Results: Resource id #2 *Warning*: Cannot modify header information - headers already sent by (output started at /home/content/i/n/t/intag/html/session.php:16) in *

Re: [PHP] Hoping for a hand with a login script

2009-09-10 Thread Tommy Pham
-- On Thu, 9/10/09, Watson Blair bestudios...@gmail.com wrote: From: Watson Blair bestudios...@gmail.com Subject: Re: [PHP] Hoping for a hand with a login script To: Tommy Pham tommy...@yahoo.com Cc: php-general@lists.php.net Date: Thursday, September 10, 2009, 4:31 AM Hey Tommy,Thanks for

Re: [PHP] Hoping for a hand with a login script

2009-09-10 Thread Ben Dunlap
So I'm trying to set up a small website that includes a store ( www.rareintaglio.com), i have all of my HTML hammed out and now I'm working on creating an admin login for the sites owner to input data from a back I would really strongly advise against building your own authentication system.

Re: [PHP] Hoping for a hand with a login script

2009-09-10 Thread Robert Cummings
Ben Dunlap wrote: So I'm trying to set up a small website that includes a store ( www.rareintaglio.com), i have all of my HTML hammed out and now I'm working on creating an admin login for the sites owner to input data from a back I would really strongly advise against building your own

RE: [PHP] Hoping for a hand with a login script

2009-09-10 Thread Bob McConnell
From: Ben Dunlap So I'm trying to set up a small website that includes a store ( www.rareintaglio.com), i have all of my HTML hammed out and now I'm working on creating an admin login for the sites owner to input data from a back I would really strongly advise against building your own

Re: [PHP] Hoping for a hand with a login script

2009-09-10 Thread Bastien Koert
On Thu, Sep 10, 2009 at 12:21 PM, Ben Dunlap bdun...@agentintellect.com wrote: So I'm trying to set up a small website that includes a store ( www.rareintaglio.com), i have all of my HTML hammed out and now I'm working on creating an admin login for the sites owner to input data from a back

Re: [PHP] Performance of while(true) loop

2009-09-10 Thread Jim Lucas
APseudoUtopia wrote: Hey list, I have a php cli script that listens on a UDP socket and, when data is sent to the socket, the script inserts it into a database. I'm using the real BSD socket functions, not fsock. The script runs socket_create(), then socket_bind(). Then it starts a

Re: [PHP] Hoping for a hand with a login script

2009-09-10 Thread Ben Dunlap
several packages available to provide it. But I believe that telling someone to adopt a complete portal system like CI just to get basic authentication is gross overkill. There has to be a better way to provide this core functionality without installing a monster package that will be 95%

Re: [PHP] Hoping for a hand with a login script

2009-09-10 Thread Ben Dunlap
I would recommend this to anyone looking to build any sort of web app. Could be that nothing out there will end up serving your purposes, but ... and, on further investigation, it looks like CI, surprisingly enough, doesn't actually have pre-built authentication and access control (although it

[PHP] Reading files in PHP 5.3.0

2009-09-10 Thread Steve Brown
I've been beating my head against a wall all day and can't figure this one out. The code below worked perfectly in PHP5.2.4. However, I recently upgraded to PHP5.3.0 and this code no longer works. The function below accepts the path to a text file containing headers from a cUrl session (example

[PHP] RE: [Formaldehyde] The Most Basic Ajax - PHP Error Debugger

2009-09-10 Thread Andrea Giammarchi
Being something nobody thought before I was expecting some comment ... zero Ajax developers here? Anyway, to make things even more simple I have released the Zero Config client side file, which works with most known browsers, IE included, and it does not require a single change in existent

[PHP] Creating alphanumeric id for a table

2009-09-10 Thread aveev
I want to create user generated id like this : AAA0001 AAA0002 ... AAA0009 AAA0010 where the id consists of 3 alphanumeric characters and 4 numerical digits in the beginning (for numerical digit, it can grow like this AAA10001). I try to use php script to generate id like this, where I use the

Re: [PHP] Creating alphanumeric id for a table

2009-09-10 Thread Ben Dunlap
I assume that I can get increment value/sequence from db  (I used harcoded increment value  in the code above (generate_id(1))), but I don't know how I can get this incremental value from db.I use mysql 5.0. If you're thinking of retrieving the newest value of an AUTO_INCREMENT column,

Re: [PHP] Reading files in PHP 5.3.0

2009-09-10 Thread Tommy Pham
--- On Thu, 9/10/09, Steve Brown sbrow...@gmail.com wrote: From: Steve Brown sbrow...@gmail.com Subject: [PHP] Reading files in PHP 5.3.0 To: php-general@lists.php.net Date: Thursday, September 10, 2009, 4:13 PM I've been beating my head against a wall all day and can't figure this one

Re: [PHP] String scrambling

2009-09-10 Thread Eddie Drapkin
On Thu, Sep 10, 2009 at 8:57 PM, Ron Piggott ron@actsministries.org wrote: Is there a function in PHP which scrambles strings? Example: $string = Hello; Output might be: ehlol Ron http://www.php.net/manual/en/function.str-shuffle.php -- PHP General Mailing List

Re: [PHP] Hoping for a hand with a login script

2009-09-10 Thread Paul M Foster
On Thu, Sep 10, 2009 at 01:00:19PM -0400, Bob McConnell wrote: From: Ben Dunlap snip http://codeigniter.com/ http://framework.zend.com/ http://www.solarphp.com/ While I have not looked at the last two, there is one thing that bothers me about your recommendation of codeigniter.

Re: [PHP] Creating alphanumeric id for a table

2009-09-10 Thread Phpster
Note that this approach has risks around race conditions. Anytime you have a construct for the id you run the risk of having it create duplicate ids. You will need to handle that. Bastien Sent from my iPod On Sep 10, 2009, at 6:49 PM, Ben Dunlap bdun...@agentintellect.com wrote: I