38,023 Topics

Member Avatar for
Member Avatar for CarterLangley

Hi guys, I have the following code that I just cannot get to work! Can you please let me know where I have gone wrong? <?php //db_connect.php $con=mysqli_connect("localhost","root","password","database"); if (mysqli_connect_errno()) { echo "Failed to connect to MySQL: " . mysqli_connect_error(); } function get_file_extension($file_name) { return end(explode('.',$file_name)); } function errors($error){ if …

Member Avatar for Ajit_786
0
1K
Member Avatar for MavrickIT

Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/botomul/public_html/whatsnew.php on line 130 [CODE]<?php error_reporting (E_ALL ^ E_NOTICE); ?> <?php $item=$_GET['id']; include ("header.php"); $mark = mysql_query("select * from product order by product_id DESC"); $counter=0; ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Welcome …

Member Avatar for Sanjeda shekh
0
850
Member Avatar for Ravi_53

I have One Problem in my coding ..I want to upload multiple images in the database in one row with using comma ... for($i=0;$i<count($_FILES['eventpic']['name']);$i++) $pic = $_FILES['eventpic']['name'][$i]; $tmp =$_FILES['eventpic']['tmp_name'][$i]; $location="pics/".$pic; move_uploaded_file($tmp,$location); $q="insert into tbl1(title,tdate,eventpic)values('','','$pic')"; echo $q; through this code i can upload tthe multiple images but not in a single …

0
212
Member Avatar for soham_3

Hello I am using Crystal report version 11.5.8.826, php version 7.0.10, Apache version 42.4.33 and MySql Version 5.7.14. I have created the sampel rptone.rpt file that contents sample report. I want to load that rptone.rpt file using php. With Crystal report 11.5.8.826, php 7.0.10, apache 42.4.33 and MySql 5.7.14 i …

0
174
Member Avatar for vinod tik

i have a problem in displaying the values of a cookie dynamically code goes as... <?php $x=array(); include("connect.php");//database connection file $temp=$_GET['id']; setcookie(count($x)+1,$temp); echo $_COOKIE['$x[1]']; ?> // how do i display the value of cookie every time... it is over written.... i have tried it with using array.. in short i …

Member Avatar for alan.davies
0
2K
Member Avatar for arry004

Hi Pls tell me how to create a Crystal Report in php, mysql using com component Thanks in advance Arry :rolleyes:

Member Avatar for alan.davies
-1
5K
Member Avatar for AsjadAli

Hello Experts! I am stuck here while generating QR Code using php sql. Basically I am generating code for students using their ids and other information while fetching data from database. But the problem is that when i click on submit button so that table data store in QR Code, …

Member Avatar for alan.davies
1
7K
Member Avatar for Yeru

Currently i can search in a box for a specific thing in my database but i can't search in my drop down menus which i need so it can help "find" it as well so it can narrow down the search. my current code: [CODE] <?php $mysql_link = mysql_connect('localhost', 'root', …

Member Avatar for Dhanabal007
0
3K
Member Avatar for aveeva7

I am following the below module, https://www.webslesson.info/2018/04/shopping-cart-by-using-bootstrap-popover-with-ajax-php.html How can i use without quantity [Product Name, Price, total, Action] i tried lot fail again and again. I am learning stage in PHP, any help pls welcome.

0
185
Member Avatar for herdhemhola

I am having problem in submitting this form when I select "1" on the number of setting in html form. The submit button is working if I select 2 in the number of sitting from html form as it will show all the form fields but when I select 1, …

0
393
Member Avatar for Des_2

I am learning database and php I have made a database with a list of my game collection with the following fields, 1. ID 2. game_name 3. game_year 4. platform 5. publisher_name 6. media 7. owned 8. finished 9. completed 10. launcher I made this database in phpMyAdmin and would …

Member Avatar for alan.davies
0
309
Member Avatar for MrInternet101

Hello all...New to the group here. Glad to be part of the site as I just found it and am excited about learning! Have a hopefully easy question for anyone who has the time to assist. Yes, it is for homework, so I hope I don't break any rules here. …

Member Avatar for Fram
0
8K
Member Avatar for jLamp

