Re: [PHP] Difference of queries in PHP/mySQL?

2001-11-18 Thread Jason G.
Check the return value of mysql_query(). It should either evaluate to false, or true. If false, then output some error messages using mysql_error() and mysql_errno(). -JasonGarber IonZoftDotCom At 01:29 PM 11/17/2001 -0500, Jeff Lewis wrote: I am wondering if there are any difference

Re: [PHP] Quiz questions on PHP

2001-11-18 Thread Shane Wright
Hi Have a look at the PHP tests on Brainbench.com - they're of a different ilk but may be useful (I think they're still free)... [dunno about the copyright though - but it should say on the site, if nothign else it might help with some pointers] -- Shane On Sunday 18 Nov 2001 12:43 pm,

Re: [PHP] Changing var value from int to string

2001-11-18 Thread Shane Wright
Hi Nope, this is fine [not necessarily good programming practise mind, but thats a different story...] -- Shane On Sunday 18 Nov 2001 6:13 am, phantom wrote: Is there any inherit danger or taboos against changing the value of a variable from an integer to a string? example: if

Re: [PHP] Standalone PHP Application

2001-11-18 Thread Shane Wright
Hi You could have a look at the GTK+ bindings for PHP - AFAIK they let you write standalone apps. There's info on the PHP web site ( www.php.net ). -- Shane I'm looking for information on using PHP for standalone applications. Specifically, I need to create a PHP-based application that

[PHP] Error running ./configure (c++ error)

2001-11-18 Thread Roy Sigurd Karlsbakk
Hi all I try to ./configure php to run on a just-upgraded rh72 box, but it tells me c++ cannot create executables. ./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-msql \ --enable-inline-optimization --enable-ftp check... check... check... checking for c++... c++ checking

[PHP] extract() question

2001-11-18 Thread David Bernier
There is this array which I would like to convert into a series variables using the extract function: ? $oz = array( lion = courage, dorothy = kansas, scarecrow = brain tin man = heart); extract($oz); ? now, I would like to access my new variables. it is obviously easy for $lion,

php-general Digest 18 Nov 2001 21:21:48 -0000 Issue 1002

2001-11-18 Thread php-general-digest-help
php-general Digest 18 Nov 2001 21:21:48 - Issue 1002 Topics (messages 75024 through 75038): Re: What's wrong with this date ? 75024 by: Andrew Forgue 75026 by: Fred Changing var value from int to string 75025 by: phantom 75033 by: Shane Wright Re: Form's :

[PHP] PHP mail() function. Help please...

2001-11-18 Thread Anthony Ritter
I'm reading J.Meloni's tutorial on page 119 in Fast and Easy and she is explaining using the PHP mail function. There are two scripts for this example... One is the .html file which lays out the form with input boxes, a textarea box and a submit button. It is: HTML HEAD TITLE Simple Feedback

Re: [PHP] PHP mail() function. Help please...

2001-11-18 Thread Avdija A . Ahmedhodi
do you have sendmail or smtp configured properly. Yao should test that first. Try to put instad of SMTP=localhost name of some other server, taht you can connect and send mail from. - Original Message - From: Anthony Ritter [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: 19. studeni 2001

Re: [PHP] building a php based subscription site (not a porn site)

2001-11-18 Thread Joe Stump
What I usually do is set a cookie BEFORE sending them to the paypal site then on the confirm page (which they click through to after they paid) check for the cookie - if it's there then activate the account. If not then delete the account after 5 days (gives them plenty of time to bitch if they

Re: [PHP] Auto Thumbnail?

2001-11-18 Thread Joe Stump
All you need is the nifty little program called convert - I have a frontend class called convert.php at my website. Check out http://www.miester.org in the code section. BTW, this bypasses the need for compiling gd into your php compile. Also, you'll want to make sure you have convert on your

Re: [PHP] alzheimers and confused

2001-11-18 Thread Joe Stump
if(!eregi(\.jpg$,$image) || !eregi(\.jpeg$,$image)) die(ERROR: doesn't appear to be a JPeg image!); --Joe On Fri, Nov 16, 2001 at 09:45:07PM -0500, jtjohnston wrote: OK kids, I'm not 19 ... my old brain gets tired easily and my wife is complaining that I stay up too late PHPing :) Putting

Re: [PHP] Error running ./configure (c++ error)

2001-11-18 Thread David Robley
On Sun, 18 Nov 2001 23:55, Roy Sigurd Karlsbakk wrote: Hi all I try to ./configure php to run on a just-upgraded rh72 box, but it tells me c++ cannot create executables. ./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-msql \ --enable-inline-optimization --enable-ftp

Re: [PHP] Question on variable variables

2001-11-18 Thread Joe Stump
This would be the logical way to do it (as I see it): define('MY','pre_'); $a = dog; $new_var = MY.$a; $$new_var and $pre_dog are the same :) --Joe On Fri, Nov 16, 2001 at 09:47:12PM -0500, Jeff Lewis wrote: I've a question regarding variable variable I was hoping someone could help me

Re: [PHP] Standalone PHP Application

2001-11-18 Thread John Monfort
I just got it. So far, it doesn't look like it lets convert your code to a .exe code. My client's scoring logic is proprietary and I need to protect the code. __John Monfort_ _+---+_ P E P I E D E S I G N S

[PHP] add column?

2001-11-18 Thread Marts
Hi, Below is a segament of my source as you can see it Switchin is taken from the row, I need it to be taken from the column can I just change it to $mycolumn? Thanks for your help $insum = $insum + $myrow[Switchin]; $outsum = $outsum + $myrow[Switchout];

Re: [PHP] comma-formatting numbers

