39,323 Topics

Member Avatar for
Member Avatar for geysa

Warning: mysqli_query() expects parameter 2 to be string, object given in E:\xampp\htdocs\cadastro\cadastrar.php on line 46 Alguem pode me ajudar? <!DOCTYPE html> <html> <head> <meta charset="UTF-8" /> <title>Cadastrar</title> </head> <body> <?php include "config.php"; $nome = isset( $_POST['nome'] ) ? $_POST['nome'] : 'valor_padrao'; $sobrenome = isset( $_POST['sobrenome'] ) ? $_POST['sobrenome'] : 'valor_padrao'; …

Member Avatar for stultuske
0
369
Member Avatar for amith_ami

Hi all, I am trying to select single record from each year of last ten year. Given below is the code what I am using now. But its taking too much time to get the result. Is there any way to make it fast? $sql_cond ="SELECT Close_Price FROM (SELECT Close_price …

Member Avatar for amith_ami
0
337
Member Avatar for lewashby

I get the following in my web browser when I try to connect to my mariaDB database. `Error!: SQLSTATE[HY000] [1045] Access denied for user ''@'localhost' (using password: NO)` It also doesn't matter if I use mariaDB root or a regular users credentials, I get the same thing. The error above …

Member Avatar for lewashby
0
656
Member Avatar for mexabet

I wrote a modify password file, but unfortunately, the MySQL query is throwing error: Warning: mysql_query() expects at most 2 parameters, 3 given in admin\modify-password.php on line 40 This is the PHP code: if (mysql_query("UPDATE admin SET hash = ? WHERE admin_id = ?", crypt($_POST["newpassword"]), $_SESSION["admin_id"]) === false) I modified …

Member Avatar for mexabet
0
350
Member Avatar for aishu_15

I have mysql database with two tables.categories and products. **categories** 1. id 2. parent_id 3. category_name 4. image 5. status **products** 1. id 2. category_id 3. product_name 4. product_description 5. image 6. status **Question** Using php code how to go to the products page after the n level categories? Below …

Member Avatar for diafol
0
1K
Member Avatar for wikit

I've been using this without issue for ages..... and now it isnt outputing the info... I get a blank table like it's trying to work but not displaying it... <?php include('dataentry/update-connect2.php'); $sql="SELECT * FROM photos Order by stageno asc"; $result=mysql_query($sql); ?> <table width="670" border="0" cellspacing="1" cellpadding="0"> <tr> <td> <div id="table-wrapper"> …

Member Avatar for diafol
0
180
Member Avatar for Pavan_9

What is the tech stack of houzz.com and Etsy? We want to build a similar application with millions of images and users, high traffic.... basically we want the base on LAMP(php) and what else we can add? Of course hosting will be EC2, S3 and Cloudfront but what else we …

Member Avatar for cereal
0
456
Member Avatar for janicemurby

hi im following a tutorial for a block system and i have the following error i cannot fathom if anyone can help be must appreciated heres the error msg: mysqli_fetch_row() expects parameter 1 to be mysqli_result, boolean given in /home/public_html/php_parsers/block_system.php on line 32 and heres the code in question // …

Member Avatar for janicemurby
0
7K
Member Avatar for Santhosh_2

