Re: [PHP] Question - foreach.

2010-06-09 Thread Daniel Brown
On Wed, Jun 9, 2010 at 21:49, Shreyas shreya...@gmail.com wrote: PHP'ers, I am reading a PHP book which explains foreach and at the end says : *'When foreach starts walking through an array, it moves the pointer to the beginning of the array. You don’t need to reset an array before walking

Re: [PHP] Question about a security function

2010-05-21 Thread David Otton
On 20 May 2010 16:51, Al n...@ridersite.org wrote: I'm not being clear. First pass is thru the blacklist, which effectually tells hacker to not bother and totally deletes the entry. If the raw entry gets past the blacklist, it must then only contain my whitelist tags. e.g., the two examples

Re: [PHP] Question about a security function

2010-05-21 Thread Ashley Sheridan
On Fri, 2010-05-21 at 14:24 +0100, David Otton wrote: On 20 May 2010 16:51, Al n...@ridersite.org wrote: I'm not being clear. First pass is thru the blacklist, which effectually tells hacker to not bother and totally deletes the entry. If the raw entry gets past the blacklist, it must

Re: [PHP] Question about a security function

2010-05-21 Thread Al
On 5/21/2010 9:24 AM, David Otton wrote: On 20 May 2010 16:51, Aln...@ridersite.org wrote: I'm not being clear. First pass is thru the blacklist, which effectually tells hacker to not bother and totally deletes the entry. If the raw entry gets past the blacklist, it must then only contain

Re: [PHP] Question about a security function

2010-05-21 Thread David Otton
On 21 May 2010 14:21, Ashley Sheridan a...@ashleysheridan.co.uk wrote: I still think you might be better off using BBCode, which is used on websites just for this very purpose. When any input comes back, you can remove all the HTML completely and replace the BBCode tags that you allow. This

Re: [PHP] Question about a security function

2010-05-21 Thread Al
On 5/21/2010 9:21 AM, Ashley Sheridan wrote: On Fri, 2010-05-21 at 14:24 +0100, David Otton wrote: On 20 May 2010 16:51, Aln...@ridersite.org wrote: I'm not being clear. First pass is thru the blacklist, which effectually tells hacker to not bother and totally deletes the entry. If the

Re: [PHP] Question about a security function

2010-05-21 Thread Jim Lucas
Al wrote: On 5/21/2010 9:24 AM, David Otton wrote: On 20 May 2010 16:51, Aln...@ridersite.org wrote: I'm not being clear. First pass is thru the blacklist, which effectually tells hacker to not bother and totally deletes the entry. If the raw entry gets past the blacklist, it must then

Re: [PHP] Question about a security function

2010-05-21 Thread Al
On 5/21/2010 10:36 AM, Jim Lucas wrote: Al wrote: On 5/21/2010 9:24 AM, David Otton wrote: On 20 May 2010 16:51, Aln...@ridersite.org wrote: I'm not being clear. First pass is thru the blacklist, which effectually tells hacker to not bother and totally deletes the entry. If the raw

[PHP] Question about a security function

2010-05-20 Thread Al
I have a password-protected, user, on-line editor that I'm hardening against hackers just in case a user's pw is stolen or local PC is infected. The user can enter html tags; but, I restrict the acceptable tags to benign ones. e.g., p, b, table, etc. e.g., no embed... script... etc. Just to

Re: [PHP] Question about a security function

2010-05-20 Thread Peter Lind
On 20 May 2010 14:53, Al n...@ridersite.org wrote: I have a password-protected, user, on-line editor that I'm hardening against hackers just in case a user's pw is stolen or local PC is infected. The user can enter html tags; but, I restrict the acceptable tags to benign ones. e.g., p, b,

Re: [PHP] Question about a security function

2010-05-20 Thread David Otton
On 20 May 2010 13:53, Al n...@ridersite.org wrote: I have a password-protected, user, on-line editor that I'm hardening against hackers just in case a user's pw is stolen or local PC is infected. The user can enter html tags; but, I restrict the acceptable tags to benign ones. e.g., p, b,

Re: [PHP] Question about a security function

2010-05-20 Thread Ashley Sheridan
On Thu, 2010-05-20 at 14:27 +0100, David Otton wrote: On 20 May 2010 13:53, Al n...@ridersite.org wrote: I have a password-protected, user, on-line editor that I'm hardening against hackers just in case a user's pw is stolen or local PC is infected. The user can enter html tags; but, I

Re: [PHP] Question about a security function

