[PHP-DB] MySQL JOIN problem

2003-03-11 Thread Rob Day
I'm having trouble getting the results I want. The database deals with libraries and reports they've submitted. Here are the relevant tables with the primary keys marked with a star (*): +--+ | libinfo | +--+ | lib_id* | | lib_name | | city | +

[PHP-DB] heredoc and coding standards

2003-02-03 Thread Rob Day
I try to write very clean code. However, there is one thing that always bugs me - using heredoc syntax in a function. Code in the function really should be indented (or 4 spaces for PEAR types), but, to quote the documentation, "the closing identifier must begin in the first column of the line." Th

[PHP-DB] another parse error

2003-01-23 Thread Rob Day
I keep getting the following error: Parse error: parse error in /var/www/cgi-bin/ld/lslreporting_edit/libs_by_house.php on line 8 I've included all my code below and marked line 8 with * The curios thing is that I copied and pasted the first 8 lines of code from another script, and that other s

RE: [PHP-DB] MySql Statement inside a function?

2002-10-18 Thread Rob Day
i'm certainly no expert, but here are my thoughts: the variable $tbn2 probabyl has no value inside of your function. so the query is really just "select name from". i'd suggest you pass the $tbn2 value to the function. also, it is generally a bad idea to have a echo statements in function. rather y

RE: [PHP-DB] advise needed for 'authorized only' site

2002-09-23 Thread Rob Day
I had a similar problem, but I can't promise that my solution is the best way to go about it. After the user was validated, I set a cookie. I then had all subsequent pages start with an if statement that checked for the cookie. If there was no cookie, they were sent back to the entry point. Anothe

[PHP-DB] MySQL timestamp field update problem

2002-09-11 Thread Rob Day
Hi all, I have a table in MySQL with the following field: 'time_date' timestamp(14) NOT NULL When a record is inserted into the table, NULL is inserted into the time_date field giving me a normal timestamp with the time of the INSERT. That much is fine. However, it is necessary for me to u

RE: [PHP-DB] Checkbox/mySQL issues

2002-08-15 Thread Rob Day
Stephanie, Take a look at this: Option 1 Option 2 Option 3 Look at the names of the checkboxes. If they are all the same and end with [] as above, PHP will toss them into an array. So in the script that processes the form you will have access to an array named $option_val. Hope that helps. -Rob -

RE: [PHP-DB] Recommendation needed: a php/mySQL program to batch e-mail announcements

2002-04-30 Thread Rob Day
why not just use a mailing list manager (i.e. majordomo, ezmlm, etc.)? writing a web interface for users to subscribe/unsubscribe would be no big deal. -Original Message- From: Al [mailto:[EMAIL PROTECTED]] Sent: Monday, April 29, 2002 11:37 AM To: [EMAIL PROTECTED] Subject: [PHP-DB] Reco

RE: [PHP-DB] IP Address?

2002-04-19 Thread Rob Day
Thanks, Craig. That was exactly what I was looking for! -Rob -Original Message- From: Craig Vincent [mailto:[EMAIL PROTECTED]] Sent: Friday, April 19, 2002 2:35 PM To: Rob Day; [EMAIL PROTECTED] Subject: RE: [PHP-DB] IP Address? > How can I find out the IP address of the cli

[PHP-DB] IP Address?

2002-04-19 Thread Rob Day
How can I find out the IP address of the client requesting a given php file? I know that you can use $HTTP_SERVER_VARS["REMOTE_ADDR"] in more recent versions of PHP. Unfortunately, we only have PHP3.0.14 and I don't think that this option is available in our ancient version. I also can't use serve

RE: [PHP-DB] Re: parse error

2001-12-13 Thread Rob Day
-DB] Re: parse error you haven't shut your script with the ?> before starting your HTML, near as I can figure it Rob Day wrote: > I've written a small script that processes a form from a webpage and sends > the submitted data as an HTML e-mail that has the form all filled

[PHP-DB] parse error

2001-12-13 Thread Rob Day
t;no 359Answer "yes" if you want all postings to the list to be sent to 360 a moderator for approval before distribution to the list. Any help would be greatly appreciated. Thanks! Rob Day Web Team Leader Texas State