39,323 Topics

Member Avatar for
Member Avatar for Rizi004

Hi I am inserting in database but there is error in query. i have array in which form data is stored and function recieve the array but data is not inserting in array. bellow is the code. $insArr=array(); $insArr['first_name']=addslashes($_REQUEST['first_name']); $insArr['last_name']=addslashes($_REQUEST['last_name']); $insArr['email']=addslashes($_REQUEST['emailid']); etc there is 46 fields in table //now the …

Member Avatar for adam.adamski.96155
0
134
Member Avatar for Synestic

**Hi Daniweb!** I have a question regarding my e-commerce website. On my product overview, I have this code: <?php $replace_what = array('/',' ', ' - ', ' ', ', ', ','); $replace_with = array('-',' ', '-', '-', ',', '-'); //Start of (1) $mysqli = new mysqli(***); if (mysqli_connect_errno()) { printf("Connect …

Member Avatar for blocblue
0
213
Member Avatar for Riu 2009

hi everyone, i just want to ask is there any mistake in my code..because whenever i comment the email check it wroks fine but with email check it always gives error that this email already exists.. i am actually checking if the email im going to add is present already …

Member Avatar for Riu 2009
0
125
Member Avatar for Riu 2009

hope everyone is fine over there :) i just wanted to ask how i can display only one question at a time from mysql table?? here is my code which is doing following things 1) selecting all questions and displaying them what i want to do is 1) display only …

Member Avatar for broj1
0
4K
Member Avatar for jason.bangayan

I need help. I got this error after submitting a form that uses formmail.php: Parse error: syntax error, unexpected T_STRING in /home/thewebdy/public_html

Member Avatar for tiggsy
0
151
Member Avatar for xbat

I'm a bit lost on this with html5 - The datasrc attribute on the select element is obsolete. Use script and a mechanism such as XMLHttpRequest to populate the page dynamically.. Does this mean that I will have to change everything into a ajax format?

Member Avatar for diafol
0
168
Member Avatar for thumati

i Always getting : **mysql_fetch_array(): supplied argument is not a valid MySQL result resource in C:\wamp\www\class\function.php on line 28** please give the suggestion friends config.php <?php define('DB_SERVER', 'localhost'); define('DB_USERNAME', 'root'); define('DB_PASSWORD', '12345'); define('DB_DATABASE', 'class'); class db_class { function db_constractor() { $connection = mysql_connect(DB_SERVER, DB_USERNAME, DB_PASSWORD) or die('Oops connection error -> …

Member Avatar for tiggsy
0
270
Member Avatar for xbat

Getting a q is undefined.. I took <option="1">1</option> etc.. and now I'm pulling with ajax from datasrc.. I can't quite figure out how to define my database value.. The one uses query which pulls from the auto start typing.. then it submits to the other page through q - Once …

Member Avatar for xbat
0
424
Member Avatar for sinZ

I'm getting this error in one of my scripts: **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 '-25,25' at line 1** Below is part of the code any help would be great <?php …

Member Avatar for pritaeas
0
205
Member Avatar for onixbwcrap

Okay, sorry if it's a terribly easy/newb-ish task. But I really need this figured out, so I appreciate any help at all. I have a simple online exam task with just a couple of pages, just started learning PHP. The process is like this: 1.) a new user inputs his …

Member Avatar for onixbwcrap
0
215
Member Avatar for MeeraKotecha

Hello all.. we can execute php files from the command line interface... but do we have anything using which we can execute the command line cmds from our php file?? Plz help soon..

Member Avatar for manikantababu
0
360
Member Avatar for dbalas

Hi! I have a problem with getting error on update... What i have is - one table where i store my orders, and one table where i keep stock records. I managed to update the stock in my table with this piece of code but when i have for example …

Member Avatar for dbalas
0
155
Member Avatar for jkon

I knew that I can use variable variables instead of reflection in PHP but I have never gone that way because my OOP background stated that this is not a clean way. Recently I made a test using both methods and the results made me rethink it. Using variable variables …

Member Avatar for bato3
0
457
Member Avatar for tiekwebstar

Hy, i am a new here. this is my first post.check this website http://www.abswheels.se/ below slider there is an 3 colunms Marke(Main category) , Modell (Sub Category) and Motor(Sub Category). You can see the default selected menu below slider. When you select other main category than sub category and 2nd …

Member Avatar for bato3
0
2K
Member Avatar for tpowell0201

Hello DaniWeb, First off, I am not looking for code, at least not yet. I also honestlly don't know where to post this, but since I'm using PHP, what the heck. If you're an admin and can help me find more relevant answers by changing the "forum type", so be …

Member Avatar for LastMitch
0
118
Member Avatar for MarkieJye

I'm doing a delete page, and this part is the part where all the data were supposed to be echoed. but, the problem is I don't really know how to print the checkbox within the php. The line 6 is wrong. Kind men, do show me how to write it …

Member Avatar for MarkieJye
0
157
Member Avatar for roheath_1

Hi, so I'm trying to make a basic registration and everything shows up in the database (phpMyAdmin) except the password <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <?php $con = mysql_connect("localhost","root",""); if (!$con) { die('Could not connect: ' . mysql_error()); } mysql_select_db("sportcourt", $con); $sql="INSERT INTO user (firstname, lastname, password, …

Member Avatar for cigoL..:)
0
146
Member Avatar for Riu 2009

hi everyone :) i dont know where i am doing it wrong...but cant upload my file...there is no error but its not saving the whole path in DB and not uploading anything in the directroy as well... please point me to riht direction tahnx :) <?php include("../includes/config.php");?> <?php $mediafile = …