2010-05-20 Thread Al
On 5/20/2010 10:07 AM, Ashley Sheridan wrote: On Thu, 2010-05-20 at 14:27 +0100, David Otton wrote: On 20 May 2010 13:53, Aln...@ridersite.org wrote: I have a password-protected, user, on-line editor that I'm hardening against hackers just in case a user's pw is stolen or local PC is

Re: [PHP] Question about a security function

2010-05-20 Thread David Otton
On 20 May 2010 15:52, Al n...@ridersite.org wrote: I agree blacklisting is a flawed approach in general. My approach is to strictly confine entry text to a whitelist of benign, acceptable tags. The But that's not what you've done. You've blacklisted the following patterns: \script\x20,

Re: [PHP] Question about a security function

2010-05-20 Thread Al
On 5/20/2010 11:23 AM, David Otton wrote: On 20 May 2010 15:52, Aln...@ridersite.org wrote: I agree blacklisting is a flawed approach in general. My approach is to strictly confine entry text to a whitelist of benign, acceptable tags. The But that's not what you've done. You've

Re: [PHP] Question about a security function

2010-05-20 Thread Ashley Sheridan
On Thu, 2010-05-20 at 11:51 -0400, Al wrote: On 5/20/2010 11:23 AM, David Otton wrote: On 20 May 2010 15:52, Aln...@ridersite.org wrote: I agree blacklisting is a flawed approach in general. My approach is to strictly confine entry text to a whitelist of benign, acceptable tags. The

Re: [PHP] Question about a security function

2010-05-20 Thread Jim Lucas
Al wrote: On 5/20/2010 11:23 AM, David Otton wrote: On 20 May 2010 15:52, Aln...@ridersite.org wrote: I agree blacklisting is a flawed approach in general. My approach is to strictly confine entry text to a whitelist of benign, acceptable tags. The But that's not what you've done.

Re: [PHP] Question about a security function

2010-05-20 Thread Al
On 5/20/2010 12:02 PM, Jim Lucas wrote: Al wrote: On 5/20/2010 11:23 AM, David Otton wrote: On 20 May 2010 15:52, Aln...@ridersite.org wrote: I agree blacklisting is a flawed approach in general. My approach is to strictly confine entry text to a whitelist of benign, acceptable tags.

Re: [PHP] Question about a security function

2010-05-20 Thread Ashley Sheridan
On Thu, 2010-05-20 at 12:40 -0400, Al wrote: On 5/20/2010 12:02 PM, Jim Lucas wrote: Al wrote: On 5/20/2010 11:23 AM, David Otton wrote: On 20 May 2010 15:52, Aln...@ridersite.org wrote: I agree blacklisting is a flawed approach in general. My approach is to strictly confine

Re: [PHP] Question about a security function

2010-05-20 Thread Al
On 5/20/2010 12:43 PM, Ashley Sheridan wrote: On Thu, 2010-05-20 at 12:40 -0400, Al wrote: On 5/20/2010 12:02 PM, Jim Lucas wrote: Al wrote: On 5/20/2010 11:23 AM, David Otton wrote: On 20 May 2010 15:52, Aln...@ridersite.orgwrote: I agree blacklisting is a flawed approach in

Re: [PHP] Question about creating php files from a form

2010-05-15 Thread Lester Caine
Kevin wrote: I am having some issues with connecting to a SQLite database right now ... I'm getting the following error Fatal Error: 'sqlite_open' is an unknown function But I'm putting that on the side right now. I think the docs are still screwed up. Try sqlite3_open() instead and see if

RE: [PHP] Question about creating php files from a form

2010-05-15 Thread Lawrance Shepstone
Kevin wrote: I am having some issues with connecting to a SQLite database right now ... I'm getting the following error Fatal Error: 'sqlite_open' is an unknown function But I'm putting that on the side right now. I think the docs are still screwed up. Try sqlite3_open() instead and see if

Re: [PHP] Question about creating php files from a form

2010-05-14 Thread Ashley Sheridan
On Thu, 2010-05-13 at 23:53 -0400, Kevin wrote: Ashley Sheridan wrote: On Thu, 2010-05-13 at 23:07 -0400, Kevin wrote: Hello All, I am trying to figure out how to create files when a user submits a form ... I have seen something about '*fopen*' , is that the direction I should be

Re: [PHP] Question about creating php files from a form

2010-05-14 Thread Richard Quadling
On 14 May 2010 04:07, Kevin kevin.mailingli...@gmail.com wrote: Hello All, I am trying to figure out how to create files when a user submits a form ... I have seen something about '*fopen*' , is that the direction I should be going? Here is what I am trying to accomplish: I am creating a

RE: [PHP] Question about creating php files from a form

