RE: [PHP-DB] appending new entry to old entries

2002-04-18 Thread Jonathan Hilgeman
Not sure if you're asking whether you can append info onto the end of a database field without having to get the previous information, but you can. UPDATE table SET MyField=CONCAT(MyField,'Appended Text') WHERE Some_ID=5; That would update the row identified by Some_ID = 5, and append Appended

RE: [PHP-DB] page expires

2002-04-18 Thread Jonathan Hilgeman
http://php.sitecreative.com/faq.php -Original Message- From: Natividad Castro [mailto:[EMAIL PROTECTED]] Sent: Wednesday, April 17, 2002 6:12 AM To: [EMAIL PROTECTED] Subject: [PHP-DB] page expires Hi to all, I have form that users fill out and submit. What I'm trying to do is not to

[PHP-DB] PHP to Fax

2002-04-16 Thread Jonathan Hilgeman
Okay, this is a new one. I'm trying to figure out the best way to send a GIF or JPG image to a fax machine using PHP and probably some other service (since I can't think of any PHP functions that deal with faxing). #1 Now, does anyone know of a good service that I could use that would work well

RE: [PHP-DB] Saving DB Resuts to a file

2002-04-12 Thread Jonathan Hilgeman
Hi Chris, This is probably due to a permissions problem on your newsletter subdirectory. Go to the server and change the newsletter subdirectory's permissions to be 777 (leaving it that way could be a security hazard, depending on if you have important information stored in that directory or not,

RE: [PHP-DB] How to avoid: Warning: Page has Expired

2002-04-09 Thread Jonathan Hilgeman
I've addressed this problem here: http://php.sitecreative.com/faq.php - Jonathan -Original Message- From: John Hughes [mailto:[EMAIL PROTECTED]] Sent: Tuesday, April 09, 2002 12:30 AM To: [EMAIL PROTECTED] Subject: [PHP-DB] How to avoid: Warning: Page has Expired I have the first

RE: [PHP-DB] grouping by category

2002-04-04 Thread Jonathan Hilgeman
Hi Big Al, You're just running full-steam ahead into these mailing lists. :) Anyhow, as olinux pointed out, you can get everything you want in one query, but I would choose a different query (no need to GROUP BY category), and then use a multi-dimensional array to organize the data. Here's my

RE: [PHP-DB] Editing/Updating Data with Forms

2002-04-04 Thread Jonathan Hilgeman
Just look at your basic PHP tutorials like Devshed's PHP 101: http://www.devshed.com/Server_Side/PHP/PHP101 - Jonathan -Original Message- From: Evans, Josh [mailto:[EMAIL PROTECTED]] Sent: Thursday, April 04, 2002 7:31 AM To: [EMAIL PROTECTED] Subject: [PHP-DB] Editing/Updating Data

RE: [PHP-DB] need some help...

2002-04-02 Thread Jonathan Hilgeman
Thank you. Someone else exists who has the sense of mind to use single quotes. I hate looking at other people's code that has tons of \s in it. - Jonathan -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Tuesday, April 02, 2002 5:00 PM To: [EMAIL PROTECTED]

RE: [PHP-DB] int or tinyint

2002-04-01 Thread Jonathan Hilgeman
Hi Jennifer, In most cases, it's best to use int. The difference between the two is simply the range of numbers they can show. Tinyint is fine for cases where you know you'll never need more than 127 (or 255 if you tell MySQL that it is an UNSIGNED tinyint, which just means that it can't have

RE: [PHP-DB] Pop up are you sure...

2002-04-01 Thread Jonathan Hilgeman
You're so negative, Jason. :) Long answer, Dave, it wouldn't be wise to do this via Javascript. Javascript can be turned off and also varies from browser to browser (like any client-side language/scripting), so this raises an issue of reliability. You may be able to do it if you're working on an

RE: [PHP-DB] Pop up are you sure...

2002-04-01 Thread Jonathan Hilgeman
shrug I was close. :) -Original Message- From: Jason Wong [mailto:[EMAIL PROTECTED]] Sent: Monday, April 01, 2002 10:53 AM To: [EMAIL PROTECTED] Subject: Re: [PHP-DB] Pop up are you sure... On Tuesday 02 April 2002 01:30, Jonathan Hilgeman wrote: You're so negative, Jason. :) No, my

RE: [PHP-DB] Unknown column 'Test' in 'field list'

2002-03-29 Thread Jonathan Hilgeman
Even though this is solved, I should mention a method that I find to be personally easier to use when INSERTing records. Simply use the field=value method: INSERT INTO MyTable SET firstname='Joe', lastname='Bob', age=58; By doing it this way, you don't have to worry about matching up the number

