Re: [PHP] Stuffing code into variable

2007-02-03 Thread Albert Padley
On Feb 3, 2007, at 10:04 PM, Paul Novitski wrote: On Feb 3, 2007, at 9:09 PM, Albert Padley wrote: I have an echo statement that I use in conjunction with a MySQL query. echo "\n" . $row['time'] . "\nclass=\"tabletext\">" . $row['field

Re: [PHP] Stuffing code into variable

2007-02-03 Thread Albert Padley
On Feb 3, 2007, at 9:09 PM, Christopher Weldon wrote: On Feb 3, 2007, at 9:09 PM, Albert Padley wrote: It's late and I've been at this a long time today so I throw myself on the mercy of the list. I have an echo statement that I use in conjunction with a MySQL query. echo &

[PHP] Stuffing code into variable

2007-02-03 Thread Albert Padley
It's late and I've been at this a long time today so I throw myself on the mercy of the list. I have an echo statement that I use in conjunction with a MySQL query. echo "\n" . $row['time'] . "\nclass=\"tabletext\">" . $row['field'] . "\n\">" . $row['division'] . "\n"; This works perfectly f

Re: [PHP] Uninitialized string offset: 0

2007-01-06 Thread Albert Padley
Ah, of course. Thanks. Al On Jan 6, 2007, at 12:57 PM, Robert Cummings wrote: On Sat, 2007-01-06 at 12:43 -0700, Albert Padley wrote: Sure. $myFilter = new InputFilter('','',0,0); The first two parameters should be arrays (not strings as you have

Re: [PHP] Uninitialized string offset: 0

2007-01-06 Thread Albert Padley
Sure. $myFilter = new InputFilter('','',0,0); $_POST = $myFilter->process($_POST); BTW - for what I'm trying to do at the moment, if I change the first line to: $myFilter = new InputFilter(); it takes care of the Notice problem. Thanks. Al On Jan 6, 2007, at 12:36 PM, Dave Goodchild wrot

[PHP] Uninitialized string offset: 0

2007-01-06 Thread Albert Padley
I have the following class that generates a Notice: Uninitialized string offset: 0 each time it is called. The lines generating the notice are marked. How do I fix this? class InputFilter { var $tagsArray; var $attrArray; var $tagsMethod; var $attrMethod;

Re: [PHP] Dynamic Year Drop Down

2006-11-16 Thread Albert Padley
have the redundant value attribute in there, otherwise some Javascript things don't work right in IE. Good habit to get into.) I don't think it can really get more simple and elegant. On Thursday 16 November 2006 23:26, Albert Padley wrote: I want to build a select drop down that

Re: [PHP] Dynamic Year Drop Down

2006-11-16 Thread Albert Padley
On Nov 16, 2006, at 11:04 PM, Tom Ray [Lists] wrote: Albert Padley wrote: I want to build a select drop down that includes last year, the current year and 3 years into the future. Obviously, I could easily hard code this or use a combination of the date and mktime functions to populate

[PHP] Dynamic Year Drop Down

2006-11-16 Thread Albert Padley
I want to build a select drop down that includes last year, the current year and 3 years into the future. Obviously, I could easily hard code this or use a combination of the date and mktime functions to populate the select. However, I'm looking for a more elegant way of doing this. Thank

Re: [PHP] For Loop

2006-06-20 Thread Albert Padley
Thanks everyone. Always nice to know there is more than one direction to go in. Albert On Jun 20, 2006, at 4:52 PM, Ray Hauge wrote: On Tuesday 20 June 2006 15:28, Adam Zey wrote: Ray Hauge wrote: On Tuesday 20 June 2006 15:14, Albert Padley wrote: I have a regular for loop - for($i=1

[PHP] For Loop

2006-06-20 Thread Albert Padley
irection? Thanks. Albert Padley -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] var_dump($POST)

2006-04-12 Thread Albert Padley
On Apr 13, 2006, at 12:16 AM, William Stokes wrote: Hello, var_dump($POST) returns now always NULL. Try var_dump($_POST); Note the underline between $ and P. Al Padley -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Proper OOP Syntax

2006-02-20 Thread Albert Padley
Thank you Chris. Albert On Feb 20, 2006, at 5:00 PM, Chris wrote: Albert Padley wrote: Given the following code: $password = (strlen($this->user_pw) < 32) ? md5($this->user_pw) : $this->user_pw; $sql = sprintf("SELECT COUNT(*) AS test, TeamID FROM % s WH

[PHP] Proper OOP Syntax

2006-02-20 Thread Albert Padley
} How would I set a session variable for the value of TeamID? Thanks. Albert Padley -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Unique Names for Variable in Loop

2006-02-02 Thread Albert Padley
Yes, that's it. Thanks for the "swift kick". AP On Feb 2, 2006, at 12:37 PM, Jim Moseby wrote: I must be brain dead today since I can't get my syntax correct. Simple MySQL query to return a list of last_name. No problem. Each last name returned needs to be assigned to a unique variable like

[PHP] Unique Names for Variable in Loop

2006-02-02 Thread Albert Padley
I must be brain dead today since I can't get my syntax correct. Simple MySQL query to return a list of last_name. No problem. Each last name returned needs to be assigned to a unique variable like name1, name2, name3, etc. Somebody just kick me in the right direction. Thanks. Al Padley -

[PHP] Re: [SPAM] - [PHP] Nested IFs Problem - Bayesian Filter detected spam

2005-08-31 Thread Albert Padley
Justin & Jordan, Thanks. The && was what I needed. Albert Padley On Aug 31, 2005, at 2:27 PM, Justin Francis wrote: Albert Padley wrote: I have the following nested ifs: if ($row['date'] < '2005-10-02') { if ($row['time'] < &#x

[PHP] Nested IFs Problem

2005-08-31 Thread Albert Padley
echo "Failed"; } Whenever the 3 if statements are true, I always get the correct "Success" to echo. However, if any or all of the if statements are false, I never get "Failed" to echo. I know it's something simple, but I just can't see it at the mome

Re: [PHP] Validating Dynamic Checkboxes

2004-08-06 Thread Albert Padley
edit checkbox before submitting this form.');<br> return false;<br> }<br> }<br> Remember that the above works insofar as it throws up the javascript alert, but then submits the form anyway. I don't see how your new function incorporates the loop to build $js

Re: [PHP] Re: Validating Dynamic Checkboxes

2004-08-06 Thread Albert Padley
On Aug 6, 2004, at 10:39 PM, Manuel Lemos wrote: Hello, On 08/07/2004 12:49 AM, Albert Padley wrote: I have a php/mysql script that returns a series of records to populate a form. The number of records returned varies from 1 to as many as 100. On the display page, each record has a checkbox to

Re: [PHP] Validating Dynamic Checkboxes

2004-08-06 Thread Albert Padley
Jason, Thanks. That seems to build the javascript string, but unfortunately the form doesn't validate. In other words, if I leave all the checkboxes unchecked the results page still is returned. Perhaps there is a problem with the javascript? Any ideas? Albert Padley On Aug 6, 2004, at 10:

[PHP] Validating Dynamic Checkboxes

2004-08-06 Thread Albert Padley
east one record before submitting this form.'); event.returnValue=false; } } This is the line I need to build dynamically: if (!(mainform.ed[0].checked || mainform.ed[1].checked)) { Any help, pointers, suggestions, etc. will be greatly appreciated. Thanks. Albert Padley -- PHP Genera

[PHP] Regex (Phone Number)

2004-07-25 Thread Albert Padley
t browsers (Windows and Mac) and the only one that throws the runtime error is IE on the Mac. All others catch the errors I am trying to trap for with no runtime errors. Can this regex be improved on or do I have to live with the idiosyncratic behavior of Mac IE? Thanks. Albert Padley

Re: [PHP] Update Multiple Records From Form

2004-05-28 Thread Albert Padley
On May 28, 2004, at 3:50 AM, Ford, Mike [LSS] wrote: On 28 May 2004 04:47, Albert Padley wrote: I feel I'm so close. I have a form with multiple database records with a checkbox to indicate which records to update set up like so: $name = "ed[" . $row['id'] . "]";

[PHP] Update Multiple Records From Form

2004-05-27 Thread Albert Padley
each($ed as $id=>$val){ $query = "UPDATE ref_events_reg SETfname = '$fname' WHERE id = '{$id}'"; I am looping through the correct records, but every field is being updated to "Array". What tweak do I need

Re: [PHP] Delete Multiple Records From Checkboxes

2004-05-26 Thread Albert Padley
On May 26, 2004, at 11:17 PM, Albert Padley wrote: On May 26, 2004, at 11:16 PM, Curt Zirzow wrote: * Thus wrote Albert Padley ([EMAIL PROTECTED]): The processing code is: if (count($del) > 0){ for ($i=0;$iI think you need to take a step back and figure out where the $del variable

Re: [PHP] Delete Multiple Records From Checkboxes

2004-05-26 Thread Albert Padley
On May 26, 2004, at 11:16 PM, Curt Zirzow wrote: * Thus wrote Albert Padley ([EMAIL PROTECTED]): The processing code is: if (count($del) > 0){ for ($i=0;$iI think you need to take a step back and figure out where the $del variable is comming from. Both solutions that have been provi

Re: [PHP] Delete Multiple Records From Checkboxes

2004-05-26 Thread Albert Padley
): Bad arguments. AP> and the following query: AP> DELETE FROM ref_events_reg WHERE id IN ('') AP> Both attempts fail to delete any records even though several records AP> are checked. AP> Where have I gone wrong? AP> Thanks. AP> Albert Padley change it to T

Re: [PHP] Delete Multiple Records From Checkboxes

2004-05-26 Thread Albert Padley
On May 26, 2004, at 8:01 PM, John W. Holmes wrote: Albert Padley wrote: I've checked the archives and several other sources, but still can't seem to make this work. I have a form with checkboxes to designate records to be deleted from the mysql database. The pertinent form cod

[PHP] Delete Multiple Records From Checkboxes

2004-05-26 Thread Albert Padley
: Bad arguments. and the following query: DELETE FROM ref_events_reg WHERE id IN ('') Both attempts fail to delete any records even though several records are checked. Where have I gone wrong? Thanks. Albert Padley -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php