39,319 Topics
| |
I have the following code which results in a mysql error. However, when I use this query in PHPMyAdmin it works fine. Can anyone see what is causing the error? [CODE] for($i=0; $i<10; $i++) { $nextDay = $i+1; $startDateTime = date("Y-m-d H:i:s", strtotime("-$i days")); $endDateTime = date("Y-m-d H:i:s", strtotime("-$nextDay days")); … | |
I have this table(building_lvl): [icode]lvl | building_id | region_id[/icode] And I want to get the region_id for which building_id=3 has lvl 2 and building_id=2 has lvl 5 [code]SELECT * FROM building_lvl INNER JOIN regions ON regions.region_id = building_lvl.region_id WHERE ((building_lvl.building_id='3') && (building_lvl.lvl > 1)) && ((building_lvl.building_id='2') && (building_lvl.lvl > 4)) … | |
I am checking to see if a value has been entered in a form and then updating only if a value is entered. The problem is I want 0 to be an option that can be entered and php is treating 0 as if it were the same as NULL … | |
I am fairly new to image uploaders (worked in animation for a long time). I have an image upload form that works fine. The image uploads and redirects to another PHP page (imageupload_file.php) that confirms the image uploaded and gives you the name of the image and size on the … | |
Hi, Code below returns this. [code] Array ( [0] => 3 [id] => 3 [1] => John [name] => John [2] => Goog [surname] => Goog ) [/code] Everything repeated. Why? Also, I need to serialize. I need it for some other reason. [code] $sql="SELECT * FROM friends WHERE id='3'"; … | |
hi, got a new prob, how can i create a php page that automatically refreshes each time i access the page. | |
Hi I'm making a login panel which sends data to the same page and I use a class made by me and called 'user' that stored user information and autentification. When I refresh the page I check if any session was created before (it was created at first successfull login … | |
Hi guyz, i'm aiming for a php and My SQL dabase website, can anybody guide me plz? appreciate the help:) | |
hi, i am trying to upload an image with comment......!! mycode is like below...... if($_POST){ getting posted variables for comment mysql_query(adding into database); if(image is posted){now getting image variables mysql_query(inserting into database); } } if works fine for me but problem is that i have two different tables one for … | |
Hi everyone, I've been a reader for a long time, now I've joined up, as I'm fairly stumped on this one!! I'm currently teaching myself mysql and php at work, and have a problem. I am using php to produce a listing of restaurants on a page, and I would … | |
Why doesn't this work? I choose English and it doesn't do anything... neither does Norsk work. Anyone help please, thanks. [CODE]<?php //nodag = Norwegian day //endag = English Day // dag = day if(!isset($GET_['ok'])) { //start if ?> <form action="" method="get"> <select name="lan"> <option value="eng">English</option> <option value="no">Norsk</option> </select> <input type="submit" … | |
I would like to make some query using the SELECT function. However i wasnt able to get the results i want. My code is as follow: [CODE] $sql = "SELECT * FROM device WHERE ((device_num like '%$val_d%') OR (dib like '%$val_dp%')) ";[/CODE] can i write it in this way? pls … | |
hello, i want to do a new task. but it is new to me. any body help plz... i want to send registration form through email to users. then user fill that registration form. i wrote javascript in mail body but in that javascript not working. below is my 'mail … | |
Why doesnt this code work. I keep getting false even when i type in the correct username and password [code] $user_name = mysql_query("SELECT * FROM users WHERE username = '".$Entered_UserName ."' AND password = '".md5($Entered_PassWord) . "'"); $user_name_password = mysql_fetch_assoc($user_name); if($user_name_password === false) { echo 'false'; } else echo 'true'; … | |
I have a webform for users of the site to insert information about theirself and then an image. However I don't want to save the image into the database as it will slow everything down...is there a way to save the image to my hardrive then create a link in … | |
I have an HTML form with three dropdown selects: month, day and year. I have four fields in my MySQL table: month, day, year, and date. The 'date' field is supposed to contain the concatenated values of the year, month and day separated by dashes. I write this in my … | |
hi there, im sorry if this has been posted before i have searched through the threads and have not found what i am looking for, however it is entirely possible that i have missed it, i have spent the whole day looking at search results and basically i need some … | |
Hi, actually i've posted from the wrong thread and i apologize for that. anyway, let me post my problem and it goes like this. we've successfully created drop down menus that is connected to our database. we have 5 fields to display, each field contains different data [(ex. first field … | |
I successfully scripted an fetch array while loop on a table called example. What's the name of the function that will return the name of the array that was created by the fetch array while loop? What's the name of the function that will turn the number of rows in … | |
hello i am new to xampp . and making a project using php & mysql. whenever my php files run, its doesn't show any changes in my database. for eg. ,if i have entered certain values on my html page and through my php page ,the values is getting inserted … | |
| Hello folks! Is it possible to create directories on my web server based on new database entries? I am implementing a photo gallery and want to have it such that, when a user ADDS a new Gallery, a (sub)directory is created with the name that the user gave the gallery. … |
Hi, Could someone assist me with this code. It gives me an error message whenever i press the submit button. It gives me this error message We are very sorry, but there were error(s) found with the form your submitted. These errors appear below. Please go back and fix these … | |
In many of the forums i have observed that , we can re direct the page like thanks for logging in u will be redirected in 5 secs and eventually the 5 secs decreases to 0 and the page gets redirected. In my php code i could redirect the page … | |
Hi All, the following code is giving me the following error and i would appreciate any help in identifying where the error lies Parse error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting ',' or ';' in /Applications/MAMP/htdocs/CG0119/index.php on line 6 the code is here, and line 6 is the echo statement [code] … | |
Hello everybody. I'm pretty new to PHP and mysql. I made a mysql database table: Election_Table One of the fields in there is elect_title, and the primary key is ID I am trying to make a drop down menu that has the names of all the names of the elections … | |
HI i have made a web site. what I want to do is that I want to make a direct link from rapidshare . I mean to transfer a file from rapidshare to my site and give it a direct link address . how can I do so ? thanks | |
Hello, This is my first post. I'm a web designer & SEO guy at a background check company. This morning I was handed down this project that, well... I lack much experience with. Definitely not my area of expertise, but willing to give it a crack rather than my company … | |
i m searching for it from last two hrs. but didnt find anything useful.. i hope some reply to this topic..!!! i just need a php script to upload excelsheet data into mysql table..!! thanks | |
Hi, i am trying to validate credit card. I want to validate credit card 1> name on card 2> card number 3> card type (visa,mastercard... etc) 4> cvv 5> expiry date I seared on google but most of links gives information to validate card according to number. How to do … |
The End.