Jump to content

adding data from sql to array


sarahAria

Recommended Posts

hi guys

I want to add usernames from mysq; database to an array like this

$existing_users=array('roshan','mike','jason');

mysql table looks like this

CREATE TABLE `Secure` (`id` int(11) NOT NULL auto_increment,`name` varchar(50) NOT NULL default '',`password` varchar(50) NOT NULL default '',`cookie_pass` varchar(50) NOT NULL default '',`state` char(1) NOT NULL default '0',`mail` varchar(100) NOT NULL default '',`active` char(1) NOT NULL default '0',`actcode` varchar(15) NOT NULL default '',`lastactive` datetime NOT NULL default '0000-00-00 00:00:00',PRIMARY KEY  (`id`)) TYPE=MyISAM AUTO_INCREMENT=1;

could yu plz help?

my problem is I don't know about arrays

Link to comment
https://forums.phpfreaks.com/topic/129839-adding-data-from-sql-to-array/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.