2001-11-18 Thread Joe Stump
Here is an example of number format: ? $foo = 10; echo number_format($foo,2); // displays 100,000.00 ? --Joe On Sat, Nov 17, 2001 at 01:45:16PM -0800, Paul Wolstenholme wrote: You can do this using the number_format function or probably sprintf. /Paul On Saturday, November 17,

Re: [PHP] PHP Backing up a Database?

2001-11-18 Thread Joe Stump
This is what you'll want to do: 0 0 * * * /path/to/mysqldump -u[username] -p[username] [database] /path/to/backup.sql Put that above in your crontab (you might want to tar/gzip it too if it's big) then download it via cron to your local box. You could also look into rsync. --Joe On Sat, Nov

Re: [PHP] extract() question

2001-11-18 Thread Joe Stump
You may want to do something like this instead: ? function my_extract($arr) { if(is_array($arr) sizeof($arr)) { while(list($key,$val) = each($arr) { $new_var = str_replace(' ','_',$key); global $$new_var; $$new_var = $val; } } } ?

Re: [PHP] PHP mail() function. Help please...

2001-11-18 Thread Anthony Ritter
Thank you! It works fine. Regards, Tony -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]

[PHP] Segmented Code/HTML VS. ECHO??

2001-11-18 Thread Brad Melendy
Hello, Other than the fact that sometimes, you just can't get raw HTML to process properly by dropping out of PHP code, what are the pros and cons of using RAW HTML or just ECHOING everything in PHP? Thanks for any insights. ..Brad -- PHP General Mailing List (http://www.php.net/) To

RE: [PHP] Segmented Code/HTML VS. ECHO??

2001-11-18 Thread Martin Towell
I think it's just a matter of taste - I haven't found any noticable differences between the two. Sometimes the code it more readable with raw html, sometimes with echos. -Original Message- From: Brad Melendy [mailto:[EMAIL PROTECTED]] Sent: Monday, November 19, 2001 11:37 AM To: [EMAIL

[PHP] Additional e-mail address in PHP script...

2001-11-18 Thread Anthony Ritter
Is there any way to add an *additional* e-mail address - a cc - besides the one that is already in the $to variable below using the following PHP script? Thanking all in advance. Tony Ritter .. ? $msg=This e-mail is being sent from www site\n;

Re: [PHP] Additional e-mail address in PHP script...

2001-11-18 Thread David Robley
On Mon, 19 Nov 2001 11:15, Martin Towell wrote: add: $mailheaders.=CC: $other_email\n; $mailheaders.=BCC: $other_email\n; should also work but I haven't managed to get blind carbon copy to work for me :( Try Bcc and Cc - note the case. -- David Robley Techno-JoaT, Web Maintainer,

Re: [PHP] Segmented Code/HTML VS. ECHO??

2001-11-18 Thread Christopher William Wesley
I _hate_ echo'n out big batches of HTML, so I never do it. I prefer to include HTML, or have a class or function write HTML. However, printing in heredoc style is very handy ... more so than sliced bread. For example: ?php $color = #FFCC00; $name = Yogi; print EOF

Re: [PHP] How to create and run background process at Win2K

2001-11-18 Thread John Monfort
You can run the application as a SERVICE. Would that do the trick? __John Monfort_ _+---+_ P E P I E D E S I G N S www.pepiedesigns.com The world is waiting, are you ready? -+___+- On Mon, 19

RE: [PHP] How to create and run background process at Win2K

2001-11-18 Thread Chris Lee
Dear John, Actually I need to generate an report which need an half an hour to complete. The MS Proxy Server time out for the long process, so I want to create the report by following method: apache/mod_php - call cgi/php - email notify end user when completed. Regards, Chris Lee

Re: [PHP] MySQL INSERT

2001-11-18 Thread David Robley
On Mon, 19 Nov 2001 14:51, Justin French wrote: Hi, I'm inserting into a table (as I've done millions of times), and I have a column called id, which is an auto incrementing, unique field. Since it's auto-increment field, I have no idea what it is at the time of insert, but I want to be

Re: [PHP] MySQL INSERT

2001-11-18 Thread Justin French
Thanks David, I've skipped off to the manual and done a bit of reading, but i'm a little confused. The user-added notes have actually clouded the issue more!! It *looks like* from what they're saying, that the number returned may not be the number that I want, if someone else inserted just

Re: [PHP] MySQL INSERT

2001-11-18 Thread David Robley
On Mon, 19 Nov 2001 15:19, Justin French wrote: Thanks David, I've skipped off to the manual and done a bit of reading, but i'm a little confused. The user-added notes have actually clouded the issue more!! It *looks like* from what they're saying, that the number returned may not be the

[PHP] Virtual Directory Support disabled

2001-11-18 Thread Mit Rowe
in phpinfo() displays Virtual Directory Support disabled what exactly is this, and where can i find documentation on it? -Mit ___ Mit Rowe (Will Mitayai Keeso Rowe) Internet Services DreamLabs/Branch Media Inc. ph:

Re: [PHP] Form's : making me sick!

2001-11-18 Thread Papp Gyozo
I just want to know how to make a form inside a form get to respond or dont make any browser errors? This is prohibited by either SGML DTDs if HTML 4.01(http://www.w3.org/TR/html4/interact/forms.html#h-17.3): !ELEMENT FORM - - (%block;|SCRIPT)+ -(FORM) -- interactive form -- and

Re: [PHP] relative paths

2001-11-18 Thread Joe Stump
An easy way to fix this common problem is this: define('BASE_INCLUDE_PATH','/var/www/includes/'); include(BASE_INCLUDE_PATH.'my_include.inc'); Just make sure to include the file with the BASE_INCLUDE_PATH define using a relative path ... ie. ? include('./init.inc'); ? --Joe On Sat,