123 Topics

Member Avatar for
Member Avatar for cheelo007

Is there a service available to have someone translate your code from mysql to PDO or Mysqli? Pay service or free. I just know I'm in over my head. Thank you.

Member Avatar for cheelo007
0
165
Member Avatar for jacob.tonna.58

script in file 1 <?php // Check if he wants to register // - Make sure that param exists // - Check length if (isset($_POST['username']) && strlen($_POST['username']) > 0) { // Check if passwords match. // - Make sure that params exist // - Check length // - Check matching …

Member Avatar for simplypixie
0
370
Member Avatar for Behseini

I am trying to create a secure login app using php and MySQLi by following this tutorial: Link To Tutorial The tutorial is using a table(members) with 5 fields as:"id", "username","email","password",and "salt". but at the very beginning there is a an SQL INSERT function which is confusing me INSERT INTO …

Member Avatar for veedeoo
0
350
Member Avatar for johnef_sh

hay how is everybody here, I have this form which should sign up users and send email to them to confirm they emails the users sign up OK but the Email don't go at all to the users email see my code and please need help on this. <?php if(isset($_POST['submited'])) …

Member Avatar for johnef_sh
0
250
Member Avatar for johnef_sh

Hey, I'm running a mysqli query, and would like to run a script if the query returns no results. this is my code <?php $SM_pro_info="SELECT * FROM special_marketing_ads ORDER BY id desc LIMIT 4"; $QSM_pro_info = $db->query($SM_pro_info)or die($db->error); $SM_pro=mysqli_fetch_array($QSM_pro_info); if($SM_pro){ while($SM_pro=$QSM_pro_info->fetch_object()){ ?> <table width="208" border="0"> <tr> <td width="129" height="35" align="right"><span …

Member Avatar for phorce
0
567
Member Avatar for pritaeas