RE: [PHP-DB] Insert into command - PHP

2002-03-29 Thread Jonathan Hilgeman
You can check to see if there were any insert errors by: print mysql_error(); ...after you have run the query. Give us the output and your query and we can help a bit more. - Jonathan -Original Message- From: Ethan J. Mings [mailto:[EMAIL PROTECTED]] Sent: Friday, March 29, 2002

RE: [PHP-DB] Re: displaying info in a form

2002-03-29 Thread Jonathan Hilgeman
People have already answered this question, but here are some additional tips. Always make sure you include the NAME attribute of an INPUT - otherwise it can cause some headaches when you try to get the submitted data on the next page. So: input type=text name=TrackingNum value=?php echo

RE: Re[2]: [PHP-DB] Insert into command - PHP

2002-03-29 Thread Jonathan Hilgeman
and strings that are on multiple lines AS LONG AS the value starts and ends with quotes (and the semicolon at the end). - Jonathan -Original Message- From: Ethan J. Mings [mailto:[EMAIL PROTECTED]] Sent: Friday, March 29, 2002 9:11 AM To: Jonathan Hilgeman Subject: Re[2]: [PHP-DB] Insert

RE: [PHP-DB] help with preg_replace for http://

2002-03-29 Thread Jonathan Hilgeman
Just do a while loop: while(preg_match(/string to find unconverted links/, $TextBody)) { // preg_replace here } But make sure you're not doing this on the fly every time the page is viewed. That will take up an enormous amount of resources with lots of visitors. Just convert it and

RE: [PHP-DB] include() statement hell!

2002-03-28 Thread Jonathan Hilgeman
So, maybe this is the question. Can you include a file from /main/page.php by using a path of /includes/dblib.inc? Probably not. PHP can see the whole filesystem, not just the area that is limited to your account. So, when you try to include /includes/dblib.inc it is trying to go down to the

RE: [PHP-DB] MySQL, PHPand cron

2002-03-28 Thread Jonathan Hilgeman
First create the PHP script to connect to the database and empty the table (DELETE FROM table;) as if you were going to visit the page manually every time you wanted to empty the table. This shouldn't be too hard: ? // EmptyTable.php $dbLink = mysql_connect(host,user,pass);

RE: [PHP-DB] include() statement hell!

2002-03-28 Thread Jonathan Hilgeman
functions into page.php (to rule out dblib.inc screwing things up) and still I get the error. I am truly confounded at this point. Thanks for any suggestions you have. I think I am almost out of Include Statement Hell. ;-) ...Brad Jonathan Hilgeman [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED

RE: [PHP-DB] include() statement hell!

2002-03-28 Thread Jonathan Hilgeman
screwing things up) and still I get the error. I am truly confounded at this point. Thanks for any suggestions you have. I think I am almost out of Include Statement Hell. ;-) ...Brad Jonathan Hilgeman [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... S

RE: [PHP-DB] include() statement hell!

2002-03-28 Thread Jonathan Hilgeman
to walk around the block with a sign on my back saying, I'm a %*$-ASS for letting that one get by. ;-) Thanks a ton Jonathan. It of course, works now. I think it will be a while before I make that mistake again. ...Brad Jonathan Hilgeman [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]"

RE: [PHP-DB] https post via php

2002-03-28 Thread Jonathan Hilgeman
The only way I can think of doing this is via cURL, so you'll need to either have the hosting company recompile their PHP with cURL (something any decent hosting company should do - it's not a difficult process), or have them provide an external curl module (like an .so file) so you can use the

RE: [PHP-DB] include() statement hell!

2002-03-27 Thread Jonathan Hilgeman
#1. You may want to double-check the path where you're calling it from in case you're working with subdirectories. Let's saying you access a page at www.domain.com/page.php which calls www.domain.com/includes/header.inc. Then, header.inc includes the dblib.inc file at

RE: [PHP-DB] RE: [PHP-WIN] Stange 'page-loading' effect

2002-03-18 Thread Jonathan Hilgeman
You should check your error logs after getting the server not found error. There will frequently be PHP error messages stored in there that might help discern the problem. You can also set checkpoints in your code that write out Passed this part, passed this part, etc to a temporary debugging

RE: [PHP-DB] Soft-Linking and includes

