Re: [PHP] Re:

2008-03-14 Thread Robert Cummings
On Sat, 2008-03-15 at 01:00 -0400, John Taylor-Johnston wrote: > Robert Cummings wrote: > > On Sat, 2008-03-15 at 00:33 -0400, John Taylor-Johnston wrote: > >> Robert, > >> > >> Array > >> ( > >> [0] => Hemmingford > >> [1] => Huntingdon > >> ) > >>> You want the follow

Re: [PHP] Re:

2008-03-14 Thread John Taylor-Johnston
Robert Cummings wrote: On Sat, 2008-03-15 at 00:33 -0400, John Taylor-Johnston wrote: Robert, Array ( [0] => Hemmingford [1] => Huntingdon ) You want the following (otherwise each checked entry overwrites the previous): How would you proceed? $sql ='insert into `database`.`table`

Re: [PHP] Re:

2008-03-14 Thread Robert Cummings
On Sat, 2008-03-15 at 00:33 -0400, John Taylor-Johnston wrote: > Robert, > > Array > ( > [0] => Hemmingford > [1] => Huntingdon > ) > > You want the following (otherwise each checked entry overwrites the > > previous): > > > > > > How would you proceed? > > $s

Re: [PHP] Re:

2008-03-14 Thread John Taylor-Johnston
Robert, Array ( [0] => Hemmingford [1] => Huntingdon ) You want the following (otherwise each checked entry overwrites the previous): How would you proceed? $sql ='insert into `database`.`table` (`Nom` ,`checkregion`) values ('John', '". ?? ."') '; I'm just guessing. -- PHP Gene

Re: [PHP] Re:

2008-03-14 Thread Robert Cummings
On Sat, 2008-03-15 at 00:18 -0400, John Taylor-Johnston wrote: > Sorry, will this work? > > $sql ='insert into `database`.`table` (`Nom` ,`checkregion`) > values ('John', '".serialise($_POST['checkregion'])."') '; Depends on what you want to do with the data. But you've certainly spelled seriali

Re: [PHP] Re:

2008-03-14 Thread John Taylor-Johnston
Sorry, will this work? $sql ='insert into `database`.`table` (`Nom` ,`checkregion`) values ('John', '".serialise($_POST['checkregion'])."') '; John Taylor-Johnston wrote: Will this do it? > $sql ='insert into `database`.`table` (`Nom` ,`checkregion`) > values ('John', '".implode(',', serial

Re: [PHP] Re:

2008-03-14 Thread John Taylor-Johnston
Will this do it? > $sql ='insert into `database`.`table` (`Nom` ,`checkregion`) > values ('John', '".implode(',', serialise($_POST['checkregion'])."') '; http://ca.php.net/manual/en/function.serialize.php Array ( [0] => Hemmingford [1] => Huntingdon ) -- PHP General Mailing List

Re: [PHP] Re:

2008-03-14 Thread John Taylor-Johnston
Ah! ok, Array ( [0] => Hemmingford [1] => Huntingdon ) How do I set up my $sql? $sql ='insert into `database`.`table` (`Nom` ,`checkregion`) values ('John', '".implode(',', $_POST['myvalues']."') '; ... Hey!! What is this? Diagnostic-Code: smtp; 550-5.7.1 mail rejected by policy. SU

Re: [PHP] Re:

2008-03-14 Thread Robert Cummings
On Fri, 2008-03-14 at 23:14 -0400, John Taylor-Johnston wrote: > $_POST["checkregion"] is supposed to be an array, no? You want the following (otherwise each checked entry overwrites the previous): Cheers, Rob. -- http://www.interjinn.com Application and Templating Framework for PHP -- PH

[PHP] Re:

2008-03-14 Thread John Taylor-Johnston
$_POST["checkregion"] is supposed to be an array, no? John Taylor-Johnston wrote: http://www.glquebec.org/English/test.php When I check "Knowlton" and "Thetford Mines" or others, only "Thetford Mines" shows up in phpinfo(). $_POST["checkregion"] only sees "Thetford Mines". What am I doing wron

