Re: [PHP-DB] password in md5 to connect to mysql instead of clear password

2005-02-25 Thread Jon-Eirik Pettersen
On Thu, 24 Feb 2005 02:37:01 -0800 (PST), Gael Lams [EMAIL PROTECTED] wrote: Hi all I use the classic following rows to connect to a mysql database. I always put $passsword in clear in the php connection file and I wonder whether there is a way to have it in md5 so that someone reading the

Re: [PHP-DB] How to emulate phpMyadmin for editing with checkboxes

2005-02-25 Thread John Holmes
Mahmoud Badreddine wrote: I changed my checkbox statement to looke like the following: INPUT type=checkbox name=isSelected[] value=?php $row['ID'] ? where ID is the name of the auto-incremental id of my table. This is the output I get from my post_r debug statement: [isSelected] = Array

[PHP-DB] How-to pass informational mysql messages to the browser

2005-02-25 Thread Mike Millner
Hello everyone, My PHP/mysql pages are working perfectly, the problem is users don't know if what they are doing is working. I have a system that adds and deletes tape id's from mysql via a PHP front end. I would like to pass the same success/failure messages that I would get if I performed

[PHP-DB] Re: password in md5 to connect to mysql instead of clear password

2005-02-25 Thread Unknown W. Brackets
Gael Lams, The problem is, MD5 is non-reversible. Any encryption you use that is non reversible... obviously cannot be reversed, right? If it can't be reversed, that's what you have to send for the connection - and anyone sending that will get through just fine. Here, let me explain. If you

Re: [PHP-DB] How to emulate phpMyadmin for editing with checkboxes

2005-02-25 Thread Mahmoud Badreddine
Thank you for your generous response. I am almost there, but not quite. I changed my checkbox statement to looke like the following: INPUT type=checkbox name=isSelected[] value=?php $row['ID'] ? where ID is the name of the auto-incremental id of my table. This is the output I get from my post_r

Re: [PHP-DB] password in md5 to connect to mysql instead of clear password

2005-02-25 Thread Martin Norland
Gael Lams wrote: Hi all I use the classic following rows to connect to a mysql database. I always put $passsword in clear in the php connection file and I wonder whether there is a way to have it in md5 so that someone reading the file could not use it to connect to the db. I googled a bit but

[PHP-DB] How-to pass informational mysql messages to the browser

2005-02-25 Thread Mike Millner
Hello everyone, My PHP/mysql pages are working perfectly, the problem is users don't know if what they are doing is working. I have a system that adds and deletes tape id's from mysql via a PHP front end. I would like to pass the same success/failure messages that I would get if I performed the

Re: [PHP-DB] password in md5 to connect to mysql instead of clear password

2005-02-25 Thread Micah Stevens
Nope, the login function uses cleartext. Put your connect function in a seperate file in a secure directory, and include() it to make the connection. That seems to be the way to do it, someone else may have a better idea. -Micah On Thursday 24 February 2005 02:37 am, Gael Lams wrote: Hi

Re: [PHP-DB] password in md5 to connect to mysql instead of clear password

2005-02-25 Thread graeme
Not answering your question but I'd put the connect info into a separate include file. This should then be placed in a directory that can be accessed by the Web Server but not by any other user (except root). Then when you need to establish a connection you just need to include the file.

[PHP-DB] max character size mysql can contain

2005-02-25 Thread Yemi Obembe
Hi guiz, I was just wondering if anyone has an idea the maximum size of characters(in bytes) a mysql database can contain thanx - A passion till tomorrow, Opeyemi Obembe | ng.clawz.com - Do you Yahoo!?

[PHP-DB] MySQLPHP decrypt(password)

2005-02-25 Thread moses Woldeselassie
hi all I am using password() to crypt a user password online. but how do i decrypt a user password, when user forgot his/her password? kind regards m -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP-DB] most popular places

2005-02-25 Thread Merlin
Hi there, I am trying to do a tricky task with PHP and MySQl 4.0.x There are 3 content tables where each of them contains a city_id and there is a 4th table which holds the city_id and the acording city_name Now I would like to find out the most used city names. For example: members

Re: [PHP-DB] password in md5 to connect to mysql instead of clear password

2005-02-25 Thread Robby Russell
On Thu, 2005-02-24 at 02:37 -0800, Gael Lams wrote: Hi all I use the classic following rows to connect to a mysql database. I always put $passsword in clear in the php connection file and I wonder whether there is a way to have it in md5 so that someone reading the file could not use it to

Re: [PHP-DB] max character size mysql can contain

2005-02-25 Thread dpgirago
Yemi Obembe wondered: Hi guiz, I was just wondering if anyone has an idea the maximum size of characters(in bytes) a mysql database can contain thanx * This is determined by the OS file-size limit as MyQSL stores its data in regular files. I

Re: [PHP-DB] most popular places