2010-05-14 Thread Bob McConnell
From: Kevin I am trying to figure out how to create files when a user submits a form ... I have seen something about '*fopen*' , is that the direction I should be going? Here is what I am trying to accomplish: I am creating a program to keep track of recipes for my wife. I have have

Re: [PHP] Question about creating php files from a form

2010-05-14 Thread tedd
At 11:07 PM -0400 5/13/10, Kevin wrote: Hello All, I am trying to figure out how to create files when a user submits a form ... I have seen something about '*fopen*' , is that the direction I should be going? Here is what I am trying to accomplish: I am creating a program to keep track of

Re: [PHP] Question about creating php files from a form

2010-05-14 Thread Kevin
Paul M Foster wrote: On Thu, May 13, 2010 at 11:53:54PM -0400, Kevin wrote: snip /On a side note: I am having some issues with connecting to a SQLite database right now ... I'm getting the following error Fatal Error: 'sqlite_open' is an unknown function But I'm putting that on the side

[PHP] Question about creating php files from a form

2010-05-13 Thread Kevin
Hello All, I am trying to figure out how to create files when a user submits a form ... I have seen something about '*fopen*' , is that the direction I should be going? Here is what I am trying to accomplish: I am creating a program to keep track of recipes for my wife. I have have page set

Re: [PHP] Question about creating php files from a form

2010-05-13 Thread Ashley Sheridan
On Thu, 2010-05-13 at 23:07 -0400, Kevin wrote: Hello All, I am trying to figure out how to create files when a user submits a form ... I have seen something about '*fopen*' , is that the direction I should be going? Here is what I am trying to accomplish: I am creating a program to

Re: [PHP] Question about creating php files from a form

2010-05-13 Thread Kevin
Ashley Sheridan wrote: On Thu, 2010-05-13 at 23:07 -0400, Kevin wrote: Hello All, I am trying to figure out how to create files when a user submits a form ... I have seen something about '*fopen*' , is that the direction I should be going? Here is what I am trying to accomplish: I am

Re: [PHP] Question about creating php files from a form

2010-05-13 Thread Paul M Foster
On Thu, May 13, 2010 at 11:53:54PM -0400, Kevin wrote: snip /On a side note: I am having some issues with connecting to a SQLite database right now ... I'm getting the following error Fatal Error: 'sqlite_open' is an unknown function But I'm putting that on the side right now. I think the

[PHP] Question: Farsi characters showing as jibberish

2010-04-24 Thread Parham Doustdar
Hi, I have created a PHP file, and wrote a string of Farsi letters in it. In the head section of the HTML, I put: META HTTP-EQUIV=Content-Type CONTENT=text/html; charset=UTF-8 There appears to be something wrong with Apache, or something, because no matter whether I put that string in an echo

Re: [PHP] Question: Farsi characters showing as jibberish

2010-04-24 Thread Michiel Sikma
On 24 April 2010 14:45, Parham Doustdar parha...@gmail.com wrote: Hi, I have created a PHP file, and wrote a string of Farsi letters in it. In the head section of the HTML, I put: META HTTP-EQUIV=Content-Type CONTENT=text/html; charset=UTF-8 There appears to be something wrong with

Re: [PHP] Question: Farsi characters showing as jibberish

2010-04-24 Thread Ashley Sheridan
On Sat, 2010-04-24 at 15:38 +0200, Michiel Sikma wrote: On 24 April 2010 14:45, Parham Doustdar parha...@gmail.com wrote: Hi, I have created a PHP file, and wrote a string of Farsi letters in it. In the head section of the HTML, I put: META HTTP-EQUIV=Content-Type

Re: [PHP] Question: Farsi characters showing as jibberish

2010-04-24 Thread Parham Doustdar
a...@ashleysheridan.co.uk Newsgroups: php.general To: Michiel Sikma mich...@thingmajig.org Cc: Parham Doustdar parha...@gmail.com; php-general@lists.php.net Sent: Saturday, April 24, 2010 6:16 PM Subject: Re: [PHP] Question: Farsi characters showing as jibberish On Sat, 2010-04-24 at 15:38 +0200, Michiel

Re: [PHP] Question: Farsi characters showing as jibberish

