Jump to content

help me fix it?


lannoo

Recommended Posts

i have a crimegame: www.armed.be and i want to add a new section: business.

 

so the sql is:

 

DROP TABLE IF EXISTS `bedrijven`;

CREATE TABLE `bedrijven` (

  `bedrijf` varchar(255) NOT NULL default '',

  `eigenaar` varchar(255) NOT NULL default '',

  `winst` varchar(255) NOT NULL default '',

  `prijs` varchar(255) NOT NULL default ''

) TYPE=MyISAM;

 

#

# Gegevens worden uitgevoerd voor tabel `bedrijven`

#

 

INSERT INTO `bedrijven` (`bedrijf`, `eigenaar`, `winst`, `prijs`) VALUES ('taxi','spel','0','0'),

('haven','spel','0','0'),

('vliegveld','spel','0','0'),

('nachtclub','spel','0','0'),

('kpn','spel','0','0'),

('ns','spel','0','0'),

('advocaten','spel','0','0'),

('connexxion','spel','0','0'),

('dhl','spel','0','0'),

('sixflags','spel','0','0'),

('ziekenhuis','spel','0','0'),

('essent','spel','0','0'),

('microsoft','spel','0','0'),

('wapenshop','spel','0','0');

 

 

and in my file is:

 

$winst  = mysql_query("SELECT * FROM `bedrijven` WHERE `winst`='$winst'");

$ei = mysql_query("SELECT * FROM `bedrijven` WHERE `bedrijf`='$bedrijf'");

$eig = mysql_fetch_assoc($ei);

mysql_query("UPDATE `[users]` SET `bank`=`bank`+'$winst' WHERE `login`='$eig->eigenaar'");

 

but it does nothing. how?

Link to comment
https://forums.phpfreaks.com/topic/89076-help-me-fix-it/
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.