[PHP] Re:

2008-03-14 Thread John Taylor-Johnston
http://www.glquebec.org/English/test.php When I check "Knowlton" and "Thetford Mines" or others, only "Thetford Mines" shows up in phpinfo(). $_POST["checkregion"] only sees "Thetford Mines". What am I doing wrong? How do I parse value checkregion? Or set this up differently? A A CREATE

[PHP]

2008-03-14 Thread John Taylor-Johnston
Am coding something. Cannot quite clear my head. I know what my SQL looks like. I just cannot see clearly to input it. What is $_POST["checkregion"] going to look like? Is it going to have all the convenient commas I will need in my SQL? Or do I have to parse God knows how many checkboxes? John

Re: [PHP] Sending multiple values from a form having same field names.

2008-03-14 Thread Eric Butera
On Fri, Mar 14, 2008 at 8:12 PM, Jim Lucas <[EMAIL PROTECTED]> wrote: > > Eric Butera wrote: > > On Fri, Mar 14, 2008 at 6:02 AM, Zoltán Németh <[EMAIL PROTECTED]> wrote: > >> 2008. 03. 14, péntek keltezéssel 14.08-kor Suamya Srivastava ezt írta: > >> > >>> Hi, > >> > > >> > How can I send

Re: [PHP] Sending multiple values from a form having same field names.

2008-03-14 Thread Jim Lucas
Eric Butera wrote: On Fri, Mar 14, 2008 at 6:02 AM, Zoltán Németh <[EMAIL PROTECTED]> wrote: 2008. 03. 14, péntek keltezéssel 14.08-kor Suamya Srivastava ezt írta: Hi, > > How can I send multiple values from a form to be stored in a database, as > name of the fields is the same? > > For

Re: [PHP] Newbie ' If Statement' Question

2008-03-14 Thread Benjamin Darwin
On Fri, Mar 14, 2008 at 7:56 PM, [EMAIL PROTECTED] < [EMAIL PROTECTED]> wrote: > Hello Folks, > > I would like to be able to wrap a 'form' inside a php 'if statement' - so > that the form will appear if the 'if condition' is met. > > - most likely I cannot have a I'm doing other things wrong al

Re: [PHP] Newbie ' If Statement' Question

2008-03-14 Thread Nathan Nobbe
On Fri, Mar 14, 2008 at 7:56 PM, [EMAIL PROTECTED] < [EMAIL PROTECTED]> wrote: > Hello Folks, > > I would like to be able to wrap a 'form' inside a php 'if statement' - so > that the form will appear if the 'if condition' is met. > > - most likely I cannot have a I'm doing other things wrong al

[PHP] Newbie ' If Statement' Question

2008-03-14 Thread [EMAIL PROTECTED]
Hello Folks, I would like to be able to wrap a 'form' inside a php 'if statement' - so that the form will appear if the 'if condition' is met. - most likely I cannot have a getField('testfield') !="") { print " ";}else {print "Non Print";} ?> -- Thanks - RevDave Cool7 @

Re: [PHP] Is this the best way?

2008-03-14 Thread Jim Lucas
Jason Pruim wrote: On Mar 14, 2008, at 5:03 PM, TG wrote: - Original Message - From: Jason Pruim <[EMAIL PROTECTED]> To: TG <[EMAIL PROTECTED]> Cc: "PHP General List" Date: Fri, 14 Mar 2008 14:56:32 -0400 Subject: Re: [PHP] Is this the best way? On Mar 14, 2008, at 1:44 PM, TG w

Re: [PHP] Is this the best way?

2008-03-14 Thread Jason Pruim
On Mar 14, 2008, at 5:40 PM, TG wrote: Then it's the other query (with the ORDER BY) that you want to look at to fix the SQL error. Don't forget to use (assuming MySQL) mysql_real_escape_string() on all variables being used in the SQL query. That'll help prevent a problem with single q

