Hello. I have one problem. This is the code: PHP Code: $category = implode(“‘, ’”,$_POST[’category’]);$category1 = ”‘”.$category.”‘”;$group = $_POST[’group’];$name = $_POST[’name’];$product = $_POST[’product’];$performance = $_POST[’performance’];$service = $_POST[’service’];$price = $_POST[’price’]; mysql_query(“INSERT INTO system VALUES (”, ’$group’, $category1, ’$product’, ’$performance’, ’$service’, ’$name’, ’$price’)”) or die(mysql_error()); echo ”Product posted successfuly”; I get this error: "Column count doesn’t match value count at row 1". I don’t know what is the problem. When i delete $category1 in query, and post ”, it works. But, i need that variable. Please, help me. Bye. View full [...]
I am trying to get a select box with optgroup to populate from a MySQL database. The problem is I can’t see how to get the WHERE clause to work. Here is an example of the code I am using. Currently it displays the optgroups correctly (these are manufacturers) but it lists all cars. How [...]
I have the posts in my message board selected via a topic ID and ordered by their datetime. Eg: Code: SELECT * FROM forum WHERE topic_id = 9 ORDER BY datetime ASC On another page I want to create a link that will point to any specific post in a topic. Eg: Code: http://www.example.com/forum/viewtopic.php?id=9#post-3 . [...]
Hi everyone…. I have a table in my database comprising of ‘yesnoquestion_id’, ‘student_id’, ‘student_answer’, ‘answer’. I need to get some information out into my webpage interface using MySQL. I need to output the number of student whose answers answers are correct to the right answer into a table that will show on the interface….. the [...]
Hello, I am new to MySQL. I have built small Inventroy database using MySQL work bench 5.2 on Windows 7 PC and forward engineered on MySQL Server. I would like to know what do I need to do in install/corporate PHP with MySQL? Does MySQL already come with PHP installed. Please give me steps to [...]
Hi Guys, I have a little problem with pulling a DATE from a database. Below is my code for the page I am trying to create. I have in the database a date – 2011-07-27 and I am trying to set the dates into an array so that I can organise dates into YEAR and [...]
Hi, I have just installed, PHP, Apache, on my WinXP Pro machine. I then went to install MySQL 4.0.21Win, which appeared to go well… Although there was no log in screen for username and password as in all the books… I went into MySQL folder and opened up winmysqladmin, the window closed and I got [...]
… for a web-based strategy game? InnoDB or MyISAM? View full post on Tycoon Talk
Hi, I have a column in my database to store a url, but the url is not quite the standard url, it’s in a form such as this: Code: $f = fopen(‘http://reunitemysite.com/scripts/amp/show.php?z=1&incl=1&ip=’.getenv(‘REMOTE_ADDR’).’&url=’.urlencode(getenv(‘HTTP_HOST’).getenv(‘REQUEST_URI’)),’r'); echo stripslashes(fread($f,100000)); fclose($f); Could I store that url in the database and will it still work? I have tried it unsuccessfully. I don’t [...]
I came accross an interesting announcement on PHP Classes this morning: The Plot to Kill PHP MySQL Extention http://www.phpclasses.org/blog/post/…Extension.html What does everyone think about this? View full post on Tycoon Talk