2005-02-25 Thread Joseph Crawford
the only way i can think of off the top of my head would not be intense as you would have to do a foreach for each of the cities such as $qry = select * from table $total = mysql_num_rows( $qry ); foreach( $cities as $city ) { // do db query such as // $qry = mysql_query(SELECT id FROM table

Re: [PHP-DB] MySQLPHP decrypt(password)

2005-02-25 Thread Martin Norland
moses Woldeselassie wrote: hi all I am using password() to crypt a user password online. but how do i decrypt a user password, when user forgot his/her password? kind regards m You don't - that's the point. You have to provide them with a way to reset their password, based on some other method

RE: [PHP-DB] most popular places

2005-02-25 Thread Bastien Koert
Use a join to get the city name Use grouping to group the most common cities select a.*, b.* from table1 a inner join table2 b on a.id = b.id [where clause] group by a.id Would need a little more data about the structure of the tables to give a more complete answer bastien From: Merlin [EMAIL

RE: [PHP-DB] How-to pass informational mysql messages to the browser

2005-02-25 Thread Bastien Koert
I like to use a js alert box to notify the users /* alert box popup confimation message function */ function confirm($msg) { echo script

Re: [PHP-DB] most popular places

2005-02-25 Thread Martin Norland
Merlin wrote: I am trying to do a tricky task with PHP and MySQl 4.0.x There are 3 content tables where each of them contains a city_id and there is a 4th table which holds the city_id and the acording city_name Now I would like to find out the most used city names. For example: members

RE: [PHP-DB] max character size mysql can contain

2005-02-25 Thread Bastien Koert
DBs can be hugeMany now are apporaching terabyte sizes...You need to learn how DBs handle the files that are used to store the data...there are fileystem size limitations bastien From: Yemi Obembe [EMAIL PROTECTED] To: php-db@lists.php.net Subject: [PHP-DB] max character size mysql can

RE: [PHP-DB] MySQLPHP decrypt(password)

2005-02-25 Thread Bastien Koert
You can't. Its an MD5 hash, not an encryption...I reset the password to a random one, and email it to the user, also flag the account to force them to change the password upon login... [code] function mail_password() { global $err_msg; //get the variables from the form if

Re: [PHP-DB] password in md5 to connect to mysql instead of clear password

2005-02-25 Thread Micah Stevens
I was just thinking that a better way to do this is with a public/private key set. Then it would be secure, but as someone else mentioned, you'd have to patch the source to make it work. -Micah On Friday 25 February 2005 07:29 am, Robby Russell wrote: On Thu, 2005-02-24 at 02:37 -0800,

Re: [PHP-DB] most popular places

2005-02-25 Thread Micah Stevens
With mysql 4.1 you could union and then subSelect maybe? I'm not super-familiar with sub selects, so this code won't likely run.. But then, you're runn 4.0x so it won't run anyway. :) select city_id, count(city_id) as num from ((select city_id from members) UNION (select city_id from

Re: [PHP-DB] password in md5 to connect to mysql instead of clear password

2005-02-25 Thread Martin Norland
[never made it to list, no idea why - been 26 hours - resending.] [ may have been since it had reply-to field before to - funny...] Gael Lams wrote: Hi all I use the classic following rows to connect to a mysql database. I always put $passsword in clear in the php connection file and I wonder

RE: [PHP-DB] password in md5 to connect to mysql instead of clear password

2005-02-25 Thread Bob Sherer
You could programmatically build the connection string in the php connection file, couldn't you? Have a line that sets a variable equal to the MD5 hashed value. Then, build the connection string, applying a call to a function that unhashes the password. That way, the password itself never

Re: [PHP-DB] MySQLPHP decrypt(password)

2005-02-25 Thread Robby Russell
On Fri, 2005-02-25 at 10:20 +, moses Woldeselassie wrote: hi all I am using password() to crypt a user password online. but how do i decrypt a user password, when user forgot his/her password? kind regards m You don't. You make them reset their password. -Robby --

RE: [PHP-DB] How-to pass informational mysql messages to the browser

2005-02-25 Thread Tyler Replogle
try if($mysql stuff her){ worked }else{ doestn't work } I don't know how to get the other info you wanted besides just finding it out before hand and see what he info is afterr you do the mydql stuff. From: Mike Millner [EMAIL PROTECTED] To: php-db@lists.php.net Subject: [PHP-DB] How-to pass

Re: [PHP-DB] password in md5 to connect to mysql instead of clear password

2005-02-25 Thread Micah Stevens
You can't unhash MD5.. it's one way only. You could encrypt something and unencrypt it later, but it's not clear what advantage you would get out of what you're saying. Perhaps I don't understand, but if you have a separate connection file, why would you need to pass a password at all?

Re: [PHP-DB] password in md5 to connect to mysql instead of clear password

2005-02-25 Thread Jason Wong
On Saturday 26 February 2005 04:16, Micah Stevens wrote: I was just thinking that a better way to do this is with a public/private key set. Then it would be secure, but as someone else mentioned, you'd have to patch the source to make it work. How would it be safer? Correct me if I'm wrong:

[PHP-DB] cancel [EMAIL PROTECTED]

2005-02-25 Thread rajarbills
This message was cancelled from within Mozilla. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php