39,323 Topics
| |
Record is inserting but email is not going.. if($_POST['registersubmit']) { $to="'".$_POST['email']."'"; include('db.php'); $checkemail=mysql_num_rows(mysql_query("select * from authentications where email='".$_POST['email']."'")); if($checkemail) header("Location:".$_SERVER['PHP_SELF']."?msg=E-Mail Already Exists "); else { $query="insert into authentications (password, authcode, email, status, created_at) values ('".$_POST['password']."', '".md5($_POST['email'])."', '".$_POST['email']."', 0, '".date('Y-m-d h:i:s')."')"; if(mysql_query($query)) { $headers1 = 'MIME-Version: 1.0' . "\r\n"; $headers1 .= … | |
Hello everyone, My friend has been helping and he's been great however it's come to a halt :P I'm working with MYSQL at the moment but am having a few issues with my code. Index.php: <html><link href="stylesheet.css" rel="stylesheet" type="text/css"> <head> </head> <body> <div id="header"><img src="http://www.rhinosecurityltd.co.uk/templates/rhuk_milkyway/images/mw_joomla_logo.png" alt="Rhino Security"> </DIV> <form name="Form" … | |
| I'm trying to upgrading php from 5.2 to 5.3 manualy. i downloaded the C9 x86 Thread Safe (2012-Nov-21 22:03:51) zip file, opened it into c:\php did what it said in this manual http://php.net/manual/en/install.windows.manual.php first off, I had no pear folder in the zip, and no pear-go.bat.. and second, once I … |
| i have this xml file <CATALOG> <CD> <TITLE>Empire Burlesque</TITLE> <ARTIST>Bob Dylan</ARTIST> <COUNTRY>USA</COUNTRY> <COMPANY>Columbia</COMPANY> <PRICE>10.90</PRICE> <YEAR>1985</YEAR> </CD> </CATALOG> with my php code i am able to get the parent node <CATALOG> then all the other data such as <TITLE> etc etc , how would i go about getting the <CD> tag?? … |
i am not sure what i did but i messed up my page. take a look at page and you will see the problem. it puting php code in a echo"";. i cant seem to find where the problem. <!-- Connect --> <?php session_start(); //for errors include("../../INCLUDE/header.php"); ?> <!-- top … | |
Hi, I want to develop a CMS that I can use when I make websites. Want to simultaneously post it online so that people can download it and develop plugins and themes for this. Would like to have it as user friendly as other CMS such as Wordpress, Joomla, Dupal … | |
Hello! Im looking for a new source code editor. Have come to the point where I need something more powerful and professional. The big issue is this: We develop software in PHP. In our code we have language specific strings like: ------------------------------- echo "Enter your name:"; ------------------------------- We would like … | |
I just need to know, what is the difference and relashin ship between the two? | |
Hi there fellow daniweb programmers I have problem in running function in javascript <script type="text/JavaScript"> function toggle() { var e = document.getElementById('target_<? echo $id; ?>'); e.style.display = 'none'; } </script> I have button that generated in php code so its repeating itself <li><a id="target_<? echo $id; ?>" href="like.php" onclick="toggle()"><img src … | |
I am trying to help prevent SQL injection using mysqli_real_escape_string, I have the following: <?php $Connect = mysqli_connect ('', '', '', ''); if (mysqli_connect_errno()) { die ("Couldn't Connect to the Database"); } $String = "Hello, my name is (*$<>)*$)!*)_£)(!*£$&"; echo $String."<br><br>"; $Escaped = mysqli_real_escape_string($Connect, $String); echo $Escaped; ?> The problem … | |
Hello, everyone. I've recently switched hosts and the same script I was running in the past is now causing the rest of my MySQL queries to be locked, and it seems the query never completes. The code is: <? $con = mysqli_connect('localhost','user','password', 'database'); $Q = "DELETE FROM `Table1` WHERE `Field1` … | |
> hi guys, i've two array 3d $data and $array_bold, then i want to bold value $data be based value $array_bold, how i can do this??? <?php $data = array( array( '0'=>array( '0'=>'chelsea everton villa liverpool', ), array( '0'=>'milan inter juventus napoli', ), ), '1'=>array( array( '1'=>'madrid barcelona altetico getafe', … | |
I'm dipping my toe in the water of salted passwords by upgrading an older webapp, and would like to present the rough outline of how my system would work in the hope that those with more experience than I might tell me if I'm going in the right direction; In … | |
I am trying to turn off a block in drupal using existing code. <?php $node = node_load(arg(1)); $type = $node->type; if(substr($_SERVER["REQUEST_URI"], 0, 13) == '/our-people') { return TRUE; } else { return in_array($type,array('3_column_interior_page', '3_column_faculty_bio_page')); } ?> I wanted to add a page that will not show the block... <?php $node … | |
Drop Down List codes: <form class="selectfb" name="getFb" method="post"> <select action="getFb.php" name="natureOffb" class="selection" > <option disabled value="--Select Nature ofFeedback">--Select Nature Of Feedback--</option> <option value="Feedback" >Feedback</option> <option value="Enquiry">Enquiry</option> <option value="Compliment">Compliment</option> </select> </form> How to retrieve the data from database after I select a nature of feedback? The value that has been retrieve … | |
can anybody tell me event name for check box for using in jquery.such as for drodown it is 'onchange' .thank you. | |
is it possible to convert 09 to 9 by any function?if yes,please tell me.It is required to me.Thank you. | |
public function display( ) { $query="SELECT * FROM test ORDER BY RAND() limit 5 "; $result=mysql_query($query)or die("cannot select DB"); $num=mysql_numrows($result); echo "<table>"; echo "<tr>"."<td style='overfolw-hidden;width:400px;'> Question: </td>"; echo "<td style='overfolw-hidden;width:40px;'> OPTION A </td>"; echo "<td style='overfolw-hidden;width:40px;'> OPTION B </td>"; echo "<td style='overfolw-hidden;width:40px;'> OPTION C </td>"; echo "<td style='overfolw-hidden;width:40px;'> OPTION D … | |
Is there any function for changing a numeric value to string?suppose i passes '5' then it should return 'five'. | |
I've been trying to make dynamic queries, where the user determines what will be queried. The reason is because I'd like the images being displayed in my gallery reflect the category selected by the user. mysql_query("SELECT(whatever category they chose) FROM products") below is the generation of categories as links. (not … | |
| I am bulding a code for my site and have few problems 1. When I run this few times, it updates table ps_stock_available but with wrong values and after some time is stops to update that table? The problem is in the last query, two queries above are working ` … |
I want to show google map of selected theatre. first user have to select city then they have to choose theatre as per selected city. i have used drop down box for both. then, after selecting theatre, when he clicks on show button i want to show google map of … | |
Hello, I'm sure I'm missing something small. If a category doesn't exist in the database yet, how can I have the query accept a value of 0 without reporting an error? The $subcategory is what the user selected. The result should either be 4 images or a blank place holder … | |
addproduct.php snippet (there are lots of other inputs, not sure if that matters): <form method="POST" action="add.php" enctype="multipart/form-data"> <p>Picture:<input type="file" id="pic_upload" name="pic" /> <input type="submit" /> </form> add.php: if(isset($_FILES["pic"])) { if($_FILES["pic"]["error"]==0) { $name = explode(".",basename($_FILES["pic"]["name"])); $target = realpath(dirname($_SERVER['PHP_SELF']))."/images/".$name[0].session_id().".".$name[1]; $temp = $name[0].session_id().".".$name[1]; if(!move_uploaded_file($_FILES["pic"]["tmp_name"],$target)) { add_error("Picture specified did not upload"); } $_POST['pic']=$temp; } … | |
I'm new to MySQL and following a tutorial in a book to design a PHP MySQL website. Following this tutorial, I created a PHP page from which I can update entries in the MySQL database. What's strange is that only specific entries in the database will not update, while others … | |
Hello! I'm working on a simple messaging system for a project and I have this query and it isn't working for some odd reason, here it is: mysql_query("INSERT INTO messages SET user='$user', message='$msg', date='$date', to='$id', private='$checked' ") Here is my error: You have an error in your SQL syntax; check … | |
I have the following code... <?php $con = mysql_connect("localhost:3306","name","pass"); if (!$con) { die('Could not connect: ' . mysql_error()); } mysql_select_db("barndata", $con); $today = date("Y-m-d"); $result = mysql_query("SELECT * FROM event where Date >= '$today' ORDER BY Date ASC LIMIT 0, 7") ; while ($row = mysql_fetch_array($result)) { echo 'banner1.add("IMAGE","'; echo … | |
<div style="font-family:tahoma; color:#F00; "> <?php session_start(); if (isset($_SESSION['user'])) echo "You are logged in as ".$_SESSION['user'], " to log out click <a href =logout.php>here</a>"; else die ("Please Register <a href =register.php>here</a>");?> </div> <?php $username = $_SESSION['user']; if(!isset($_SESSION['user'])) { header("location: login.php"); } else { $query=" SELECT * FROM users WHERE user='$username'"; $result=mysql_query($query); … | |
Hi everyone. I'm currently developing a website for my university project. I want to ask about .htaccess for url manipulation. I already search through the web but couldn't figure out what i intend to do. I have this structure public_html - css - img - js _private - data ( … | |
I get this error: Warning: SimpleXMLElement::__construct() [simplexmlelement.--construct]: Entity: line 23: parser error : Premature end of data in tag catalog line 2 in C:\xampp\htdocs\php_exercise\exercise3_1.php on line 7 Warning: SimpleXMLElement::__construct() [simplexmlelement.--construct]: in C:\xampp\htdocs\php_exercise\exercise3_1.php on line 7 Warning: SimpleXMLElement::__construct() [simplexmlelement.--construct]: ^ in C:\xampp\htdocs\php_exercise\exercise3_1.php on line 7 Fatal error: Uncaught exception 'Exception' with … |
The End.