Re: [PHP-DB] httaccess and mysql ??

2002-08-30 Thread Christian Schneider

[EMAIL PROTECTED] wrote:
 I'm trying to use htaccess/htpasswd to password protect a directory.
 Is there any way to connect it to mysql, so that it looks for user/password
 in mysql table..
 

mod_auth_mysql
http://www.cgi101.com/class/password/mod_auth_mysql.html

cheers,

:-)christian


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP-DB] drop list inserts

2002-04-18 Thread Christian Schneider

Hi Barry,

Barry Rumsey wrote:
   $query_id = mysql_query(INSERT INTO music_album VALUES
 (NULL, '$music_artist.id' ,'$album' ,NULL ,NULL));
 echo  $artist_name and $album has been added to the 
 
 Could someone please point out what I'm doing wrong?
 

is the value of $music_artist.id correct? Also, your select has the 
name of music_artist and the value of the respective id, isn't that 
what you want?


Regards,

Christian


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP-DB] to ora_bind or not to ora_bind

2002-04-03 Thread Christian Schneider

Hi,

sorry to post just after subscribing but I didn't find anything in the faqs.

I have to port an Oracle-based system to MySQL and am now investigating 
how to get rid of the Oracle specialities. I neither wrote the system 
nor do I fully understand how it's working yet, so I might miss something.

The biggest trouble spot seems to be the use of the ora_bind functions 
as in the following example:

$e = db_parse ($curs, insert into usercomments values 
.(:pkey,:pser,:pnam,:pema,:pdat,:ptxt,:psub,:pref) )

if ( ! $e ):
   $err = Error in insert statement!;
   $errn = $curs;
else:
   db_bind ($curs, param_key, :pkey, 6, 1);
   db_bind ($curs, param_ser, :pser, 16, 1);
   db_bind ($curs, param_nam, :pnam, 128, 1);
   db_bind ($curs, param_ema, :pema, 128, 1);
   db_bind ($curs, param_dat, :pdat, 64, 1);
   db_bind ($curs, param_txt, :ptxt, 1024, 1);
   db_bind ($curs, param_sub, :psub, 128, 1);
   db_bind ($curs, param_ref, :pref, 16, 1);
   if (!db_exec ($curs)):
  $err = Could not execute insert statement, sorry!;
  $errn = $curs;
   else:
   endif;
endif;

The problem is that I don't really see what the use of the ora_bind is 
here. Is there anything that would forbid the port to:

mysql_query(insert into usercomments values( $param_key, $param_ser, 
..., $param_ref));

Or am I missing something substantial here?


Thanks a lot,

Christian
-- 
Christian Schneider [EMAIL PROTECTED]

Zentrum für Angewandte Informatik --.. .- .. -.-
Universitätsweiter Service .-. .-. --.. -.-

+ Universität zu Köln + Robert-Koch-Str. 10 + D-50931 Köln
+ Tel. +49 221 478 7021 +


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php