this is my code in firstpage <?php require 'dataconnection.php'; $res = mysql_query("select * from questions where category_id=$category ORDER BY RAND() LIMIT 20") or die(mysql_error()); $rows = mysql_num_rows($res); echo $rows; $i=1; while($result=mysql_fetch_assoc($res)){ if($i==1){?> <div id='question<?php echo $i;?>' class='cont'> <p class='questions' id="qname<?php echo $i;?>"> <?php echo $i?>.<?php echo $result['Question'];?></p> <input type="radio" value="A" …

Member Avatar for diafol
0
467
Member Avatar for AntonyRayan

Can anyone give me the full sample code to Send email from one requested email to multiple emails in php

Member Avatar for diafol
0
196
Member Avatar for AazibKhan
Member Avatar for gabrielcastillo

Quick help, I can't seem to think right now, and I need to add these array values into a single total value for each array key. Importantly the total value. Array ( [0] => Array ( [sub_total] => 1000 [total_tax] => 82.5 [total] => 1087.5 ) [1] => Array ( …

Member Avatar for cereal
0
354
Member Avatar for abim usman

<html> <head> <title>Help Me</title> <html lang="en"> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css"> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script> <script src="http://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/js/bootstrap.min.js"></script> </head> <body><br><br> <center> <h1> Additon</h1><br> <form action="" method="post"> <label>Enter Num1:</label> <input type="text" name="num1" /><br> <label>Enter Num2:</label> <input type="text" name="num2" /><br><br> </form> <div class="container"> <!-- Trigger the modal with a button --> …

Member Avatar for rubberman
0
309
Member Avatar for UK-1991

Hello, I am trying to create shortcodes in an easy way for my cms I am successfull to create and replace the shortcode with the content but what if there will be 2 shortcodes placed within the content I am confused to replace it if there are 2 shortcodes can …

Member Avatar for cereal
0
196
Member Avatar for Santhosh_2

i developed a quiz app in php. i want to store selected radio button values into session array and post them to next page and dispaly in the second page. here is my first page code.int this i get the data from db and populate here.i want to send this …

Member Avatar for diafol
0
549
Member Avatar for grahf23

Hi guys, need some help on a star rating system i am working on. The issue is that i have multiple star rating on a single page but if i click on a star for another field, it will highlight all the previous unlighted stars too. Not sure how to …

0
118
Member Avatar for vipula

I have a username and password for a external website. I want to have a link from my webste to log in to that site without giving username and password to my users. How can I achieve that. I tried lke this but failed. If any one can rectify this …

Member Avatar for jkon
0
2K
Member Avatar for Abbas Ansari

I'm trying hard with displaying details from a selected option in a drop down list for my project. I have a drop down list which is populated from a MYSQLi query. I want the user to select an option and the values associated pulled from the database and displayed to …

Member Avatar for cereal
0
19K
Member Avatar for Sophia_1

Hi everyone, am trying to display report based on quarter ie Quarter1,Quarter2 etc. However,after keying in record for Quarter2, the report below does not display Quarter2 record but still Quarter1 record. Please advise how to make the report display Quarter2 record if the current month is Jun etc. Thanks a …

Member Avatar for Sophia_1
0
280
Member Avatar for UK-1991

developed an admin panel in which users can add products from there and I put fields over there as size and color for the dresses dresses sizes and color would be more then 1 so I made 2 more tables in the database named prod_size and prod_color here is the …

Member Avatar for amigura
0
174
Member Avatar for mexabet

I'm getting the following error message, while inserting data into a MySQL database table: Sorry, an error occurred while inserting data into the database. 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 '?, …

Member Avatar for mexabet
0
373
Member Avatar for LibraryCode

Hi all would like to ask technical question what are the prons and cons of using and not using codeigniter shopping cart class? Heard is better to use functions and sessions and do not use cart class as it is depricated or limited with doing certain functionality .Thanks

Member Avatar for cereal
0
149
Member Avatar for Ritesh_4

Hello I am currently building a login form using HTML/PHP/Codeigniter, and would like to add some visual effects, like for example, if a user enters the username, either a tick or a cross is added beside the field when the user moves to the "password" field for example, and the …

Member Avatar for diafol
0
418
Member Avatar for Stephen_10

Hello All, I have been working on a registration form for opencart for a while now. I think I am nearly there in how I have coded it. However I just do not know where I am going wrong with it. It is a standard form with text input fields …

0
102
Member Avatar for Sophia_1

Hi, am trying to display the filename after upload but can't display, instead error message "There are no files in the database" is displayed. Please advise. Thanks. <?php // Connect to the database $dbLink = new mysqli('localhost','user','','pq'); if(mysqli_connect_errno()) { die("MySQL connection failed: ". mysqli_connect_error()); } // Get the ID // …

Member Avatar for amigura
0
378
Member Avatar for janicemurby

hi ive changed my system and im attempting to add a date of birth to registration and i have came across the following error Fatal error: Call to undefined function Age() in /home/jktempla/public_html/signup.php on line 56 if solmeone can please look at the coding for this section and see whats …

Member Avatar for cereal
0
215
Member Avatar for cambraydesign

What I want to do is embed a pdf on a web page or use a js library for viewing pdf and have an option to click on the pdf. This saves the coordinates and page of the pdf that you are on. I can then send these coordinates for …

0
223
Member Avatar for Jiby_1

a pop up will display during a button click...before that i want to store a hidden field value to session at the same time popup should come..how it is possible

Member Avatar for diafol
0
85
Member Avatar for SimonIoa

Hello i have a problem with my script for uploading a photo. The name it is stored in the database (123.jpg) but the photo doesnt go to folder i ask it to go Here is my script <form id="imageform" method="post" enctype="multipart/form-data" action='<?php echo $base_url; ?>press_image_ajax.php'> <span id='addphoto'><?php echo $lang['AddAPicture'];?>:</span> <input …

Member Avatar for diafol
0
111
Member Avatar for jiah2345

I have a column with employee Id and employee name.When i enter the EmployeeID in the textbox, the employee name should be automatically populated from the database in the second textbox. Please Help

Member Avatar for urtrivedi
0
101

The End.