2010-04-24 Thread Ashley Sheridan
guesses aloud. :-) - Original Message - From: Ashley Sheridan a...@ashleysheridan.co.uk Newsgroups: php.general To: Michiel Sikma mich...@thingmajig.org Cc: Parham Doustdar parha...@gmail.com; php-general@lists.php.net Sent: Saturday, April 24, 2010 6:16 PM Subject: Re: [PHP

Re: [PHP] Question: Farsi characters showing as jibberish

2010-04-24 Thread Parham Doustdar
-general@lists.php.net Sent: Saturday, April 24, 2010 6:16 PM Subject: Re: [PHP] Question: Farsi characters showing as jibberish On Sat, 2010-04-24 at 15:38 +0200, Michiel Sikma wrote: On 24 April 2010 14:45, Parham Doustdar parha...@gmail.com wrote: Hi, I have created a PHP

Re: [PHP] Question: Farsi characters showing as jibberish

2010-04-24 Thread Michiel Sikma
On 24 April 2010 16:07, Parham Doustdar parha...@gmail.com wrote: Hi Ashley and Michiel, It appears it is something in Apache or my server program on Windows (I am using Uniform Server; a portable webserver from http://www.uniformserver.com). The reason I got to such a conclusion is this:

Re: [PHP] Question: Farsi characters showing as jibberish

2010-04-24 Thread Parham Doustdar
Hi, It probably did because I added the line, AddDefaultCharset UTF-8 to my .htaccess a few moments ago. :-) Michiel Sikma mich...@thingmajig.org wrote in message news:o2p6cda1ded1004240726l272f04fbmdd2fb996e2580...@mail.gmail.com... On 24 April 2010 16:07, Parham Doustdar parha...@gmail.com

[PHP] Wordpress/PHP question

2010-03-22 Thread John Tamm-Buckle
Hi all, I'm storing generated data as a post in wordpress using the wp_insert_post function, which works great. Users click a submit button and the things are saved, hurrah! However, on clicking the submit button I want to automatically navigate to the post. This has been less successful.

Re: [PHP] Wordpress/PHP question

2010-03-22 Thread Robert Cummings
John Tamm-Buckle wrote: Hi all, I'm storing generated data as a post in wordpress using the wp_insert_post function, which works great. Users click a submit button and the things are saved, hurrah! However, on clicking the submit button I want to automatically navigate to the post. This has

Re: [PHP] Wordpress/PHP question

2010-03-22 Thread Piero Steinger
On 22.03.2010 17:47, John Tamm-Buckle wrote: Hi all, I'm storing generated data as a post in wordpress using the wp_insert_post function, which works great. Users click a submit button and the things are saved, hurrah! However, on clicking the submit button I want to automatically navigate to

Re: [PHP] Wordpress/PHP question

2010-03-22 Thread tedd
At 12:59 PM -0400 3/22/10, Robert Cummings wrote: You have a space someplace... most like left after some anal coder decided it was a good idea to close all their ?php tags but didn't think about trailing space in the files :) Cheers, Rob. That may be, but I always add fiber to my coding.

Re: [PHP] Wordpress/PHP question

2010-03-22 Thread Piero Steinger
On 22.03.2010 18:45, John Tamm-Buckle wrote: Line 6 is: html xmlns=http://www.w3.org/1999/xhtml; ?php //language_attributes('xhtml'); ? Thanks, John On Mon, Mar 22, 2010 at 12:38 PM, Piero Steinger pi...@the-admins.ch mailto:pi...@the-admins.ch wrote: On 22.03.2010 17:47, John

[PHP] Question on XML/XSL/PHP/MySQL

2010-01-27 Thread Ryan Park
Hypothetically say that I have MySQL with petabytes of data. I want to use XSL as my template language. But in order to use XSL, I need to make XML filled with petabytes of data. This does not sound elaborate way to use XSL/XML; I would rather use PHP/MySQL/Smarty. Is there a way around this

Re: [PHP] Question on XML/XSL/PHP/MySQL

2010-01-27 Thread Ashley Sheridan
On Wed, 2010-01-27 at 03:31 -0800, Ryan Park wrote: Hypothetically say that I have MySQL with petabytes of data. I want to use XSL as my template language. But in order to use XSL, I need to make XML filled with petabytes of data. This does not sound elaborate way to use XSL/XML; I would

Re: [PHP] Question on XML/XSL/PHP/MySQL

2010-01-27 Thread Ryan Park
My only reason doing this because I could use XSL as my templating engine; achieve the separation of content, design, and code. But in order to use XSL I need to use XML. XML needs to big if I want to use the data from the huge MySQL database. On 1/27/2010 3:32 AM, Ashley Sheridan wrote: On

Re: [PHP] Question on XML/XSL/PHP/MySQL

2010-01-27 Thread Ashley Sheridan
On Wed, 2010-01-27 at 03:39 -0800, Ryan Park wrote: My only reason doing this because I could use XSL as my templating engine; achieve the separation of content, design, and code. But in order to use XSL I need to use XML. XML needs to big if I want to use the data from the huge MySQL

Re: [PHP] Question on XML/XSL/PHP/MySQL

2010-01-27 Thread Jay Ess
Ryan Park wrote: Hypothetically say that I have MySQL with petabytes of data. I want to use XSL as my template language. But in order to use XSL, I need to make XML filled with petabytes of data. This does not sound elaborate way to use XSL/XML; I would rather use PHP/MySQL/Smarty. Is there a

Re: [PHP] Question on XML/XSL/PHP/MySQL

2010-01-27 Thread tedd
At 3:39 AM -0800 1/27/10, Ryan Park wrote: My only reason doing this because I could use XSL as my templating engine; achieve the separation of content, design, and code. But in order to use XSL I need to use XML. XML needs to big if I want to use the data from the huge MySQL database. On

[PHP] Question about using JSON_ENCODE()

2010-01-08 Thread Anthony Papillion
I'm developing a basic webservice to compliment a mobile application I'm developing or iPhone. While I know how to encode simple variables and arrays, I'm not sure how to do what I'm needing to do. Basically, I want to encode a status message to return to the mobile client. Something like

Re: [PHP] Question about using JSON_ENCODE()

2010-01-08 Thread Ryan Sun
Yup, you put result in an array $result = array('status' = 'good'); and return encoded string return Json_Encode($result); your client will get a string '{status: good}' and you use your client tech(eg. javascrpt) to decode this string and finall get an object On Fri, Jan 8, 2010 at 3:43 PM,

Re: [PHP] Question about using JSON_ENCODE()

2010-01-08 Thread Anthony Papillion
Thank you Ruan! This is just what I was looking for! Anthony Ryan Sun ryansu...@gmail.com wrote in message news:f7f19ac21001081308r4b202d45vedaf3561536ad...@mail.gmail.com... Yup, you put result in an array $result = array('status' = 'good'); and return encoded string return

[PHP] [php] Question about jsmin-php code

2009-12-29 Thread hack988 hack988
I'm see some code from jsmin-php like follow: ?php error_reporting(E_STRICT); fwrite(STDERR, memory_get_peak_usage(true).\n); require './jsmin.php'; echo JSMin::minify(file_get_contents('ext-all-debug.js')); fwrite(STDERR, memory_get_peak_usage(true).\n); ? I have some question about code

Re: [PHP] [php] Question about jsmin-php code

2009-12-29 Thread Daniel Egeberg
On Tue, Dec 29, 2009 at 12:07, hack988 hack988 hack...@dev.htwap.com wrote: I have some question about code 1.what is E_STRICT error level mean?I'm found an explain at http://www.php.net/manual/en/errorfunc.constants.php but i don't understand which situation need this level? E_STRICT is an

Re: [PHP] Question Answer based report.

2009-12-27 Thread navneet sharma
Hi Aditya, You can store question and answer in database. if user provides correct answer increase veritable ($score) you can use switch case to generate character (like in facebook apps) Navneet. On Fri, Dec 25, 2009 at 9:41 PM, aditya shukla adityashukla1...@gmail.comwrote: Merry

[PHP] Question Answer based report.

2009-12-25 Thread aditya shukla
Merry Christmas Guys, I am trying to make a small web application which has some question and some answers for that questions.My aim is to create a report based on the questions and answers related to questions.Please suggest a way to go about the application.Should I go for a if-else or switch

[PHP] Question about includes

2009-11-24 Thread Al
I'm having an include problem on a shared host and need the answer to the following to cover a key point. I'm getting this error: Warning: include_once() [function.include]: Failed opening 'Net/SMTP.php' for inclusion include_path='.:/usr/lib/php:/usr/local/lib/php:/home1/youstart/php/') in