2002-03-08 Thread Jonathan Hilgeman
08, 2002 12:28 PM To: [EMAIL PROTECTED] Subject: Re: [PHP-DB] Soft-Linking and includes You must use absolute paths in includes. essentially the include will reference itself as the starting point, rather than the script you are calling it from. olinux --- Jonathan Hilgeman [EMAIL PROTECTED

[PHP-DB] Soft-Linking and includes

2002-03-07 Thread Jonathan Hilgeman
I'm on a red hat system, and I've soft-linked two directories: /www/dir1/subdir /www/dir2/subdir -- /www/dir1/subdir Now, inside subdir is a file that tries to include(../info.php); which prints out some information about the file paths and my database stuff. So there's: /www/dir1/info.php

RE: [PHP-DB] Tutorial?

2002-03-04 Thread Jonathan Hilgeman
Hi Jennifer, I'm guessing the purpose of this would be to keep people from double-clicking and submitted information twice, possibly making an application deduct payment twice or something important similar in nature. The best way I've found of accomplishing the goal of keeping people from

RE: [PHP-DB] Tutorial?

2002-03-04 Thread Jonathan Hilgeman
. If the user reloads, the query fails - trap that error and you're golden. Jonathan Hilgeman [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hi Jennifer, I'm guessing the purpose of this would be to keep people from double-clicking and submitted informati

[PHP-DB] Secure Encrypt/Decrypt Functions

2002-02-21 Thread Jonathan Hilgeman
Does anyone know of a fairly simple, but secure technique for encrypting and decrypting text? - Jonathan -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

RE: [PHP-DB] Query with numbers like 1, 3, 5..........

2002-02-07 Thread Jonathan Hilgeman
Yes, Even Numbers: SELECT * FROM table WHERE MOD(id,2) = 0; Odd Numbers: SELECT * FROM table WHERE MOD(id,2) != 0; - Jonathan -Original Message- From: Jeremy Peterson [mailto:[EMAIL PROTECTED]] Sent: Thursday, February 07, 2002 11:59 AM To: Raymond Lilleodegard; [EMAIL PROTECTED]

RE: [PHP-DB] Similar Articles or Customers also bought...

2002-01-21 Thread Jonathan Hilgeman
Technically, you should have a list of saved orders associated with a customer ID. You should be able to search the saved orders for all customer IDs that purchased the current product ID. Then, generate a giant list of all products that all those customer IDs purchased, and compile them into a

RE: [PHP-DB] Fixed Quote Marks in Inputs

2002-01-07 Thread Jonathan Hilgeman
... - Jonathan -Original Message- From: Boaz Yahav [mailto:[EMAIL PROTECTED]] Sent: Saturday, January 05, 2002 12:07 AM To: Bogdan Stancescu; Jonathan Hilgeman Cc: [EMAIL PROTECTED] Subject: RE: [PHP-DB] Fixed Quote Marks in Inputs I just read your thread and I have to say that I was intrigued

RE: [PHP-DB] How to querry two db in a single statement?

2002-01-04 Thread Jonathan Hilgeman
If the two databases are on the same server, you can use joins to select data from multiple databases. For instance: Database 1, Table A: | id | name| | 1 | George | | 2 | Mark| | 3 | Harry | Database

RE: [PHP-DB] How to querry two db in a single statement?

2002-01-04 Thread Jonathan Hilgeman
if you want to sort the results alphabetically. - Jonathan -Original Message- From: Andreas Pucko [mailto:[EMAIL PROTECTED]] Sent: Friday, January 04, 2002 9:40 AM To: Jonathan Hilgeman Subject: AW: [PHP-DB] How to querry two db in a single statement? I wrote them

[PHP-DB] Fixed Quote Marks in Inputs

2002-01-04 Thread Jonathan Hilgeman
I finally came up with a reliable solution that I can use when I'm dealing with form inputs that can contain quote marks (single or double quotes). To store quote marks, you can str_replace them with their HTML code equivalents. For single quote marks, this is #039;, and for double quote marks

RE: [PHP-DB] Fixed Quote Marks in Inputs

2002-01-04 Thread Jonathan Hilgeman
to use slashes unless you're dealing with regexes. And not everybody does it that way. - Jonathan -Original Message- From: Bogdan Stancescu [mailto:[EMAIL PROTECTED]] Sent: Friday, January 04, 2002 1:41 PM To: Jonathan Hilgeman Cc: '[EMAIL PROTECTED]' Subject: Re: [PHP-DB] Fixed Quote

RE: [PHP-DB] Fixed Quote Marks in Inputs

2002-01-04 Thread Jonathan Hilgeman
for a lot of us. - Jonathan -Original Message- From: Bogdan Stancescu [mailto:[EMAIL PROTECTED]] Sent: Friday, January 04, 2002 2:39 PM To: Jonathan Hilgeman Cc: '[EMAIL PROTECTED]' Subject: Re: [PHP-DB] Fixed Quote Marks in Inputs Oh, one more thing - maybe you don't understand what

RE: [PHP-DB] Fixed Quote Marks in Inputs

2002-01-04 Thread Jonathan Hilgeman
]] Sent: Friday, January 04, 2002 3:11 PM To: Jonathan Hilgeman Cc: '[EMAIL PROTECTED]' Subject: Re: [PHP-DB] Fixed Quote Marks in Inputs Ok, as I said before, you can store whatever you please in your database. However, please don't speak as an experienced web programmer when not longer than three