Below is a documented code example showing how to use the [MySQLi](http://php.net/manual/en/book.mysqli.php) (MySQL improved) classes/objects to connect and query your database (and check for errors). If there are any questions, or you want to see different features, let me know.

5
4K
Member Avatar for simplypixie

I am not new to OOP I am tidying up a very large site of mine and trying to create a much better structure (more in keeping with the whole point of OOP). I have decided to use mysqli (please don't suggest PDO as I have decided againast it) which …

Member Avatar for simplypixie
0
2K
Member Avatar for bsewell

Hi, I'm trying to write a program using mysqli, so I have created a login page. I've tried looking for how to get an Insert statement ran using MySQLi, object orientated style. So it looks like my query isn't working but I don't know why so I wondered if someone …

Member Avatar for LastMitch
0
186
Member Avatar for LastMitch

Hi I'm having issue with editing the **Input Type** in **2** different position. I want to edit and add input text in the img. I also want to edit and add input text in the content. What I want to learn is how to add **2** **Input Type** areas in …

Member Avatar for LastMitch
0
169
Member Avatar for LastMitch

Hi I'm having issues with **get_magic_quotes_gpc()** function. I download this **Ajax File and Image Manager** from this site: http://www.phpletter.com/DOWNLOAD/ I install it on tinymce & fckeditor to test it out. They both work. I try to link the images and it didn't work and I also realizes the links are …

Member Avatar for LastMitch
0
263
Member Avatar for Setvir

I am urgently seeking assistance with the following error: *Commands out of sync; you can't run this command now* here's the code: $sql="select pr1.".$_SESSION['lang'].", pr1.id, pr2.".$_SESSION['lang'].", pr2.id from `project` as pr2 join project as `pr1` on(pr1.id=pr2.parent_project) where pr2.id=?"; $stmt = $mysqli->stmt_init(); $stmt->prepare($sql) or die ("Error preparing statement: ".$mysqli->error); $stmt->bind_param('i',$_GET['id']); $stmt->execute() …

Member Avatar for cereal
0
161
Member Avatar for johnef_sh

Hay everybody, I have this Form I am trying to upload my image but every time I do "update" the page return normal and nothing uploded to my folder "ProfilesImages" where is my fault. if(isset($_POST['update'])){ $ProfileImage = $_FILES['ProfileImage']['name']; $Fname = clean_text($_POST['Fname']); $Lname = clean_text($_POST['Lname']); $Uemail = $_POST['Remail']; $Uwebsite = $_POST['website']; …

Member Avatar for blocblue
0
98
Member Avatar for timwhelan

I am trying to build a query that will display the Amount of people that signed up in a certain month. I am adding the date_time to the database at the time someone signs up for a course. I want to display the months and total sign-ups for the month. …

Member Avatar for johnef_sh
0
538
Member Avatar for phplover

Hi, When a user registers on my site there status is 0 (not active) ... meaning they not activated there account via email. When they register i also store the DATETIME they registered, i store it in MySQL using MySQL DATETIME and using `NOW()` in my INSERT query on registration. …

Member Avatar for phplover
0
3K
Member Avatar for phplover

Hello, Can someoneone tell me when you `prepare()` a statement (in my case an update statement) and then `execute()` it, i then check using `rowCount()` after the update query (see code below) if `rowCount() > 0` if it is then a match was found and update took place, but i …

Member Avatar for phplover
0
192
Member Avatar for joshmac

I have a singleton class that I am revamping and need a little help with. I want to use the following syntax for my queries without having to declare a global object. Below is my current code: /** * The db database object * * @access private * @var object …

0
175
Member Avatar for afaaro

Hi about 7 days am experiencing this problem if you can help me out this is the code; it's not updating at all it's just redirecting me to the page this is my code [CODE] function editcat($cid,$catname,$catdesc,$ok=false) { global $db; $id = intval($cid); $result = $db->query("SELECT * FROM category WHERE …

Member Avatar for broj1
0
115
Member Avatar for ajbest

Can anyone tell me if the following query can be done? [CODE]mysql_query("SELECT a, b, (a+b) AS c FROM table WHERE c=1");[/CODE] When I try this I get an unknown column error for c. In order to get the query to work I have had to do this [CODE]mysql_query("SELECT a, b, …

Member Avatar for pzuurveen
0
170
Member Avatar for cuonic

Hi, Just started to mess with MySQLi, created a simple login script, Connection to MySQL server establishes correctly, but then displays username is incorrect, because 0 rows were returned. 1) Am I doing it right, is the mysqli layout I'm using correct ? 2) Database structure is uid - username …

Member Avatar for decade
0
112
Member Avatar for tt13

Nowadays i'm working very hardly on one prohect - mini social network with some advantages: You can generate tree style map ([url]http://goo.gl/ZP5yc[/url]) of all relationships of user. For example B, C, D are friends of A. On profile page of A when you click on "generate" button it shows A …

Member Avatar for Ezzaral
0
78
Member Avatar for Stefano Mtangoo

Hi, I'm making a custom user management class that inherits from DBManager class. The problem I have so far is executing queries using mysqli prepared statements. DB connects fine but then prepare statement fails. I have mysqli object as an attribute that is shared in the class. I'm new with …

Member Avatar for hielo
0
136
Member Avatar for phplover

Hi, I have gone over and over the subject and still confused. I currently develop in PHP 5.2.x along with MySQL. (awaiting host to upgrade to 5.3.x, hopefully not to long although on local i develop using php 5.3.5) Currently i use the standard MySQL functions in PHP like: [B]mysql_connect()[/B],[B] …

Member Avatar for phplover
0
156
Member Avatar for gunnarflax

Since no one answered to my previous thread about a similar issue I rephrase the problem and try my luck again :) I have rather recently started working with prepared MySQLi-statements in php. From what I've learned is it supposed to be much more effective and secure so I've tried …

0
155
Member Avatar for gunnarflax

Hi! I have a problem with binding parameters dynamically in my mysqli_stmt objects. As I don't know how many parameters which will be put into this function I must bind the parameters dynamically. Though I cannot understand what's wrong with this method: [CODE] public function execute($unprp_stmt, $data){ //Prepare the stmt …

Member Avatar for gunnarflax
0
412
Member Avatar for stevenfagan

I'm using a linux shared hosting account with godaddy and I can't seem to get stored procedures working correctly with my MySQL database. I can create them from within phpMyAdmin fine. I can also create them in MySQL workbench fine. However, whenever I try to call the stored procedures either …

Member Avatar for davidchilders
0
1K
Member Avatar for stevenfagan

I have a linux shared hosting account on godaddy and I want to use mysqli instead of the standard mysql. I'm not sure how to set it up though. I've picked up pieces of information around, but can't seem to find enough information that is specific enough to the situation. …

Member Avatar for AndreRet
0
207
Member Avatar for waveydaveywaves

I'm very stressed out right now and cant seem to fix the problem with this php/mysqli script. I will pay $10 through paypal to anyone who duplicates my code, (and its fixed) as a reply to this thread. My deadline is very close, and I need it within a day. …

Member Avatar for waveydaveywaves
0
442
Member Avatar for waveydaveywaves

right now my php script is vulnerable to anyone putting in a random member_id into the url and having it excute sucessfully how can I encrypt the id="id#" in the url, so a guest is unable to type in there own id in the posted id retrieved through the url? …

Member Avatar for waveydaveywaves
0
216
Member Avatar for waveydaveywaves

I've been trying to get this code to work for hours can anyone spot the mistake i made? its a code to edit the contents of a database field calling it by its primary key. my error code is Parse error: syntax error, unexpected T_VARIABLE in E:\xampp\htdocs\php\databaseview\records.php on line 103 …

Member Avatar for pritaeas
0
333
Member Avatar for samaniac

Hey guys, I'm getting the above error, could any of you tell me why? Here's the code [CODE]$mysqli=new mysqli("localhost", "***", "***","***") ; if(!$mysqli){ die("Database error"); } function checklogin($username, $password){ global $mysqli; $result = $mysqli->prepare("SELECT * FROM users WHERE username = ?"); $result->bind_param("s", $username); $result->execute(); if($result != false){ $dbArray=$result->fetch_array();[/CODE]

Member Avatar for hielo
0
1K

The End.