Re: [PHP] Question about includes

2009-11-24 Thread Brady Mitchell
On Tue, Nov 24, 2009 at 6:22 AM, Al n...@ridersite.org wrote: This bothers since the current working directory is effectively where my original script resides; is it not? If so, doesn't the include Net/SMTP.php on line 206 look for the path relative to it and not in /home1/youstart/php/? When

Re: [PHP] Question about includes

2009-11-24 Thread Al
Brady Mitchell wrote: On Tue, Nov 24, 2009 at 6:22 AM, Al n...@ridersite.org wrote: This bothers since the current working directory is effectively where my original script resides; is it not? If so, doesn't the include Net/SMTP.php on line 206 look for the path relative to it and not in

[PHP] question about smarty

2009-11-05 Thread Sudhakar
i am using smarty template engine at work place, following is the situation i already have 1 template that has already been created example = http://localhost/sites/template1.com this works fine following is the folder structure i have for smarty on xampp 1. C:\xampp\htdocs\sites\template1.com

Re: [PHP] question about smarty

2009-11-05 Thread Fernando Castillo Aparicio
sudhakarar...@gmail.com Para: php-general@lists.php.net Enviado: vie,6 noviembre, 2009 00:14 Asunto: [PHP] question about smarty i am using smarty template engine at work place, following is the situation i already have 1 template that has already been created example = http://localhost/sites

