[PHP] php in html-- what gives?

2001-07-24 Thread CGI GUY
I'm trying to test the following: I have created a simple cookie script: I have placed it in an html page, at the very top (no spaces, lines, etc.), and have left no lines/spaces between the '?>' and '' tags. Yet the script does not execute (nor does it return an error of any kind). What gives

[PHP] html form question

2001-07-25 Thread CGI GUY
What's the method for populating any number of html form ... tags with query results? I've seen lots of php-embedded examples for CHECKBOX, RADIO and even SELECT, but I can't seem to figure out how to create a simple drop-down menu. HELP!!! __ Do Y

[PHP] dumb mysql_connect issue

2001-07-31 Thread CGI GUY
Is there anything (add. parameters, etc.) that I'm missing that would possibly explain why the following code won't execute? Thanks in advance. This mailing list rules!!! __ Do You Yahoo!? Make international calls for as low as $.04/minute with

Fwd: Re: [PHP] dumb mysql_connect issue

2001-07-31 Thread CGI GUY
and see what it tells you. > > Regards, > Philip > > > On Tue, 31 Jul 2001, CGI GUY wrote: > >> Is there anything (add. parameters, etc.) that I'm >> missing that would possibly explain why the following >> code won't execute? >> -- mike cull

[PHP] subroutines?

2001-08-07 Thread CGI GUY
How does PHP compensate for an apparent lack of traditional subroutines (as with Perl, etc.)? It seems like I'm going to have to script separate pages for ea. set of processes in my search (i.e., print FORM, print results for SEARCH, print DETAILS, etc.). Please tell me I'm mistaken! ___

Re: [PHP] Virtual Servers (apache) and php

2001-08-14 Thread CGI GUY
Wouldn't it be just to add, say, AddType application/x-httpd-php .php .php3 AddType application/x-httpd-php-source .phps or approximation within the tags? I think (fingers crossed here) that should do it... --- Jay Paulson <[EMAIL PROTECTED]> wrote: > Hello- > > I'm using the virutal

Re: [PHP] Re: inserting a remote html file

2001-08-14 Thread CGI GUY
As long as you have sendmail configured on your server, and you're working with a standard php install, it should be working properly. mail() needs to see things happen in this fashion and order: mail("[EMAIL PROTECTED]", "subject", "body", "headers") The headers are optional, and you can conca

[PHP] looong date formatting for MySQL

2001-08-17 Thread CGI GUY
There's gotta be an easier way to get create a date properly formatted for MySQL's standard -MM-DD DATE field format. Any suggestions, smacks-upside-the-head, etc. on how to reduce this would be greatly appreciated. Here's my code: It works, but sheesh...

Re: [PHP] looong date formatting for MySQL

2001-08-17 Thread CGI GUY
Thanks for the reply, however, that function call doesn't zero-substitute (i.e., "07" for "7", "03" for "3", etc.); that's why I've added this: if ($month < 10) { $month = "0"; $month .= $today['mon']; } By default, MySQL only accepts dates as -MM-DD; PHP's getdate(Y-m-d) prints out -M-D

[PHP] array_unique() and count issue

2001-08-18 Thread CGI GUY
OK, I want to count the number of unique elements in an array, then print the total. However, both methods I've tried return "1"; the man pages explain that the count() function will return 1 if the var is set but not an array. But if you look at the 2nd method esp., I've set an if-else !is_set(

[PHP] option tags and WHILE

2001-08-19 Thread CGI GUY
What's wrong with this code? I keep getting a parse error at the form/select lines... $array = mysql_fetch_array($mysql_result) or die("no go"); print (""); print (""); while ($array[1] => $array[0]) { print ("$array[1]\n"); } print (""); print (""); ?>