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

2002-03-08 Thread Indioblanco
My limited understanding of Unix hard and soft links is that /www/dir2/subdir is not a directory, it is a pointer to the inode that is pointed to by /www/dir1/subdir. I think to accomplish what you want, /www/dir2/subdir would have to be a true directory, filled with soft links to each of the

Re: [PHP-DB] Looking for a good MySQL db abstraction layer

2002-03-08 Thread Indioblanco
PEAR, Metabase, and ADODB are all good db abstraction packages with their respective merits. But if your looking for something simple, efficient, for mysql only try: http://www.phpclasses.org/browse.html/package/107.html The package contains basic connection, sql command, and recordset classes. I

[Fwd: Re: [PHP-DB] if variable is equal to 2 through 4]

2002-02-06 Thread Indioblanco
$my_array = array (2, 3, 4); if (in_array($variable, $my_array)) { echo hello; } Jay Fitzgerald wrote: i am currently using this code: if ($variable == 2) || ($variable == 3) || ($variable == 4) { echo hello; } how would I write it if I wanted to say this: if $variable

Re: [PHP-DB] Database Connection Properties

2002-01-07 Thread Indioblanco
Store the connection strings in an include file preferably outside the wed root. You can include files with a fully resolved path, or using the php include_path variable if you have access to the configuration. Alternately, if you don't have access to directories outside the webroot, put the

Re: [PHP-DB] database/form help needed

2002-01-06 Thread Indioblanco
You could setup an autoincremented unique integer field in your db table(s), then when you fetch the row from the table use the id in generating your checkbox name. -ib Chris Payne wrote: Hi there everyone, I have a loop which goes through my MySQL database and some PHP code which grabs

Re: [PHP-DB] Problem with SQL query on several tables

2001-11-27 Thread Indioblanco
It sounds to me like what you're trying to do is APPEND data from three similarly structured tables into one entity ordered by a column common to all 3 tables called datestamp. If I'm mistaken, then please ignore all of the following: Approach #1 (mysql) Create a temporary table with the

Re: [PHP-DB] Result is not empty

2001-11-22 Thread Indioblanco
yes, of course you're right-- gotta stop working so late... the use of the while statement where it wasn't needed threw me off, I guess. Paul DuBois wrote: Take out the while statement-- i.e. simply use: $row = mysql_fetch_array($result); the way you have things constructed now, the

Re: [PHP-DB] Result is not empty

2001-11-20 Thread Indioblanco
Take out the while statement-- i.e. simply use: $row = mysql_fetch_array($result); the way you have things constructed now, the while statement evaluates true on the first iteration and $row equals the result row from the query. Because the while returned true, it is evaluated a second time,

Re: [PHP-DB] (int)mysql_result?

2001-11-20 Thread Indioblanco
(int) forces (casts) result as integer-- see http://www.php.net/manual/en/language.types.type-juggling.php#language.types.typecasting SUM would be the field name -ib [EMAIL PROTECTED] wrote: What does adding the (int) do to this statement: $poll_sum = (int)mysql_result($poll_result, 0,