[PHP] Question: Wai-aria?

2009-09-22 Thread Parham Doustdar
Hello there, I have asked on the mailing lists that have blind users and no one seems to know about this technology (that is ironically created to help us blind folks). I was wondering if anyone here has the experience of implementing Wai-aria. Since my question is rather about Wai-aria than

Re: [PHP] Question: Wai-aria?

2009-09-22 Thread Fernando Castillo Aparicio
Ups! By mistake I didn't reply to all. Resending. Sorry. De: Parham Doustdar parha...@gmail.com Para: php-general@lists.php.net Enviado: martes, 22 de septiembre, 2009 9:41:44 Asunto: [PHP] Question: Wai-aria? Hello there, I have asked on the mailing lists

[PHP] Question: Correcting MySQL's ID colomn when removing an entry

2009-09-20 Thread Parham Doustdar
Hello there, I'm guessing that when a row in a MySQL table is removed, the ID colomns of the rows which come after that row are not changed. For example: 1 2 3 4 Now, if I want to remove the third rows, the ID colomn would be something like: 1 2 4 I was wondering if there was a way to fix it

Re: [PHP] Question: Correcting MySQL's ID colomn when removing an entry

2009-09-20 Thread Lars Torben Wilson
On Sun, 20 Sep 2009 12:07:39 +0430 Parham Doustdar parha...@gmail.com wrote: Hello there, I'm guessing that when a row in a MySQL table is removed, the ID colomns of the rows which come after that row are not changed. For example: 1 2 3 4 Now, if I want to remove the third rows, the ID

Re: [PHP] Question: Correcting MySQL's ID colomn when removing an entry

2009-09-20 Thread Ashley Sheridan
On Sun, 2009-09-20 at 01:06 -0700, Lars Torben Wilson wrote: On Sun, 20 Sep 2009 12:07:39 +0430 Parham Doustdar parha...@gmail.com wrote: Hello there, I'm guessing that when a row in a MySQL table is removed, the ID colomns of the rows which come after that row are not changed. For

Re: [PHP] Question: Correcting MySQL's ID colomn when removing an entry

2009-09-20 Thread Phpster
On Sep 20, 2009, at 3:37 AM, Parham Doustdar parha...@gmail.com wrote: Hello there, I'm guessing that when a row in a MySQL table is removed, the ID colomns of the rows which come after that row are not changed. For example: 1 2 3 4 Now, if I want to remove the third rows, the ID

Re: [PHP] Question: Correcting MySQL's ID colomn when removing an entry

2009-09-20 Thread tedd
At 12:07 PM +0430 9/20/09, Parham Doustdar wrote: Hello there, I'm guessing that when a row in a MySQL table is removed, the ID colomns of the rows which come after that row are not changed. For example: 1 2 3 4 Now, if I want to remove the third rows, the ID colomn would be something like:

Re: [PHP] Question: Correcting MySQL's ID colomn when removing an entry

2009-09-20 Thread Paul M Foster
On Sun, Sep 20, 2009 at 12:07:39PM +0430, Parham Doustdar wrote: Hello there, I'm guessing that when a row in a MySQL table is removed, the ID colomns of the rows which come after that row are not changed. For example: 1 2 3 4 Now, if I want to remove the third rows, the ID colomn

Re: [PHP] Question: Sorting through table headers?

2009-09-17 Thread Parham Doustdar
Hello there, Thanks a lot. The Javascript class worked like a charm. I'm glad I asked! :) Thanks for all the answers, everyone. I seem to have communicated my intent wrong, when it came to my algorithm, but basically, yes, it was not based on the MVC model, and yes, it did filter the SQL table,

Re: [PHP] Question: Sorting through table headers?

2009-09-14 Thread Jim Lucas
Parham Doustdar wrote: Hello there, I've been asked to create something like the tables you usually see, where the headers are actually links and when you click the links, the table gets sorted based on the header. Are there any classes that you know of that would do the job? My current idea

Re: [PHP] Question: Sorting through table headers?

2009-09-14 Thread Marcus Gna?
Jim Lucas wrote: Parham Doustdar wrote: Hello there, I've been asked to create something like the tables you usually see, where the headers are actually links and when you click the links, the table gets sorted based on the header. Are there any classes that you know of that would do the

[PHP] Question: Sorting through table headers?

