10,940 Topics
| |
php and mysql form Hi all, how I can add values in a table to a combo box in html .. eg: the user's table has the id 1,2,3,4 and that using a query, being able to move to a combo box, to make a selection of id?. Greetings and … | |
hii..I have proplem of converting datatype from decimal to float to show it in view from table: [CODE] create table st_fees(s_no int(4) primary key,s_name varchar(50), reg_fs decimal(5,2),study_fs decimal(8,2),curr int(1)); [/CODE] and my view creation code is [CODE] create view sum_fs as select s_no ,s_name,reg_fs+study_fs as fees,curr from st_fees; [/CODE] the … | |
Dear All, I would like to generate pdf document via my php page which are based on mysql data? Any recommendation so far I have seen fpdf and tcpdf. Which one will be better or is there any better tool for it? Thank you. | |
This is what I have for a main page and form and upload code for an image. The image information is stored in a Blob field in phpMyAdmin. [CODE] <?php error_reporting(0); mysql_connect("sql5c1d.megasqlservers.com","vincastweb356440","fakepassword") or die(mysql_error()); mysql_select_db("phpmy1_vincastweb_com") or die(mysql_error()); $picture = $_FILES['image']['tmp_name']; $brand = $_POST['brand']; $year = $_POST['year']; $story = $_POST['story']; $description … | |
Im trying to write a delete function for a "path" class which has data points (lat/long). It also has notes and photos along it but each of these objects have comments that also need to be deleted. Essentially everything associated with the path. Here's my SQL attempt in the most … | |
Hi, how can I import database file (.sql) to my database in phpmyadmin and ignore or replace duplicate fields. For example, if I have news with id 5 in .sql file and my local database, I want to replace that record in local database with record in file. I tried … | |
[CODE]$sql="SELECT * FROM accounts,adminaccount WHERE accounts.emailaddress='$username' and accounts.password='$password' or adminaccount.emailaddress='$username' and adminaccount.password='$password'"; $result = mysql_query($sql); $count=mysql_num_rows($result); $row = mysql_fetch_assoc($result); $usertype = $row['usertype']; if($count==1) { $_SESSION['usertype']= $row['usertype']; $_SESSION['id'] = $row['id']; if($usertype == "admin") { header("location:indexadmin.php"); } else { header("location:indexmember.php"); } } else { header("location:index.php?page=loginfail.php"); } ?> [/CODE] I wanted it to … | |
Hi am really new with php mysql, i need help pls. I have created a email software in my server, there is a field for inserting email data info. Right now i am inserting these data one by one, but this is annoying and taking hard time. Pls help me … | |
Hello, i have some problem with this issue. i have to do display results randomly using mysql. but results don't repeat until one cycle completed. i mean there are 6 results is there.... example first displyed randomly like 2 and 6, next 3 , 4 next 1,5 (one cycle completed) … | |
Warning: mysql_fetch_array() expects parameter 1 to be resource, boolean given in C:\xampp\htdocs\Lcbo\flash_import.php on line 6 this is the error i get from this code: [CODE] require_once("Connections/LCconnect2.php"); $myquery = mysql_query("SELECT pro_brand FROM product_information ORDER BY pro_id DESC"); print "&winetitle="; while($row=mysql_fetch_array($myquery)){ //<----line 6 print $row['pro_brand']."|"; } [/CODE] is it something to do … | |
Hi everyone! i am developing an application using java and mysql as a database server. the problem is i want to change the default date format in mysql. i created a table like this; create table registration (registrationNo integer primary key, customerName varchar[50] not null, regDate DATE not null); so … | |
hi guys, i'm having an SQL Error in my CMS, somebody please have a look i get this error: "Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in C:\Program Files (x86)\VertrigoServ\www\portal\estrutura\publicidades\exibe.php on line 73" my code: <? $variables=(strtolower($_SERVER['REQUEST_METHOD'])== 'GET') ? $_GET : $_POST; foreach ($variables as $k=> … | |
Hi everyone, First of all let me just tell you that I have never done database programming myself, and this is the first time I'm setting up a MySQL database via phpMyAdmin, so I could be missing something small but I'm sure someone will know the answer, anyways... I have … | |
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')' at line 1 keep getting this error what do i do | |
Hi, I'm a bit of a noob with PHP. I am trying to retrieve information from multiple tables with the following code [CODE] <?php function check_input($id) { // Stripslashes if (get_magic_quotes_gpc()) { $id = stripslashes($id); } // Quote if not a number if (!is_numeric($id)) { $id = "'" . mysql_real_escape_string($id) … | |
I am having a bit of difficulty in getting the right value. What I want to query is, the users who expire in 7 days, for example on 4th Oct 2011, the query should display the result of that particular day only. Right now I am querying as below: select … | |
I have an html page that gets data from 'hs_hr_employee' table and lays the info in a table on a web page. Then I have another table 'rights' which gets info from 4 columns from the 'hs_hr_employee' table and stores them in columns. In addition to those 4, the 'rights' … | |
[CODE] <?php //LOAD USER $result = mysql_query("SELECT * FROM event"); while ($data = mysql_fetch_array($result)){ ?> <tr> <td><?php echo $data['event'];?></td> <td><?php echo $data['tempat'];?></td> <td><?php echo readDate($data['mulai']);?></td> <td><?php echo readDate($data['selesai']);?></td> <td> <a href="./event_manager.php?id=<?php echo $data['id']; ?>&mode=delete">Hapus</a> | <a href="./event_manager.php?id=<?php echo $data['id']; ?>&mode=edit">Edit</a> </td> </tr> <?php } ?> </table> [/CODE] Warning: mysql_fetch_array() expects … | |
Hey all, I'm new-ish at MySQL and Navicat. I'm trying to import a file with about 1.16 million records and Navicat keeps "working" (I see the timer moving) but it actually stops processing records at 850,825 records. The log shows no errors whatsoever but I know there are many more … | |
The following code is used to connect C# with mysql server connectionParam = "SERVER=" + DbServer + ";DATABASE=" + dbName + ";UID=" + uName+ ";PASSWORD=" + pass; MySqlConnection mConnection = new MySqlConnection(connectionParam ); But what will be the code, if MySql can only be accessed through HTTP Tunneling. Tunneling URL: … | |
I'm looking to create a battles, Explanation: I want to create a place on my website where users can vote on two users on a certain category, such as (example: best eyes, smartest person, etc) then other users have the option to vote, but only once, and who ever has … | |
Hi all, I have 4 (four) tables using MySql database, ie: [CODE]tb_item ( id_item, (varchar) --> PK item_name, (varchar) price, (double) ) tb_order ( id_order, (varchar) --> PK id_item, (varchar) -->FK date_order, (date) lead_time, (float) order_quantity, (double) ) tb_use ( id_use, (varchar) --> PK id_item, (varchar) -->FK date_use, (date) use_quantity, … | |
category_manager.php [CODE] <?php //LOAD USER $result = mysql_query("SELECT * FROM kategori_berita"); while ($data = mysql_fetch_array($result)){ ?> <tr> <td><?php echo $data['kategori'];?></td> <td> <a href="./category_manager.php?id=<?php echo $data['id']; ?>&mode=delete">Hapus</a> | <a href="./category_manager.php?id=<?php echo $data['id']; ?>&mode=edit">Edit</a> </td> </tr> <?php [/CODE] Warning: mysql_fetch_array() expects parameter 1 to be resource, boolean given in C:\xampp\htdocs\php_template2\category_manager.php on line … | |
Hello, I have been learning php stuff for the last few days. Recently, I have learned how to allow user registration, and I have made this simple voting code that allows people to "like" or "upvote" something on my site. The way the site is set up is there is … | |
Hi, I installed MySQL from the MySQL site. The setup procedure required me to set an username and password, which I set as X and Y respectively (say). Then when I opened the mySQL command line client, it asked for password, and after providing Y, I was allowed in. Once … | |
Hi, i am just adding the last component to my registration page, but i am having a little trouble with it. Basically my website includes a referal based system, wherebye when the user signs up they can add a referal that benefits the referal later on. The code i am … | |
Hi There, I would like to know if it's possible to use or what I could use to get the required results. The values [code] +2711 081 076 086 080 9011 6547082 9013 9039 9086 9041 +27084 substring(table,length(tbl_code),length(tbl_code))=trim(tbl_code) [/code] I have different values lengths in my MySQL table that's not … | |
hello every1 actually m new to vb.net, i have installed oracle 9i on my system and i dont knw how to connect even a simple form to my sql table in which i have two fields named first_name and last_name, the name of the table in sql is user. can … | |
Hi all. As a hobby I've been working on making a website with PHP and MySQL, both of which I am new to. I'm having some trouble with the comments system as I can't seem to be able to insert a date into the database. After the "insert", when I … | |
Hi Guys, I have imported an excel document into MySQL to tidy up and make better use of the data but I am having problems running an update. All tables used as examples below; [U]Tables[/U] asset_register phone sim team The asset_register contains the following cols; [CODE] id INT, serialNo VARCHAR, … |
The End.