RE: [PHP-DB] Fixed Quote Marks in Inputs

2002-01-04 Thread Jonathan Hilgeman
:44 PM To: Jonathan Hilgeman Cc: '[EMAIL PROTECTED]' Subject: Re: [PHP-DB] Fixed Quote Marks in Inputs Ok, seems like I misjudged you and I apologize for that. I haven't changed my opinion about the very issue we've been discussing - only wanted to post the sentence above, just for the record

RE: [PHP-DB] finding records wiht non-null columns

2002-01-03 Thread Jonathan Hilgeman
...WHERE some_column IS NOT NULL; - Jonathan -Original Message- From: bill [mailto:[EMAIL PROTECTED]] Sent: Thursday, January 03, 2002 8:19 AM To: [EMAIL PROTECTED] Subject: [PHP-DB] finding records wiht non-null columns Is there a better query than SELECT * FROM some_database WHERE

RE: [PHP-DB] How to speed up querries in a humangous db?

2001-12-26 Thread Jonathan Hilgeman
You could always categorize parts of the data and split it into separate tables. For instance, if you have a LOT of United States countries, you can duplicate the table, but keep only the U.S. country-records in the second table, and everything else in the first table. Then, before querying the

RE: [PHP-DB] Checkboxes, PHP, and MySQL

2001-12-20 Thread Jonathan Hilgeman
It's not the checkbox's VALUE attribute that determines whether it is checked or not. If you add the empty attribute CHECKED, then the checkbox will be checked. Example: INPUT TYPE='Checkbox' NAME='VarCheck1' VALUE='Good' CHECKED INPUT TYPE='Checkbox' NAME='VarCheck2' VALUE='Good' VarCheck1

RE: [PHP-DB] Checkboxes, PHP, and MySQL

2001-12-20 Thread Jonathan Hilgeman
Or a better, more-visual way might be: ? if($result[32] == 1) $Checked = CHECKED; else $Checked = ; print INPUT TYPE='Checkbox' NAME='firstvalue' VALUE='1' $Checked; ? - Jonathan -Original Message- From: matt stewart [mailto:[EMAIL PROTECTED]] Sent: Thursday, December 20, 2001 8:45

RE: [PHP-DB] Run php page automatically