2009-09-13 Thread Parham Doustdar
Hello there, I've been asked to create something like the tables you usually see, where the headers are actually links and when you click the links, the table gets sorted based on the header. Are there any classes that you know of that would do the job? My current idea is to return an array of

Re: [PHP] Question: Sorting through table headers?

2009-09-13 Thread Tommy Pham
--- On Sun, 9/13/09, Parham Doustdar parha...@gmail.com wrote: From: Parham Doustdar parha...@gmail.com Subject: [PHP] Question: Sorting through table headers? To: php-general@lists.php.net Date: Sunday, September 13, 2009, 6:55 AM Hello there, I've been asked to create something like

[PHP] Question: what are frameworks?

2009-08-09 Thread Parham Doustdar
Hi there, I've heard of frameworks, but I don't quite know what they are used for. I've done a little search on the internet, but even though I've been able to find different PHP frameworks, I'm not quite sure what they offer, or in what they differ, or why I shouldn't just use PHP as it is.

Re: [PHP] Question: what are frameworks?

2009-08-09 Thread Sancar Saran
On Sunday 09 August 2009 02:47:37 pm Parham Doustdar wrote: Hi there, I've heard of frameworks, but I don't quite know what they are used for. I've done a little search on the internet, but even though I've been able to find different PHP frameworks, I'm not quite sure what they offer, or in

Re: [PHP] Question on code profiling

2009-07-27 Thread Andrew Ballard
On Sat, Jul 25, 2009 at 1:31 AM, Daniel Kolbokolb0...@umn.edu wrote: Andrew Ballard wrote: On Thu, Jul 23, 2009 at 11:31 PM, Andrew Ballardaball...@gmail.com wrote: From what I can tell, the numbers I see in WinCacheGrind look like they are off by about a factor of 10 pretty uniformly.

Re: [PHP] Question on code profiling

2009-07-24 Thread Andrew Ballard
On Thu, Jul 23, 2009 at 11:31 PM, Andrew Ballardaball...@gmail.com wrote: From what I can tell, the numbers I see in WinCacheGrind look like they are off by about a factor of 10 pretty uniformly. Andrew Apparently the difference is indeed WinCacheGrind, as a number of other people have left

Re: [PHP] Question on code profiling

2009-07-24 Thread Daniel Kolbo
Andrew Ballard wrote: On Thu, Jul 23, 2009 at 11:31 PM, Andrew Ballardaball...@gmail.com wrote: From what I can tell, the numbers I see in WinCacheGrind look like they are off by about a factor of 10 pretty uniformly. Andrew Apparently the difference is indeed WinCacheGrind, as a number

[PHP] Question on code profiling

2009-07-23 Thread Andrew Ballard
I'm trying to profile a site on our development server to see why it takes around 4 seconds to generate a pretty basic page. I installed xdebug to use for the profiling, and now I'm really confused. Even though it takes around 4 seconds to build the entire page, the profile says that the total

Re: [PHP] Question on code profiling

2009-07-23 Thread Robert Cummings
Andrew Ballard wrote: I'm trying to profile a site on our development server to see why it takes around 4 seconds to generate a pretty basic page. I installed xdebug to use for the profiling, and now I'm really confused. Even though it takes around 4 seconds to build the entire page, the profile

Re: [PHP] Question on code profiling

