39,316 Topics

Member Avatar for
Member Avatar for Nicole_17

I need help..Even after doing extensive research and youtube videos.. I can't seem to get this. This is just for a hypothetical situational based project i'm doing to demonstrate the functionality of storing fake credit card info in a mySQL database from a PHP file. The goal is: Once a …

Member Avatar for Dani
0
167
Member Avatar for Trabelsi

Hi, I try to update a table through a list with checkboxes , but still this error message appear:"SQLSTATE[HY093]: Invalid parameter number: parameter was not defined" this my source code: the script checkbox.html <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <link rel="shortcut icon" type="image/ico" href="http://www.datatables.net/favicon.ico"> <meta name="viewport" content="initial-scale=1.0, maximum-scale=2.0"> <!-- jQuery …

Member Avatar for chiu
0
253
Member Avatar for ChrisJ

I’m trying to modify a web script where a drop-down works successfully. How can another drop-down field appear only after a selection has been made from the first drop-down list? Here’s the current code: <?php if ($pt->page == 'category' && $pt->show_sub == true) { ?> <div class="pull-right col-md-3 no-padding-left"> <select …

0
44
Member Avatar for wellho188

Hello I just want to ask for some help regarding with the undefined index error. The image are uploaded / stored in database but the image cant store in folder directory. Please can someone help me. This is for my project. Thank you guys in advance.

Member Avatar for rproffitt
1
48
Member Avatar for Adolfo_1

Hi ... how can i have url seo friendly from database ?? Example: localhost/myshop/product.php? id = 95 Or: https://www.myshop.it/product.php?id=95 I have done several tests with .htccess but it doesn't work. I would like to have as follows: https://www.myshop.it/product.php/shoes-armani Or: https://www.myshop.it/shoes-armani tbl_product +-------------+----------------+-----+----------------+ | p_id |p_name | p_name_friendly| +-------------+----------------------+----------------+ | 95| …

Member Avatar for Dani
0
199
Member Avatar for Umar code

deprecated and will be removed in a future version. To avoid this warning set 'always_populate_raw_post_data' to '-1' in php.ini and use the php://input stream instead. in <b>Unknown</b> on line <b>0</b><br /> <br /> <b>Warning</b>: Cannot modify header information - headers already sent in <b>Unknown</b> on line <b>0</b><br />. Please the …

Member Avatar for Dani
0
47
Member Avatar for ChrisJ

I am trying to display something on web pages that show this in the url: "sub__" for example: ...com/videos/category/1/sub__536. It was suggested I try this code: $page = basename($_SERVER['PHP_SELF']); if ($page=="....") { echo Hello World; } elseif ($page=="....php") { Some Other code... } but I don't know where to place …

Member Avatar for Dani
0
31
Member Avatar for ChrisJ

This php has subcategory code on line 149 and 215 https://pastebin.com/zgbELKJf can you tell me if this file outputs a subcategory page?

Member Avatar for Dani
0
46
Member Avatar for Umar code
0
19
Member Avatar for hAPIcat

Hi, everybody. I write bots and decided to share my experience of writing bots on the [Chat API] platform, maybe it will be interesting to someone We’ll tell you how to write a simple bot on PHP using API WhatsApp. A demo bot will react on commands of ordinary Whatsapp …

5
1K
Member Avatar for WpgnGaming

I have a issue with the code below what I am trying to get the image from gifts table with matching the user_gifts id with the gifts_id but can not seam to get it right anyone god any ideas thanks. public function get_my_gifts($user_id) { global $db; $my_gifts = []; $get_my_gifts …

Member Avatar for pritaeas
1
90
Member Avatar for marmelade7

I'm trying to figure out why the regex code below gives me two different results, depending on where I use it. [A-Z]{0,1}[a-z]{2,}[:] **On phpliveregex.com, the above regex code matches the following:** narrator: Narrator: **When used in preg_match, the above regex code matches the following:** narrator: Narrator: NARRATOR: PS I'm not …

Member Avatar for Reverend Jim
0
81
Member Avatar for radhika_3

$query = "INSERT INTO TB_RADIOLOGI (ID_PASIEN, ID_PENDAFTARAN, TGL_PERMINTAAN, JENIS_PERMINTAAN) VALUES(?, ?, ?, ?);"; foreach($_POST['JENIS_PERMINTAAN'], reverse_tanggal($_POST['TGL_PERMINTAAN']) as $idx=>$val){ $params = array($_POST['ID_PASIEN'], $_POST['ID_PENDAFTARAN'], $val ); //--disini input id_pasien=0001 sesuai contoh di form sqlsrv_query($GLOBALS['conn'], $query, $params); } there is an error : Parse error: syntax error, unexpected ',' in Please help

Member Avatar for AndrisP
0
56
Member Avatar for naimake

Hi, I need your help. I am a newbie in PHP and my update statement is not working despite seeing all the values from the console. My code for the bootstrap modal file: <!----------------------------------- modal begin --------------------------------------> <div class="modal fade" id="editmodal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true"> <div class="modal-dialog"> <div class="modal-content"> <div …

1
30
Member Avatar for opjjuly

hey guys, i was wondering, is there any other way to hide .php extensions without using .htaccess? Instead of: [url]http://www.example.com/index.php[/url] Visitors to your site will see: [url]http://www.example.com/index/[/url] my webhost does not support the .htaccess thingy. :yawn: :@

Member Avatar for mervin_2
0
844
Member Avatar for javi2015
0
70
Member Avatar for sudharshan9xweb
Member Avatar for emiliolorenzo30

$sql = "SELECT cl_id, cl_name, cl_service_description, cl_contact, cl_dept,status, expiry_date from contract_list"; $result = $conn-> query($sql); if($result->num_rows > 0) { while($row = $result-> fetch_assoc()) { echo "<td>$row[cl_id]</td>"; echo "<td>$row[cl_name]</td> "; echo "<td> $row[cl_service_description]</td>"; echo "<td>$row[cl_dept]<td>"; echo"$row[status]"; echo "<td>$row[cl_contact]</td>"; echo "<td>$row[expiry_date]</td>"; echo "<td></td>"; echo "<td><div class=table-data-feature>"; echo "<button class='item' data-toggle='tooltip' data-placement='top' title='send'>"; …

0
24
Member Avatar for emiliolorenzo30

<?php require('cns.php'); $conn = mysqli_connect("localhost", "root", "", "cns"); if ($conn-> connect_error) { die ("Connection failed:". $conn-> connect_error); } $sql = "SELECT cl_id, cl_name, cl_service_description, cl_contact, cl_dept,status, expiry_date from contract_list"; $result = $conn-> query($sql); if($result->num_rows > 0) { while($row = $result-> fetch_assoc()) { echo "<td>$row[cl_id]</td>"; echo "<td>$row[cl_name]</td>"; echo "<td> $row[cl_service_description]</td>"; echo …

0
43
Member Avatar for Kojo_3

Please let me give more details $datetime1 = new DateTime($orderdate); $datetime2 = new DateTime($currdate); $interval = date_diff($datetime1, $datetime2); $interval->format('%m months'); $months_diff = $interval->format('%m months'); for($i = 1; $i <=($months_diff+1); $i++){ $totalFees = $fees + $totalFees;

Member Avatar for pritaeas
0
25
Member Avatar for safost56

Hi there, I have been a developer since 1999 but I was in an auto accident and have a severe traumatic brain injury which hasn't helped me write php code at all...LOL But I'm still here and trying. I need some help with file uploading in php. It's giving me …

Member Avatar for pritaeas
0
20
Member Avatar for Kojo_3

Hello. My name is Eben and I'm a beginner in php. I've been getting this error message "Notice: A non well formed numeric value encountered in C:\wamp64\www\Project\FeePayment.php on line 145". This is the code; for($i = 1; $i <=($months_diff+1); $i++){ $totalFees = $fees + $totalFees; Please I need help.

Member Avatar for rproffitt
1
42
Member Avatar for Issah_1

[ { "regionCode": "0", "": { "amount": "291377681.35999995", "kwh": "5589027.089364664", "numberOfPay": "43876" } }, { "regionCode": "3", "AZARE Region": { "amount": "13494424.550000023", "kwh": "286885.42398979055", "numberOfPay": "3863" } }, { "regionCode": "7", "BAUCHI Region": { "amount": "55739882.11", "kwh": "1297297.378804144", "numberOfPay": "11199" } }, { "regionCode": "5", "BUKURU Region": { "amount": "77074190.08000007", …

Member Avatar for Dani
0
34
Member Avatar for Shazz_1

I have a problem to do price data and i don't know to insert it into the coding this is question ![Screenshot_2021-09-23_015318.png](https://static.daniweb.com/attachments/4/7cc52f3407b6a914f395c8aaa4644c69.png) this is the coding that i have made <?php $page_title = 'Yoho Express!'; include ('includes/header.html'); ?> <form action="q2.php" method="post"> <p><h1><fieldset><legend>Enter your information in the form below:</legend></p></h1> <p><b>Departure day:</b> …

0
137
Member Avatar for Marco_18

Good morning, i have a section in a php page as per code: <div class="container section" id="afterHeader"> <div class="row"> <div class="tabs movies"> <a class="style1">1^ WEEK</a> <ul> <li><a href="#thu">GIO</a></li> <li><a href="#fri">VEN</a></li> <li><a href="#sat">SAB</a></li> <li><a href="#sun">DOM</a></li> <li><a href="#mon">LUN</a></li> <li><a href="#tue">MAR</a></li> <li><a href="#wed">MER</a></li> </ul I would need to replace the part <ul> </ul> …

Member Avatar for Marco_18
1
112
Member Avatar for searchmed

Hi, I've been trying to troubleshoot this iframe issue all day. I need help. First, the issue is an iframe on the frontpage is to load a php script for an Video ad. Second the frontpage is a php search script. Now, when you visit the frontpage initially everything is …

Member Avatar for Dani
1
345
Member Avatar for Omar_17

I moved my website from host to another, moved database and public_html file, Also, I modified wp-config file and deleted hlaccess. But, now I can't update any plugin or delete there is message said update_option( 'siteurl', 'https://zone1on.com' ); update_option( 'home', 'https://zone1on.com' ); Skip to main contentSkip to toolbar At the …

Member Avatar for Dani
0
99
Member Avatar for Uperdominator

$company_id = $_SESSION['compid']; $sql="SELECT * FROM `movies` WHERE companyID = ? AND name LIKE '%$search%' OR description LIKE '%$search%' " ; $stmt=mysqli_stmt_init($conn); if (!mysqli_stmt_prepare($stmt,$sql)) { header("location:main.php?error=stmt failed"); exit(); } mysqli_stmt_bind_param($stmt,"i", $company_id); mysqli_stmt_execute($stmt); $result = $stmt->get_result();

Member Avatar for rproffitt
0
36
Member Avatar for S U S A N
Member Avatar for ashraftushar

Hi I have mysql table as below id | item_id | date | received Now I want to make a html table from above data where columns are year and rows are months. and value will be sum of received on month _ year. like below demo | | 2018 …

Member Avatar for rproffitt
0
23

The End.