Member Avatar for Riu 2009
0
737
Member Avatar for flynismo

Hey all, What I am trying to do is create a search by zip code form. When the form is submitted, it will search for members in nearby cities within the given radius. For example, I submit a form saying find me all members within a 20 mile radius of …

Member Avatar for flynismo
0
121
Member Avatar for AMADH

This is my php code, I was wondering if you could help me, <link rel="stylesheet" href="style.css" /> <script type="text/javascript" src="script.js"></script> <?php $cat = mysql_real_escape_string($_GET['category']); include '../includes/db-conns.php'; //The file is being accessed on the staging site $hostname = $hostname3; $username = $username2; $password = $password2; $databasename = $databasename3; $link = mysql_connect($hostname, …

Member Avatar for AMADH
0
121
Member Avatar for tscina

I'm developing a website wherein the user searches for a name and results will be in a list. Then there is a link where in the user will preview an email format, like a confirmation page and at the bottom is a send button. After the button is clicked, it …

Member Avatar for tscina
0
219
Member Avatar for andyy121

im traying to create a contact form (email). im using xampp. so i need something like HmailServer or something like this to send email to myself. can everybody told me how i can configure HmailServer.

Member Avatar for LastMitch
0
152
Member Avatar for Peek@u

Hello I am having an issue assigning a variable to a select box selection so that i can feed the variable back into future queries. Please see code below: <select name="room" id="msg-room"> <?php $query = mysql_query("SELECT * FROM rooms ORDER BY ROOM asc"); while($data = mysql_fetch_assoc($query)) { ?> <option value="<?php …

Member Avatar for LastMitch
0
140
Member Avatar for bradly.spicer

Hey all. I FINALLY GOT MY PLUGIN TO *WORK*. Apart from one element... <?php /* Plugin Name: Minepress Minecraft Dynmap Plugin Plugin URI: http://minepress.co.uk Description: Minepress Minecraft Dynmap Plugin Author: Bradly spicer Version: 0.0.1 Author URI: http://minepress.co.uk */ /*Installation of Plugin */ /* What to do when the plugin is …

Member Avatar for LastMitch
0
170
Member Avatar for sunrise2008

Hi, At first I'm really sorry for my bad English :icon_redface: I really want to simulate a ImageButton click for an ASP.NET (.aspx) file via [B]curl[/B] (or simplate HTML file, but I very tries for it and finally I didn't get it! [B]More explain...[/B] I have this snippet code on …

Member Avatar for dirtfox
0
2K
Member Avatar for Avicii

final public function result($sql) { return $this->mysql['result']($this->mysql['query']($sql, $this->connection), 0); } Anyone got any idea how to best fix this error ?

Member Avatar for diafol
0
267
Member Avatar for samiyahg

This is a sample of the string of data that i need to extract the price of. "Price Rs 475 000 - CHEVROLET AVEO LS // SEP 11 6,000 kms - Red.. full options.. MANUAL 5 door // hatchback Contact me on 786 8394" I have many such strings after …

Member Avatar for samiyahg
0
565
Member Avatar for Avicii

<?php if(!defined('IN_INDEX')) { die('Sorry, you cannot access this file.'); } ?> <?php $vouch = mysql_query("SELECT * FROM cms_vouchers"); while ($voucher = mysql_fetch_assoc($vouch)) { $username = $voucher['user_id']; if(($_SESSION['user']['username']) == "$username") { ?> <div id="page-content-text" class="left"> <div id="contentTitle" class="red">%hotel_name% Alert: Enter the voucher code <?php echo $voucher['code'] ?> to receive <?php echo …

Member Avatar for Avicii
0
107
Member Avatar for amith_ami

hi all,.... plz help me..... hi guyz... i just know how to insert a file into database, but i dont know how to update that file.... here is my code.... <?php $resume=$_FILES['resume']['name']; $file=$_FILES['resume']['tmp_name']; $ext=strstr($resume,"."); //echo "file".$file; //echo "<br>"; //echo "resume".$resume; $sql = "SELECT MAX(cnd_id) FROM tbl_candidate"; $res = mysql_query($sql); $data= …

Member Avatar for amith_ami
0
131
Member Avatar for giturman810

Heello, I was having problems with this php script. I am trying to echo a statement on a contact form depending on the data entered, but when I hit submit, I get a blank page. I belive the error is something small, but I can;t put my finger on it. …

Member Avatar for simplypixie
0
304

The End.