Re: [PHP] Is this the best way?

2008-03-14 Thread TG
Then it's the other query (with the ORDER BY) that you want to look at to fix the SQL error. Don't forget to use (assuming MySQL) mysql_real_escape_string() on all variables being used in the SQL query. That'll help prevent a problem with single quotes or other bad characters showing up in yo

Re: [PHP] Posting Summary for Week Ending 14 March, 2008: php-general@lists.php.net

2008-03-14 Thread Børge Holen
On Friday 14 March 2008 21:24:30 Jason Pruim wrote: > So... After this post gets sent... Does Dan have some code in here to > kill all traffic on the list for a minimum amount of time? :) no but he does some time travel. merry christmas everyone! ;D > > Happy Friday everyone! > > On Mar 14, 2008,

Re: [PHP] Is this the best way?

2008-03-14 Thread Jason Pruim
On Mar 14, 2008, at 5:03 PM, TG wrote: - Original Message - From: Jason Pruim <[EMAIL PROTECTED]> To: TG <[EMAIL PROTECTED]> Cc: "PHP General List" Date: Fri, 14 Mar 2008 14:56:32 -0400 Subject: Re: [PHP] Is this the best way? On Mar 14, 2008, at 1:44 PM, TG wrote: What error

Re: [PHP] Is this the best way?

2008-03-14 Thread TG
- Original Message - From: Jason Pruim <[EMAIL PROTECTED]> To: TG <[EMAIL PROTECTED]> Cc: "PHP General List" Date: Fri, 14 Mar 2008 14:56:32 -0400 Subject: Re: [PHP] Is this the best way? > > On Mar 14, 2008, at 1:44 PM, TG wrote: > > > > > What error are you getting? Maybe there's

[PHP] Unable to create selectable TCP socket

2008-03-14 Thread ros
Hi! I have a simple PHP script: $mbox = imap_open ("{localhost:993/imap/ssl}INBOX", "[EMAIL PROTECTED]", "123"); if(!$mbox) { echo 'Error: '.imap_last_error().''; } Script works fine from local PC, but results to error when executed at web hoster site. The error is: "Error: Unable to cr

Re: [PHP] Posting Summary for Week Ending 14 March, 2008: php-general@lists.php.net

2008-03-14 Thread Jason Pruim
So... After this post gets sent... Does Dan have some code in here to kill all traffic on the list for a minimum amount of time? :) Happy Friday everyone! On Mar 14, 2008, at 4:00 PM, PostTrack [Dan Brown] wrote: Posting Summary for PHP-General List Week Ending: Friday, 14

RE: [PHP] PHP and #if