I am using the following code to check the user permission (User Role). This is to check whether the user is logged in or not <?php session_start(); if (!isset($_SESSION["username"])) { echo '<script>window.location.href = "userLogin/?notloggedin=true";</script>'; } ?> This is to check whether is an admin or not <?php session_start(); if ($_SESSION["user_group"] …

Member Avatar for alan.davies
0
333
Member Avatar for anis_1
0
289
Member Avatar for aveeva7

My code about filterable audio searching, here how can i add Add-To-Cart functionality? code : index.php <?php //index.php include('database_connection.php'); ?> <!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="width=device-width, initial-scale=1"> <meta name="description" content=""> <meta name="author" content=""> <title>Voice Repository</title> <script src="js/jquery-1.10.2.min.js"></script> <script src="js/jquery-ui.js"></script> <script src="js/bootstrap.min.js"></script> <link rel="stylesheet" …

0
327
Member Avatar for Dani

This is the code behind the demo at https://www.daniweb.com/connect/oauth/demo

1
3K
Member Avatar for Kullaniciadi

*Multiple database select - but print ids separately* $sql = "SELECT * FROM peron, peronmedia WHERE peronmedia.PID=5" and peron.ID=5"; $xc = mysqli_query($baglanti, $sql); $rs=mysqli_fetch_array($xc); echo $rs["peron.PID"]; echo $rs["peronmedia.ID"]; **but the codes don't work** ## **How can I do it?** ## Thank you.

0
195
Member Avatar for Ben_33

<?php require_once('../vendor/autoload.php'); if (!isset($_POST["cart_payload"])) { echo "PAYLOAD NOT SET"; } $items = json_decode($_POST["cart_payload"], true); $line_items = array(); foreach ($items as $item) { $line_items[] = array( $target = 'images/'; $target = $target . basename( $_FILES['image']['name']) 'name' => $item["title"], 'image' => $FILES["image"], 'amount' => $item["price"]*100, 'currency' => 'gbp', 'quantity' => $item["quantity"], ); …

Member Avatar for rproffitt
0
360
Member Avatar for jonlloydd

Receiving error - Warning: Missing argument 4 for Get_All_Orderlines_Range(), called in /home/download/domains/1ecommerce.com/public_html/dev/_cms/list_orders.php on line 184 and defined in /home/download/domains/1ecommerce.com/public_html/dev/_cms/list_orders.php on line 161 Line 161: function Get_All_Orderlines_Range($id, $all = "", $from_date, $to_date){ $sql = "SELECT * FROM orders"; $sql .= " INNER JOIN orderline on orders.OR_ORDER_NO = orderline.OL_ORDER_NO"; $sql .= " …

Member Avatar for imaaxa
0
2K
Member Avatar for Gloak

I have an application that has core PHP for the signin, registration, dashboard. It has a front end and backend (dashboard). Simple stuff. I need to implement a Scheduling system and [EasyAppointments](https://easyappointments.org/) (EA) has 90% of the stuff I need. EA uses codeigniter and requires login. It has it own …

Member Avatar for Dani
0
518
Member Avatar for herdhemhola

I am a beginner to php and am designing student information system where students need to enter 9 subject and its corresponding grade based on the number of sittings. Is there any better way to do this apart from what I have been doing? These are my codes: <form name="register" …

Member Avatar for rproffitt
0
706
Member Avatar for aveeva7

Magento how to apply discount for new customer like 1st order 5% discount and 3rd order 10% discount?

0
239
Member Avatar for Dani

You might be familiar with the dreaded blank page when your PHP script doesn't work. Here's how to spit out errors to the screen, instead of getting just a blank page, as well as logging errors to a file.

1
2K
Member Avatar for Dani

There are two ways to write to a file in PHP. You can either open a stream, and write to it in parts, or you can use `file_put_contents()` which is much more convenient, with the trade off being that it takes up much more memory, and is not ideal if …

0
2K
Member Avatar for kesavankani

Hello Frds, select box option add new state in add.already same state in condition check already exist using php pdo.please help me.

-1
322
Member Avatar for abhi10kumar

How I can get current date and 15 days back date from current date in 'Y-m-d' format ?? e.g. if current date is 2011-06-21 then $currentdate=2011-06-21 and $dateback=2011-06-06;

Member Avatar for AnnDash
1
3K
Member Avatar for SimonIoa

Hello i am getting an error on a CASE WHEN THEN syntax on my mySql SELECT DISTINCT u.uid,c.c_id,u.name,u.profile_pic,u.username,u.email,c.time FROM conversation c, users u, conversation_reply r CASE WHEN c.user_one = '99' THEN c.user_two = u.uid WHEN c.user_two = '99' THEN c.user_one= u.uid END AND ( c.user_one ='99' OR c.user_two ='99' ) …

Member Avatar for Viki_1
0
5K
Member Avatar for Dani

We have a Swagger file for our API, but in our API documentation, we want to show valid responses for each endpoint. I coded up this little recursive function in PHP which takes our Swagger file and spits out a valid response. I use it as follows, for each individual …

0
2K
Member Avatar for Dani
0
2K
Member Avatar for kesavankani

Hai Frds, My question is i have create select box using state,district,city and town.select state box click add option select box change text box add/edit in text box add tha value save in state select box. How do please help me

Member Avatar for Dani
0
386

The End.