2001-12-20 Thread Jonathan Hilgeman
I usually just create a cron job for this. Create your PHP script that will delete the matching records once. Then go into cron and have it run every 10 minutes. - Jonathan -Original Message- From: Harpreet [mailto:[EMAIL PROTECTED]] Sent: Thursday, December 20, 2001 11:21 AM To: [EMAIL

[PHP-DB] RE: [mysql-support] RE: [PHP-DB] Run php page automatically

2001-12-20 Thread Jonathan Hilgeman
:[EMAIL PROTECTED]] Sent: Thursday, December 20, 2001 1:53 PM To: Jonathan Hilgeman; [EMAIL PROTECTED]; [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: RE: [mysql-support] RE: [PHP-DB] Run php page automatically I would probably recommend AGAINST running this php script from cron. I have a similar

[PHP-DB] cURL not returning anything

2001-12-14 Thread Jonathan Hilgeman
I copied one of my PHP applications to a new server that is within a firewall. The new server is running PHP 4.0.6 and cURL 7.8.1. I use cURL to connect to a gateway and process credit card transactions. In any case, if I run curl from the command line with all the required POST fields, I get an

RE: [PHP-DB] Connecting to MySQL Database

2001-12-13 Thread Jonathan Hilgeman
Can you show us the code that checks the username and password to see if they're correct? Is this a custom admin page that you created? If your page is authenticating against the mysql database, then you should know that MySQL encrypts the password and stores the encrypted password. So if

RE: [PHP-DB] Connecting to MySQL Database

2001-12-13 Thread Jonathan Hilgeman
and as you said, the password has been encrypted. Shouldn't MySQL be able to compare it against an encrypted password? Thanks for your help! Jonathan Hilgeman [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Can you show us the code that checks the

RE: [PHP-DB] inserting mysql data using php array???

2001-11-27 Thread Jonathan Hilgeman
I actually have an easy way to do INSERTs like this. First I create the array: $MyArray[field] = value; $MyArray[name] = Jonathan; $MyArray[age] = 123; $MyArray[email] = $email_address; and then I define this function somewhere in a function library: function Array2Query($dbArray) {

[PHP-DB] MySQL Can't Create UNIX socket (55)

2001-11-26 Thread Jonathan Hilgeman
I occasionally receive an error message saying that PHP was unable to create a UNIX socket (55). Anyone else have this error or know what it is? - Jonathan -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL

[PHP-DB] MySQL Restarting A LOT

2001-11-20 Thread Jonathan Hilgeman
Okay, this is beginning to bug. I have an application that uses several databases, and it restarts daily - anywhere from 1-8 times per day. This is not supposed to happen at all unless we manually restart the server. But I'm beginning to experience frequent problems with it just restarting out of

RE: [PHP-DB] MySQL Restarting A LOT

2001-11-20 Thread Jonathan Hilgeman
-Original Message- From: Matthew Loff [mailto:[EMAIL PROTECTED]] Sent: Tuesday, November 20, 2001 1:18 PM To: 'Jonathan Hilgeman'; [EMAIL PROTECTED] Subject: RE: [PHP-DB] MySQL Restarting A LOT You have the wrong list. http://www.mysql.com/documentation/lists.html -Original Message- From

RE: [PHP-DB] No Caching (Reloading Fresh Content)

2001-11-20 Thread Jonathan Hilgeman
Thanks, but I think you already sent me that link. Or maybe it was a different Chris. Either way, I couldn't get any viable answers from there. - Jonathan -Original Message- From: Boget, Chris [mailto:[EMAIL PROTECTED]] Sent: Tuesday, November 13, 2001 1:30 PM To: 'Jonathan Hilgeman

RE: [PHP-DB] Upload

2001-11-16 Thread Jonathan Hilgeman
Hola Lilian, You might want to check http://phpclasses.upperdesign.com and search for upload. - BUT - I have found it much easier and simpler to just to use my own code when doing uploads. It is really simple, since most of the work is done by the browser and the server programs. To add an

[PHP-DB] No Caching (Reloading Fresh Content)

2001-11-13 Thread Jonathan Hilgeman
How can I ensure that a specific page is never cached and ALWAYS gets processed every time it is viewed? Sometimes a viewer can hit his/her browser's Back button (such a hateful button), and get a cached version of a dynamic page. I want this page's PHP code to be executed even if the visitor

Re: [PHP-DB] No Caching (Reloading Fresh Content)

2001-11-13 Thread Jonathan Hilgeman
I read a bit of it, but it's still giving me trouble. I have the following short, test, PHP script: ? Header(Cache-control: private, no-cache); Header(Expires: Mon, 26 Jul 1997 05:00:00 GMT); # Past date Header(Pragma: no-cache); $link =

RE: [PHP-DB] sending bulk emails

2001-11-02 Thread Jonathan Hilgeman
Interesting that this should come up. The company I work for needs to send out an e-mail to 95k of their subscribers. Now, this is the first time in 2 years, so you can imagine that we'll be getting 94k of bounced e-mail addresses. So I'm writing a script that will handle sending out the e-mails

[PHP-DB] SSL and IE

2001-10-26 Thread Jonathan Hilgeman
I'm programming a credit card payment form using PHP and I have been getting some strange feedback from test groups. The groups are varied as much as possible, and it seems as though some of the ones using MSIE 5.x are having trouble connecting to the secure page while others using MSIE 5.x CAN

RE: [PHP-DB] executing system commands

2001-10-25 Thread Jonathan Hilgeman
Try to avoid system commands whenever you can and instead use PHP functions when they're available. In this case, you can use the following function mkdir: http://www.php.net/manual/en/function.mkdir.php What is the problem you're having with that system command? The most frequent problems stem

RE: [PHP-DB] Creating a file using php

2001-10-22 Thread Jonathan Hilgeman
DN has a point, though. You shouldn't rely on the mailing list, otherwise you're going to turn out to be a pretty whacked programmer who doesn't know a good portion of the available options and commands. It's a good thing to just browse through the manual from time to time. Most people on here

[PHP-DB] Re: Renaming a database name...

2001-09-19 Thread Jonathan Hilgeman
There is an excellent set of functions called dbUtils that takes care of this type of thing. You can get it from www.SiteCreative.com - Jonathan Arief Fajar Nursyamsu [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Dear All... Can I rename a database name ?

[PHP-DB] Exporting Access - MySQL with a macro

2001-09-18 Thread Jonathan Hilgeman
I've set up a MySQL datasource on a Windows machine and it works - I have tested it. I want to export a table from Access to the datasource, and I have been able to do it manually. HOWEVER, NOW I am trying to do the same thing except via a macro, and Access is giving me trouble. It keep saying

[PHP-DB] Re: NEWBIE - Needs Assistance with Joins

2001-09-17 Thread Jonathan Hilgeman
You said you get a parse error - so I'm assuming that is a PHP parse error, not an SQL error. Can you attach the entire problem file to an e-mail and send it to me, along with the exact error message? I have a feeling that it is something to do with the way you are retrieving the results in your

[PHP-DB] Re: DB design question (so maybe a little OT)

2001-09-07 Thread Jonathan Hilgeman
I'm thinking that you should get all the common fields among the different types of people: F. Name, L. Name, Address, CC Number And then create a different table containing additional information that only pertains to certain types of people. Then join them using an id. - Jonathan Alexander

Re: [PHP-DB] Warning: Page has Expired

2001-09-04 Thread Jonathan Hilgeman
Actually, if you set it to be completely blank, it seems to let the browser handle the cache. I did that and have never received a page like that since then. I researched this for about 2-3 days straight, trying everything I could find. This seems to be the best method. Every once in a while you

[PHP-DB] Re: store an array in a mysqldb

2001-08-31 Thread Jonathan Hilgeman
Yikes - not sure what everyone else is smoking. That's the hard way. I thought he was just asking if he could a variable that is an array inside a database and retrieve it later as an array. If this is the case, you can use the serialize() function to convert the array to data that can be stored

[PHP-DB] Re: resizing image in php

2001-08-31 Thread Jonathan Hilgeman
Any specific type of image? Look at the function and user comments on this PHP manual page. They have some good examples of resizing. http://www.php.net/manual/en/function.imagecopyresized.php - Jonathan Andrius Jakutis [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL

Re: [PHP-DB] Password Question

2001-08-31 Thread Jonathan Hilgeman
Don't let them change it to whatever they want - have your program/system create a new, random password and e-mail it to the user's account. Unless the malicious person has a way to intercept the e-mail - which is possible - it's kind of useless. But how else are you going to get that information

Re: [PHP-DB] Weird Problem In mysql_connect();

2001-08-31 Thread Jonathan Hilgeman
You mean you had all this inside a function? Like: function dbConnect () { $link = mysql_connect($host,$user,$pass); } ? If so, did you pass $host, $user, and $pass to the function by global-ing them like: function dbConnect () { global $host; global $user; global $pass; $link =

[PHP-DB] Re: Troubles in ODBC Land

2001-08-28 Thread Jonathan Hilgeman
; foreach($EnvVars as $Key = $Val) { putenv($Key=$Val); $HTTP_ENV_VARS[$Key] = $Val; } I can see via phpinfo() that they are getting set. Any more ideas? - Jonathan Jonathan Hilgeman [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... I'm on a FreeBSD

[PHP-DB] ODBC Woes

2001-08-28 Thread Jonathan Hilgeman
Okay, all I need to know is this: Some people say that they can only connect with: odbc_connect(DSN=Datasource;UID=username;PWD=password,,); Others say that doesn't work, and that they can only connect with: odbc_connect(Datasource,username,password); I am confused. I can use the second example

Re: [PHP-DB] ODBC Woes

2001-08-28 Thread Jonathan Hilgeman
_conenct($dsn, $uid, $pwd) Best regards, Andrew Hill Director of Technology Evangelism OpenLink Software http://www.openlinksw.com Universal Data Access Data Integration Technology Providers -Original Message- From: Jonathan Hilgeman [mailto:[EMAIL PROTECTED]] Sent: Tuesday, A

Re: [PHP-DB] ODBC Woes

2001-08-28 Thread Jonathan Hilgeman
sor_type]) } else { $do_this='http://php.net/download-docs.php'; } On Tuesday 28 August 2001 22:05, Jonathan Hilgeman wrote: Okay, all I need to know is this: Some people say that they can only connect with: odbc_connect(DSN=Datasource;UID=username;PWD=password,,); Others say that does

[PHP-DB] Re: can you help to beginner?

2001-08-23 Thread Jonathan Hilgeman
Actually, it is much better to use three tables in this case. Have the following tables: Company table: companyid and companyname Services table: serviceid and servicename Company2Services table: companyid and serviceid Let's say you have three companies: 1 Kleptos Anonymous 2 Solar Sneezers

Re: [PHP-DB] can you help to beginner?

2001-08-23 Thread Jonathan Hilgeman
Actually, He should be using three. While one company could use many services, you might also have other companies that offer the same service. So there should be 3 tables to allow a many-to-many relationship. See my e-mail response to him. - Jonathan Chris Hobbs [EMAIL PROTECTED] wrote in

[PHP-DB] FreeBSD connecting to Access database on NT/2k

2001-08-22 Thread Jonathan Hilgeman
I'm not exactly sure how to go about using PHP on a FreeBSD box to connect to an Access database on a Windows NT/2000 machine. I tried odbc_connect and just got an undefined function error. But beyond that, all I have is a URL to the database file, and a username and password. I've heard some

[PHP-DB] Re: FreeBSD connecting to Access database on NT/2k

2001-08-22 Thread Jonathan Hilgeman
Also, I should mention that I have glanced at two methods: iODBC and OpenRDA, but I'd like to know if I can use PHP's dl() function to simply load them when needed, instead of having to recompile... - Jonathan Jonathan Hilgeman [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">new

Re: [PHP-DB] Photo Album Schema

2001-08-21 Thread Jonathan Hilgeman
Well said, Justin. I still would have to go with the scheme of: /photos/$UserID/$Category (?)/$FileName - Jonathan Hilgeman www.SiteCreative.com Justin Buist [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED].. . I'm going to play Devil's advocate a little

[PHP-DB] Re: query returned Resource id #2 (quick php/mysql tutorial)

2001-08-17 Thread Jonathan Hilgeman
Hi Alex, mySQL doesn't return normal PHP values. You need to use mysql functions to convert the mySQL resulting data into an array, like so: // mySQL Table: // // field1 | field2 | stuff | // // Florida | Ferrari | George |

[PHP-DB] Re: (OT) SQL query repeats

2001-08-15 Thread Jonathan Hilgeman
If you use GROUP BY lesson.l_id after your ORDER BY lesson.l_id, you will not get any records with the same lesson.l_id value. - Jonathan Adv. Systems Design [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... hello: I have 2 tables...lesson and lesson_gle (which

[PHP-DB] Re: (OT) SQL query repeats

2001-08-15 Thread Jonathan Hilgeman
Try one of the following: 1) Move the GROUP BY between WHERE and HAVING -OR- 2)SELECT l.*,lg.* FROM lesson l LEFT JOIN lesson_gle lg ON lg.l_id=l.l_id WHERE lg.glenum LIKE 'MA%' GROUP BY l.l_id ORDER BY l.l_id - Jonathan Adv. Systems Design [EMAIL PROTECTED] wrote in message [EMAIL

[PHP-DB] Windows+GD-ed Images

2001-08-13 Thread Jonathan Hilgeman
Hi people, I have a site that is made up of a number of different images that are all created on the fly with GD. The site works fine on a stable UNIX environment, but I have tried to transfer it to a regular Windows box for development, and I am having some troubles. MOST of the images will

[PHP-DB] Resource Consumption

2001-08-13 Thread Jonathan Hilgeman
I previously posted that GD was giving me grief after a while, once I had moved the development of my site over to a Windows machine running Apache. I believe I now know why there were problems. After a while, I began receiving error messages and they would output in the middle of the image code,

[PHP-DB] Re: Warning Page Expired

2001-07-31 Thread Jonathan Hilgeman
Edit your php.ini file and find the line that starts with session.cache_limiter. Replace it so that the line says: session.cache_limiter = ; Fix for Caching Problems If you leave the value blank (the ; Fix for part is just a comment), the browsers will handle their own caching and will

[PHP-DB] Re: mysql_fetch_array

2001-07-30 Thread Jonathan Hilgeman
try just changing mysql_fetch_array to mysql_fetch_assoc Bryan [EMAIL PROTECTED] wrote in message 006801c1192c$649f6e30$272478cc@bryanspc">news:006801c1192c$649f6e30$272478cc@bryanspc... mysql_fetch_array places 2 records for each one returned (example) Array ( [0] = 56

[PHP-DB] Re: upload problem ...

2001-07-16 Thread Jonathan Hilgeman
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]... I have implemented the code even as one file but the php file just run without uploading the file to the server, though i have chmod the uploadfolder tmp as 777,, Any help.Thanks ... Jonathan Hilgeman [EMAIL PROTECTED] wrote in message

[PHP-DB] Re: upload problem ...

2001-07-13 Thread Jonathan Hilgeman
File 1 (whateverform.php): FORM ENCTYPE=multipart/form-data ACTION=fileupload-destination.php METHOD=POST INPUT TYPE='File' NAME='alfredoUpload' /FORM File 2 (fileupload-destination.php):

[PHP-DB] Re: Warning: Page has Expired

2001-07-11 Thread Jonathan Hilgeman
I had this problem, too. It seems as though when using session variables and POST forms, you get this error when trying to go back to a POSTed page. I believe I read somewhere that the error is more of a security issue - to keep others from simply going back and seeing any private data, but I'm

[PHP-DB] Re: Warning: Page has Expired

2001-07-11 Thread Jonathan Hilgeman
You can also change your form to use the GET method instead. That works without changing your php.ini file. But don't use GET methods for logging in or passing secure information. It's much more insecure than POSTing (not that POSTing variables is a 100% secure method, either)... Keith Spiller

[PHP-DB] Re: MySQL Error

2001-07-10 Thread Jonathan Hilgeman
Are you running as the admin setting it up or are you a user on the system getting the error? Vivek Misra [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Dear Experts When ever i try to run MySQL under linux it gives me following error ERROR 2002 : can't

RE: [PHP-DB] MySQL Error???

2001-06-29 Thread Jonathan Hilgeman
I CC-ed the mailing list by accident. Below is my original reply to Brian. -Original Message- From: Jonathan Hilgeman Sent: Thursday, June 28, 2001 8:14 AM To: 'Brian Grayless' Cc: PHP-DB (E-mail) Subject: RE: [PHP-DB] MySQL Error??? Hi Brian, Sounds like you have a tinyint field

RE: [PHP-DB] How do I backup my MySQL database? asks a Newbie.

2001-06-22 Thread Jonathan Hilgeman
I run different mySQL servers and frequently use them to back up the others (i.e. I'll use ServerTwo to hold a backup of ServerOne's data in case ServerOne goes down), so I wrote a few functions to help copying databases between servers for backups, and to manage databases and tables on single

RE: [PHP-DB] Connecting to MySQL

2001-06-21 Thread Jonathan Hilgeman
Sounds like either: 1) You don't have your correct username/password info in the mySQL/user table or 2) Your server is bound to an IP address or something (a frequent problem on Win machines, but it looks like you're using Linux or something) The localhost part isn't really the username that is

RE: [PHP-DB] security in PHP under Apache

2001-05-23 Thread Jonathan Hilgeman
PHP runs via Apache, so it adopts the user that Apache uses, essentially. You can use a program like sudo to allow them to run certain commands on the server. Jonathan -Original Message- From: Simon R Jones [mailto:[EMAIL PROTECTED]] Sent: Wednesday, May 23, 2001 10:31 AM To: [EMAIL

RE: [PHP-DB] web to access/excel

2001-05-22 Thread Jonathan Hilgeman
Hi Russ, Try this package: http://phpclasses.upperdesign.com/browse.html/package/237 You need to register for free to gain access, but this package is supposed to write Excel binary files. Jonathan -Original Message- From: Russ Michell [mailto:[EMAIL PROTECTED]] Sent: Tuesday, May 22,

[PHP-DB] PHP5 is NOT out yet, but 4.0.5 IS!

2001-05-01 Thread Jonathan Hilgeman
1) Check out the new 4.0.5 version of PHP. 2) Some of the functions in the documentation now say Feature added in 4.0.6 but I don't see that version available yet, since 4.0.5 was just released. Does that just mean they are enticing us or something? -Original Message- From: B. van

RE: [PHP-DB] Variable passing

2001-04-24 Thread Jonathan Hilgeman
(print PassHidden...) before each of your /FORM tags, and it should work fine. -- Jonathan Hilgeman -Original Message- From: Brinzoi Constantin Aurelian [mailto:[EMAIL PROTECTED]] Sent: Tuesday, April 24, 2001 5:49 AM To: [EMAIL PROTECTED] Subject: [PHP-DB] Variable passing Hi ! Here

RE: [PHP-DB] Querying 2 databases...???

2001-04-24 Thread Jonathan Hilgeman
Why not just JOIN the tables using new columns in the sportDB? For instance, if your user names in the sportDB database and the user names in the mysql database match up, just do a JOIN ... ON sportdb.table_name.username_field = mysql.user.User You don't need two connections. Jonathan

RE: [PHP-DB] Advice On Building Dynamic MySQL Queries

2001-04-20 Thread Jonathan Hilgeman
I actually created an array of different conditions like: $ConditionsArray = array("Var1 500","Var2 1800","ID=43"); and then: $Conditions = join(" AND ", $ConditionsArray); This constructs: $Conditions = "Var1 500 AND Var2 1800 AND ID=43&qu