2008-03-14 Thread Andrés Robinet
> -Original Message- > From: Eric Gorr [mailto:[EMAIL PROTECTED] > Sent: Friday, March 14, 2008 3:22 PM > To: PHP General > Subject: Re: [PHP] PHP and #if > > > On Mar 14, 2008, at 3:15 PM, Eric Gorr wrote: > > > > > On Mar 14, 2008, at 3:10 PM, Stut wrote: > > > >> On 14 Mar 2008, at 19

[PHP] Posting Summary for Week Ending 14 March, 2008: php-general@lists.php.net

2008-03-14 Thread PostTrack [Dan Brown]
Posting Summary for PHP-General List Week Ending: Friday, 14 March, 2008 Messages| Bytes | Sender ++-- 480 (100%) 799678 (100%) EVERYONE 39 (8.1%)

Re: [PHP] PHP and #if

2008-03-14 Thread Stut
On 14 Mar 2008, at 19:21, Eric Gorr wrote: On Mar 14, 2008, at 3:15 PM, Eric Gorr wrote: On Mar 14, 2008, at 3:10 PM, Stut wrote: On 14 Mar 2008, at 19:03, Eric Gorr wrote: Unfortunately, such things cannot be used to wrap functions. Erm, yes they can. Try it. Gives: Parse error: synta

Re: [PHP] PHP and #if

2008-03-14 Thread André Medeiros
OK, here's how it goes: -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] PHP and #if

2008-03-14 Thread Shawn McKenzie
Eric Gorr wrote: > > On Mar 14, 2008, at 3:15 PM, Eric Gorr wrote: > >> >> On Mar 14, 2008, at 3:10 PM, Stut wrote: >> >>> On 14 Mar 2008, at 19:03, Eric Gorr wrote: Unfortunately, such things cannot be used to wrap functions. >>> >>> Erm, yes they can. Try it. >>> >>> >> if (rand(0,1) ==

Re: [PHP] Is this the best way?

2008-03-14 Thread Jim Lucas
Jason Pruim wrote: On Mar 14, 2008, at 1:15 PM, Shawn McKenzie wrote: Dan Joseph wrote: I am attempting to add a little error checking for a very simple login system. The info is stored in a MySQL database, and I am using mysqli to connect to it. I have it working with the solution provided b

Re: [PHP] PHP and #if

2008-03-14 Thread Eric Gorr
On Mar 14, 2008, at 3:15 PM, Eric Gorr wrote: On Mar 14, 2008, at 3:10 PM, Stut wrote: On 14 Mar 2008, at 19:03, Eric Gorr wrote: Unfortunately, such things cannot be used to wrap functions. Erm, yes they can. Try it. Gives: Parse error: syntax error, unexpected T_STRING in /Users/E

Re: [PHP] PHP and #if

2008-03-14 Thread Eric Gorr
On Mar 14, 2008, at 3:10 PM, Stut wrote: On 14 Mar 2008, at 19:03, Eric Gorr wrote: Unfortunately, such things cannot be used to wrap functions. Erm, yes they can. Try it. Gives: Parse error: syntax error, unexpected T_STRING in /Users/Eric/Sites/ ifWrapping.php on line 3 -- PHP G

Re: [PHP] PHP and #if

2008-03-14 Thread Stut
On 14 Mar 2008, at 19:03, Eric Gorr wrote: Unfortunately, such things cannot be used to wrap functions. Erm, yes they can. Try it. Oh, and top-posting is evil, please don't do it. -Stut -- http://stut.net/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www

Re: [PHP] PHP and #if

2008-03-14 Thread Shawn McKenzie
Eric Gorr wrote: > Unfortunately, such things cannot be used to wrap functions. > > > > On Mar 14, 2008, at 2:38 PM, Dave Goodchild wrote: > >> in php you have a number of constructs that can be used to execute >> code (or not) based on certain conditions ie is_defined(). Not sure if >> the com

Re: [PHP] PHP and #if

2008-03-14 Thread Eric Gorr
Unfortunately, such things cannot be used to wrap functions. On Mar 14, 2008, at 2:38 PM, Dave Goodchild wrote: in php you have a number of constructs that can be used to execute code (or not) based on certain conditions ie is_defined(). Not sure if the comparison with C holds true as C is c

Re: [PHP] Is this the best way?

2008-03-14 Thread Jason Pruim
On Mar 14, 2008, at 1:44 PM, TG wrote: What error are you getting? Maybe there's some way to fix that too. The error I get without checking the row count is this: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to

Re: [PHP] PHP and #if

2008-03-14 Thread Stut
On 14 Mar 2008, at 18:34, Eric Gorr wrote: If you are talking about simply commenting code out, yes, I am aware of this...however, the #if technique is far more capable in certain situations. There are reasons why C, etc. has included the ability to comment out lines of code and also provi

Re: [PHP] PHP and #if

2008-03-14 Thread Dave Goodchild
in php you have a number of constructs that can be used to execute code (or not) based on certain conditions ie is_defined(). Not sure if the comparison with C holds true as C is compiled and PHP is interpreted. On Fri, Mar 14, 2008 at 6:34 PM, Eric Gorr <[EMAIL PROTECTED]> wrote: > If you are ta

Re: [PHP] PHP and #if

2008-03-14 Thread Eric Gorr
If you are talking about simply commenting code out, yes, I am aware of this...however, the #if technique is far more capable in certain situations. There are reasons why C, etc. has included the ability to comment out lines of code and also provide #if's. But based on your reply, I have

Re: [PHP] PHP and #if

2008-03-14 Thread Børge Holen
On Friday 14 March 2008 19:19:30 Eric Gorr wrote: > In C, etc. one can place #if's around code to determine whether or not > the compiler should pay any attention to the code. > > Is there a similar technique for PHP? > > I've not seen anything like this before and a brief search hasn't > turned up

[PHP] PHP and #if

2008-03-14 Thread Eric Gorr
In C, etc. one can place #if's around code to determine whether or not the compiler should pay any attention to the code. Is there a similar technique for PHP? I've not seen anything like this before and a brief search hasn't turned up anything either...just thought I would ask to make sure.

Re: [PHP] email issue

2008-03-14 Thread Børge Holen
On Friday 14 March 2008 18:33:13 nihilism machine wrote: > here is my simple email lib: http://pastebin.com/m4d107c01 > > any idea why in the body i have a link with an = sign that gets > replaced with a % sign? > > -e read up on urlencode -- --- Børge Holen http://www.arivene.net -- PHP Genera

Re: [PHP] storing / processing login info (newbie stuff not in tutorials)

2008-03-14 Thread tedd
At 11:38 AM -0500 3/14/08, Philip Thompson wrote: On Mar 14, 2008, at 10:15 AM, tedd wrote: At 8:01 AM -0700 3/14/08, good_times wrote: 2. i see an example where a form in a login.html submits to "authcheck.php" but authcheck.php just prints ('User not found in LDAP' or 'error occured' or 'succ

Re: [PHP] Last Friday of every month

2008-03-14 Thread tedd
At 1:03 PM -0400 3/14/08, Eric Butera wrote: On Fri, Mar 14, 2008 at 11:57 AM, tedd <[EMAIL PROTECTED]> wrote: > You were right -- here it is: > http://webbytedd.com/b1/last-friday/ Hi Tedd, Thanks for the writeup! You could streamline that a bit by using getdate() and using the r

Re: [PHP] Is this the best way?

2008-03-14 Thread TG
What error are you getting? Maybe there's some way to fix that too. Just remember that errors and notices are like pain. It usually means there's something wrong. If you're getting an error, there may be a better way of doing waht you're doing. Ideally, you should get zero results if there'

[PHP] email issue

2008-03-14 Thread nihilism machine
here is my simple email lib: http://pastebin.com/m4d107c01 any idea why in the body i have a link with an = sign that gets replaced with a % sign? -e -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Is this the best way?

2008-03-14 Thread Jason Pruim
On Mar 14, 2008, at 1:15 PM, Shawn McKenzie wrote: Dan Joseph wrote: I am attempting to add a little error checking for a very simple login system. The info is stored in a MySQL database, and I am using mysqli to connect to it. I have it working with the solution provided below, but I am

Re: [PHP] Is this the best way?

2008-03-14 Thread Jason Pruim
On Mar 14, 2008, at 1:05 PM, Eric Butera wrote: On Fri, Mar 14, 2008 at 1:02 PM, Richard Heyes <[EMAIL PROTECTED]> wrote: Yes, if it is a lack of being able to see your value using print_r or echo, then use var_dump(). Seeing the value's and printing them arn't a problem... Just a hold

Re: [PHP] Is this the best way?

2008-03-14 Thread Shawn McKenzie
Dan Joseph wrote: >> I am attempting to add a little error checking for a very simple login >> system. The info is stored in a MySQL database, and I am using mysqli >> to connect to it. I have it working with the solution provided below, >> but I am wondering if this is the right way to do it or if

Re: [PHP] Is this the best way?

2008-03-14 Thread Eric Butera
On Fri, Mar 14, 2008 at 1:02 PM, Richard Heyes <[EMAIL PROTECTED]> wrote: > > $rowcnt = mysqli_num_rows($loginResult); > > if($rowcnt !="1"){ > > echo "Auth failed"; > > die("Auth failed... Sorry"); > > > > > > > > }else{ > > while($row1 = mysqli_

Re: [PHP] How to get error context

2008-03-14 Thread It Maq
Here is the error message captured by my error handling function: mysql_connect() [function.mysql-connect]: Access denied for user 'admin'@'localhost' (using password: YES) i put a wrong password and username --- Zoltán Németh <[EMAIL PROTECTED]> wrote: > 2008. 03. 14, péntek keltezéssel 07.40-k

Re: [PHP] Last Friday of every month

2008-03-14 Thread Eric Butera
On Fri, Mar 14, 2008 at 11:57 AM, tedd <[EMAIL PROTECTED]> wrote: > At 8:17 AM -0400 3/14/08, Eric Butera wrote: > > > >Just FYI you can use the word "last friday" in strtotime. So really > >you could check and see if the max day in a month is a friday and if > >not fall back on last friday.

Re: [PHP] Is this the best way?

2008-03-14 Thread Richard Heyes
$rowcnt = mysqli_num_rows($loginResult); if($rowcnt !="1"){ echo "Auth failed"; die("Auth failed... Sorry"); }else{ while($row1 = mysqli_fetch_array($loginResult)) { $_SESSION['user'] = $row1['loginName'];

Re: [PHP] Is this the best way?

2008-03-14 Thread Jason Pruim
On Mar 14, 2008, at 12:51 PM, TG wrote: I think the first thing I'd check is why you'd have more than one row being returned. Is this a problem with some other part of the system? Bad data import? Not checking for unique users when creating them? Something like that. The userna

Re: [PHP] Is this the best way?

2008-03-14 Thread Jason Pruim
On Mar 14, 2008, at 12:45 PM, Dan Joseph wrote: I am attempting to add a little error checking for a very simple login system. The info is stored in a MySQL database, and I am using mysqli to connect to it. I have it working with the solution provided below, but I am wondering if this is the ri

Re: [PHP] Is this the best way?

2008-03-14 Thread TG
I think the first thing I'd check is why you'd have more than one row being returned. Is this a problem with some other part of the system? Bad data import? Not checking for unique users when creating them? Something like that. If you do everything you can to prevent the possibility of

Re: [PHP] Last Friday of every month

2008-03-14 Thread Philip Thompson
On Mar 14, 2008, at 11:44 AM, Philip Thompson wrote: On Mar 13, 2008, at 8:12 PM, VamVan wrote: Can you tell me how to do this ? suppose I have a date variable = '02/23/2008' i need to know if this is the last friday of february let me know. There are plenty of ways. Here's a couple:

Re: [PHP] Is this the best way?

2008-03-14 Thread Dan Joseph
> > I am attempting to add a little error checking for a very simple login > system. The info is stored in a MySQL database, and I am using mysqli > to connect to it. I have it working with the solution provided below, > but I am wondering if this is the right way to do it or if there is a > better

Re: [PHP] Last Friday of every month

2008-03-14 Thread Philip Thompson
On Mar 13, 2008, at 8:12 PM, VamVan wrote: Can you tell me how to do this ? suppose I have a date variable = '02/23/2008' i need to know if this is the last friday of february let me know. There are plenty of ways. Here's a couple: OS X: 1. Finder > Applications > iCal (or Command-spac

Re: [PHP] storing / processing login info (newbie stuff not in tutorials)

2008-03-14 Thread Philip Thompson
On Mar 14, 2008, at 10:15 AM, tedd wrote: At 8:01 AM -0700 3/14/08, good_times wrote: 1. instead of typing: $conn=ocilogon("usrname","passwrd","db"); can i save this info in a file and have my php script either include or call it when it needs to make a db connection? what would that look l

[PHP] Is this the best way?

2008-03-14 Thread Jason Pruim
Hi everyone, I am attempting to add a little error checking for a very simple login system. The info is stored in a MySQL database, and I am using mysqli to connect to it. I have it working with the solution provided below, but I am wondering if this is the right way to do it or if there is

Re: [PHP] What's wrong the __autoload()?

2008-03-14 Thread tedd
At 4:24 PM +0100 3/14/08, Aschwin Wesselius wrote: tedd wrote: At 9:19 PM -0400 3/13/08, Robert Cummings wrote: - $SJHSKJ mentions Nazis Aha, you lose. You were the first to mention Nazis. :-) Hey, at least I've learned something today. I thought he was joking about Godwin's Law and wha

Re: [PHP] Last Friday of every month

2008-03-14 Thread tedd
At 8:17 AM -0400 3/14/08, Eric Butera wrote: Just FYI you can use the word "last friday" in strtotime. So really you could check and see if the max day in a month is a friday and if not fall back on last friday. I didn't test it but I just thought I'd throw that out there. erics:~ eric$ php -

[PHP] Sendmail question

2008-03-14 Thread nihilism machine
I have a link that i want to use as the body of an html email. here is the code i use: // Notify about comments public function emailComment($Link, $ID) { $mail = new SendMail(); $mail->SetCharSet("ISO-8859-1"); $mail->from("someone", "[EMAIL PROTECTED]"

Re: [PHP] What's wrong the __autoload()?

2008-03-14 Thread Aschwin Wesselius
tedd wrote: At 9:19 PM -0400 3/13/08, Robert Cummings wrote: - $z asserts $a or claims $b - $y disagrees with $a or $b or both and responds with rebuttal $h and makes claims $c, $d, sometimes $e - $z responds with rebuttal $i and often asserts a few other things that well

Re: [PHP] storing / processing login info (newbie stuff not intutorials)

2008-03-14 Thread Shawn McKenzie
good_times wrote: > 1. instead of typing: $conn=ocilogon("usrname","passwrd","db"); > can i save this info in a file and have my php script either include or call > it when it needs to make a db connection? what would that look like? i may > want to point my app to a test db at some point & it woul

Re: [PHP] storing / processing login info (newbie stuff not in tutorials)

2008-03-14 Thread tedd
At 8:01 AM -0700 3/14/08, good_times wrote: 1. instead of typing: $conn=ocilogon("usrname","passwrd","db"); can i save this info in a file and have my php script either include or call it when it needs to make a db connection? what would that look like? i may want to point my app to a test db at

Re: [PHP] How to get error context

2008-03-14 Thread Zoltán Németh
2008. 03. 14, péntek keltezéssel 07.40-kor It Maq ezt írta: > For example "mysql_connect" reprted automatically the > error but in the manual > http://us3.php.net/manual/en/function.mysql-connect.php > all they give as information is the return: "Returns > a MySQL link identifier on success, or FA

Re: [PHP] What's wrong the __autoload()?

2008-03-14 Thread tedd
At 9:19 PM -0400 3/13/08, Robert Cummings wrote: - $z asserts $a or claims $b - $y disagrees with $a or $b or both and responds with rebuttal $h and makes claims $c, $d, sometimes $e - $z responds with rebuttal $i and often asserts a few other things that well call $f, $g

[PHP] storing / processing login info (newbie stuff not in tutorials)

2008-03-14 Thread good_times
1. instead of typing: $conn=ocilogon("usrname","passwrd","db"); can i save this info in a file and have my php script either include or call it when it needs to make a db connection? what would that look like? i may want to point my app to a test db at some point & it would be nice to only change

Re: [PHP] How to get error context

2008-03-14 Thread It Maq
For example "mysql_connect" reprted automatically the error but in the manual http://us3.php.net/manual/en/function.mysql-connect.php all they give as information is the return: "Returns a MySQL link identifier on success, or FALSE on failure.", where can i see if it throws an error, and when you

Re: [PHP] How to get error context

2008-03-14 Thread Zoltán Németh
2008. 03. 14, péntek keltezéssel 07.20-kor It Maq ezt írta: > So i'm wondering if there are some rules > that can help me know if an error will be reported > automatically or not. there is no general rule for that. you have to check the manual for each function, some of them just returns false on

Re: [PHP] How to get error context

2008-03-14 Thread It Maq
Hi, I maid the modifications you suggested. For the error context when i display it, it gives a lot of information, but not easy to understand how the array is structured. If somebody knows about a site explaining how to access the context it would be great. I also modified the error reporting to

Re: [PHP] Web host with SOAP

2008-03-14 Thread Daniel Brown
On Thu, Mar 13, 2008 at 10:53 PM, Shawn McKenzie <[EMAIL PROTECTED]> wrote: > >> > > Ooo... I want SUDO! > > ALL = NOPASSWD: ALL > > please! Which is exactly why you get the following FANTASTIC package! * No shell access * No databases * No scripting support * No

Re: [PHP] Sending multiple values from a form having same field names.

2008-03-14 Thread Eric Butera
On Fri, Mar 14, 2008 at 6:02 AM, Zoltán Németh <[EMAIL PROTECTED]> wrote: > 2008. 03. 14, péntek keltezéssel 14.08-kor Suamya Srivastava ezt írta: > > > Hi, > > > > How can I send multiple values from a form to be stored in a database, as > > name of the fields is the same? > > > > For example

Re: [PHP] Last Friday of every month

2008-03-14 Thread Eric Butera
On Thu, Mar 13, 2008 at 9:39 PM, Andrés Robinet <[EMAIL PROTECTED]> wrote: > > -Original Message- > > From: VamVan [mailto:[EMAIL PROTECTED] > > Sent: Thursday, March 13, 2008 9:13 PM > > To: php-general@lists.php.net > > Subject: [PHP] Last Friday of every month > > > > Can you tell

Re: [PHP] Sending multiple values from a form having same field names.

2008-03-14 Thread Zoltán Németh
2008. 03. 14, péntek keltezéssel 14.08-kor Suamya Srivastava ezt írta: > Hi, > > How can I send multiple values from a form to be stored in a database, as > name of the fields is the same? > > For example: > > foreach ($field_data as $field) { > > $field_name=$field["field_name"]; >

Re: [PHP] What's wrong the __autoload()?

2008-03-14 Thread Zoltán Németh
2008. 03. 14, péntek keltezéssel 08.52-kor Aschwin Wesselius ezt írta: > Robert Cummings wrote: > > It works like follows... > > > > - $z asserts $a or claims $b > > - $y disagrees with $a or $b or both and responds with rebuttal $h > > and makes claims $c, $d, sometimes $e > > -

Re: [PHP] Last Friday of every month

2008-03-14 Thread Richard Heyes
VamVan wrote: Can you tell me how to do this ? suppose I have a date variable = '02/23/2008' i need to know if this is the last friday of february Work backwards from the 28th subtracting 86400 from your Unix timestamp until you get to a Friday. Compare this with your variable. -- Rich

[PHP] Sending multiple values from a form having same field names.

2008-03-14 Thread Suamya Srivastava
Hi, How can I send multiple values from a form to be stored in a database, as name of the fields is the same? For example: "; } elseif ($datatype=="textarea") { echo ""; } echo ""; } ?> This creates a form with field names and text box or textarea box next t

Re: [PHP] Last Friday of every month

2008-03-14 Thread Aschwin Wesselius
VamVan wrote: Can you tell me how to do this ? suppose I have a date variable = '02/23/2008' i need to know if this is the last friday of february let me know. $month = 3; $year = 2008; for ($day = 31; $day >= 21; $day--) { // maximum of 7 days, but february starts at 28

Re: [PHP] What's wrong the __autoload()?

2008-03-14 Thread Aschwin Wesselius
Robert Cummings wrote: It works like follows... - $z asserts $a or claims $b - $y disagrees with $a or $b or both and responds with rebuttal $h and makes claims $c, $d, sometimes $e - $z responds with rebuttal $i and often asserts a few other things that well call $f, $g