2009-07-23 Thread Ben Dunlap
Nope. Basically it connects to a database to load an ACL (which at [...] I thought xdebug was supposed to be a pretty good profiler. If it calculating the time correctly, where are the other ~3.6 seconds going? One night I saw a script wait indefinitely for a response from a tanked database,

Re: [PHP] Question on code profiling

2009-07-23 Thread Andrew Ballard
On Thu, Jul 23, 2009 at 5:32 PM, Ben Dunlapbdun...@agentintellect.com wrote: I second Jonathan's suggestion; I would try calling microtime() before and after your database query, and before and after anything else that isn't strictly execution of the script. Ben I tried this where I could.

RE: [PHP] New to PHP question

2009-05-11 Thread Robert Cummings
On Wed, 2009-01-28 at 23:42 +, Ashley Sheridan wrote: I hate div'itis as well. Some people seem to think it's a big faux pas to use table tags now, when that couldn't be more wrong. Use tables for tabular data, CSS for the rest (with as few exceptions - and there are always some eh - as

[PHP] Rusu Ionut, PHP Question

2009-03-26 Thread Ionut Rusu
Hello my name is Rusu Ionut, i'm from Romania and i was wondering if you have the time to to explain to mea little situation that i encountered. So i have a class: *index *and inside this class i have declared a public array containing some classes, inside the constructor of the class i extract

RE: [PHP] Rusu Ionut, PHP Question

2009-03-26 Thread kyle.smith
*. A better approach is require_once(), or placing all the includes at the top of your scripts. Hope this helps, Kyle -Original Message- From: Ionut Rusu [mailto:johnr...@gmail.com] Sent: Thursday, March 26, 2009 10:35 AM To: php-general@lists.php.net Subject: [PHP] Rusu Ionut, PHP

[PHP] Re: Rusu Ionut, PHP Question

2009-03-26 Thread Ionut Rusu
sry to boder you again but i didnt quite understood youre answer, i got the part where to add the include files on the top of the file or with require_once statment, but i still dont understant how is it posiible to add classes to the constructor with the include statment and not trigger a nested

Re: [PHP] Re: Rusu Ionut, PHP Question

2009-03-26 Thread Jan G.B.
Erm, aren't extends what you're looking for? To accomplish the auto-loading of needed subclasses? example: ?php class FOO { static $x = 'Hello World'; } class BAR extends FOO { public $greeting = false; public function __construct() { $this-greeting = parent::$x; } }

[PHP] Question about template systems

2009-03-03 Thread Matthew Croud
Hello, First post here, I'm in the process of learning PHP , I'm digesting a few books as we speak. I'm working on a content heavy website that provides a lot of information, a template system would be great and so i've been looking at ways to create dynamic data with a static navigation

Re: [PHP] Question about template systems

2009-03-03 Thread Marcus Gnaß
Marcus Gnaß wrote: like with programming questions in general. Should have read my own post before sending! ;) Should be programming languages! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Question about template systems

2009-03-03 Thread Matthew Croud
Excellent, thanks for your help guys, you've been really helpful :) On 3 Mar 2009, at 10:20, Marcus Gnaß wrote: Matthew Croud wrote: Hello, First post here, I'm in the process of learning PHP , I'm digesting a few books as we speak. I'm working on a content heavy website that provides a

Re: [PHP] Question about template systems

2009-03-03 Thread Richard Heyes
Hi, First post here, I'm in the process of learning PHP , I'm digesting a few books as we speak. I'm working on a content heavy website that provides a lot of information, a template system would be great and so i've been looking at ways to create dynamic data with a static navigation

Re: [PHP] Question about template systems

2009-03-03 Thread Marcus Gnaß
Matthew Croud wrote: Hello, First post here, I'm in the process of learning PHP , I'm digesting a few books as we speak. I'm working on a content heavy website that provides a lot of information, a template system would be great and so i've been looking at ways to create dynamic data with a

Re: [PHP] Question about template systems

2009-03-03 Thread Paul M Foster
On Tue, Mar 03, 2009 at 09:01:06AM +, Matthew Croud wrote: Hello, First post here, I'm in the process of learning PHP , I'm digesting a few books as we speak. I'm working on a content heavy website that provides a lot of information, a template system would be great and so i've been

Re: [PHP] Question about template systems

2009-03-03 Thread Stuart
2009/3/3 Matthew Croud m...@obviousdigital.com First post here, I'm in the process of learning PHP , I'm digesting a few books as we speak. I'm working on a content heavy website that provides a lot of information, a template system would be great and so i've been looking at ways to create

Re: [PHP] Question about template systems

2009-03-03 Thread Ross McKay
On Tue, 3 Mar 2009 20:46:40 +, stuttle wrote: [...] As far as templating systems go I personally don't think they add anything to the equation unless you're working with designers who are already familiar with something. Separation of logic and content is important, abstraction away from PHP

Re: [PHP] Question about version control.. sorta..

2009-02-06 Thread Michael Kubler
I'll put in a +1 for Subversion. I use it and love it. I have the actual repository sitting on a linux box and usually use TortiseSVN to update, and commit to the repository. It's pretty easy to use, and was much easier to setup than I expected. I simply apt-get install svn, and then edited

Re: [PHP] Question about version control.. sorta..

2009-02-05 Thread TG
2008 11:40:23 -0500 Subject: [PHP] Question about version control.. sorta.. Ok.. so I know about CVS and SVN and unfortunately haven't had as much experience with them as I'd like. I've used them, but always in a really basic sense and always on systems that have already been set up. A friend

Re: [PHP] Question about version control.. sorta..

2009-02-05 Thread German Geek
Subject: [PHP] Question about version control.. sorta.. Ok.. so I know about CVS and SVN and unfortunately haven't had as much experience with them as I'd like. I've used them, but always in a really basic sense and always on systems that have already been set up. A friend recently

<    1   2   3   4   5   6   7   8   9   10   >