39,320 Topics
| |
Hey guys please help me with my code, I want to disable select drop down if $stat=a, this is my code. Thank You! echo "<select name='name' id='name' 'if ($stat =='a'){ echo ('disabled');}'>"; | |
The following table query is not executing properly, what is the correct syntax? $m_query = 'Insert into'.$job_id.'(`mobile`,`routeID`,`status`) values ('$mobile','$routeID','Sent')'; | |
Hi every, I have a working form on a website that I post a var to the url after the form has been submitted. The problem is, My data is not being displayed from the database after the form is submitted. index.php?fes=<? print $cfes_ref; ?> What is the best way … | |
Hi guys. I have problems with my php scrpt for downloading the file that i uploaded on my wampp server. Specifically, it turns out that when i finished downloding the file, its original size decrease like for example i upload a 24kb file on my wampp server. Then if i … | |
Hello Daniweb Community, I'm wanting to incorporate my Facebook pages reviews into my website but I can't see the manage to get a permanent access token. I've tried the same key (which is permanent) that I use to get the news feed but that doesn't work with the reviews. At … | |
Dear all, I am developing a website which can upload photos and also uploading Name, Descrptions etc using one form and one "submit" button. I found this below: http://plugins.krajee.com/file-advanced-usage-demo#comments The Example has some codes but I am not sure how to put it into a HTML Form and submit to … | |
hi i just want to ask and ask your help . can you guys help to make timer in my quiz page. seriously i have no idea how to do it. plus im still new in this field around 7 month , so i dont know where to put the … | |
Hello, I have just created a form and the form data is submitting using Ajax as I wanted the user to be on the same page after he submits the form as there are bootstrap accordian tabs data is submitting properly and retriving as well no problem but when the … | |
hi i used a javascript countdown timer as: [CODE]<form name="counter"><input type="text" size="8" name="d2"></form> <script> <!-- // var min=5 var seconds=0 document.counter.d2.value='5' function display(){ if (seconds<=0){ min-=1 seconds=60 } if (min<=-1){ seconds=0 min+=1 } else seconds-=1 document.counter.d2.value=min+":"+seconds setTimeout("display()",1000) } display() --> </script>[/CODE] for clock ticking purpose. and [CODE]<SCRIPT LANGUAGE="JavaScript"><!-- setTimeout('document.tform.submit()',300000); //--></SCRIPT>[/CODE] … | |
My current connection and echo code is as follwed: <?php $myServer = "Server_Name"; $myUser = "User"; $myPass = "Pass"; $myDB = "DB_Name"; //connection to the database $dbhandle = sqlsrv_connect($myServer, $myUser, $myPass) or die("Couldn't connect to SQL Server on $myServer"); //select a database to work with $selected = mssql_select_db($myDB, $dbhandle) or … | |
Hello, Created a query for getting users list excluding the logged in user well I thought about creating a simple one but huh that didn't worked for me. Okay so what logic and for what did I created for. I tried to show the users that are friends with each … | |
In a table, I show S.No , Name , Amount, Payable Amount, Balance Amount dynamically. So I need a calculation to show balance amount by subtracting payable amount with amount for all textboxes in onblur dynamically. Here is my code. But it does for only the first row, and how … | |
Hello, This tutorial is the next of “[A simple Data Layer for OOP PHP Applications](https://www.daniweb.com/programming/web-development/tutorials/500118/a-simple-data-layer-for-oop-php-applications)” so having read it and made your own tests is needed to understanding what we are doing. So far we have a Db object (child of PDO that standardize and simplifies its use) , a … | |
Hello i want to make a script so that users can record audio through their mic. I found this online https://github.com/streamproc/MediaStreamRecorder/blob/master/demos/audio-recorder.html but i how i can make the recorded audio to be stored on a table on my database? | |
Hi, I am trying to submit data and saving it to the database queries are inserting properly but the problem is that when I try to insert the data the message column Let suppose i Type in Hello World! In data base it show as undefined whhy is that so … | |
I have a problem when downloading the file i've uploaded on my local server. The file is successfully downloaded, however there is a problem on opening the file that i've download. For example i download a word file(.docx). The error is : The office open XML file 'filename' cannot be … | |
**Plz provide me a complete example of "Passing specific table row data in Bootstrap Modal" i.e on clicking edit link of a specific record, details for that record should be displayed in modal Table data is fetched with PHP from MySQL database. Plz help me out...** | |
I am using CodeIgnitor and oracle db at model function add_new_emp_test( $x, $y) { $conn=$this->db->conn_id; // Execute the call to the stored procedure $stmt = "BEGIN emp_pkg.add_account(:x1,:y1); END;"; $lob = oci_new_descriptor($conn, OCI_D_LOB); $lob = oci_new_descriptor($conn, OCI_D_LOB); $stid = oci_parse($conn, $stmt); oci_bind_by_name($stid, ':x1', $x, 100); oci_bind_by_name($stid, ':y1', $lob, -1, OCI_B_BLOB); $lob->writeTemporary(base64_encode($y)); … | |
Hi I have two tables property and property_images I join these tables with the following query: function get_residential(){ $query = $this->db->query("SELECT property.ID, property.property_name, property.property_slug, property.property_size, property.property_beds, property.property_bath, property.property_garage, property.property_type, property.property_state, property.property_price, property.property_address, property.property_description, property.date_created, property.active, property_image.image_name FROM property AS property INNER JOIN property_images AS property_image ON property.ID = property_image.image_id WHERE … | |
Hi,i have the following code,how can i count values -averages per row and column from this code: <?php $data = array( array(""=>"January", "ATL"=>rand(0,335) , "ORD"=>rand(0,335),"LAX"=>rand(0,335),"DFW"=>rand(0,335),"DEN"=>rand(0,335),"JFK"=>rand(0,335),"SFO"=>rand(0,335),"CLT"=>rand(0,335),"LAS"=>rand(0,335),"PHX"=>rand(0,335)), array(""=>"February", "ATL"=>rand(0,335) , "ORD"=>rand(0,335),"LAX"=>rand(0,335),"DFW"=>rand(0,335),"DEN"=>rand(0,335),"JFK"=>rand(0,335),"SFO"=>rand(0,335),"CLT"=>rand(0,335),"LAS"=>rand(0,335),"PHX"=>rand(0,335)), array(""=>"March", "ATL"=>rand(0,335) , "ORD"=>rand(0,335),"LAX"=>rand(0,335),"DFW"=>rand(0,335),"DEN"=>rand(0,335),"JFK"=>rand(0,335),"SFO"=>rand(0,335),"CLT"=>rand(0,335),"LAS"=>rand(0,335),"PHX"=>rand(0,335)), array(""=>"April", "ATL"=>rand(0,335) , "ORD"=>rand(0,335),"LAX"=>rand(0,335),"DFW"=>rand(0,335),"DEN"=>rand(0,335),"JFK"=>rand(0,335),"SFO"=>rand(0,335),"CLT"=>rand(0,335),"LAS"=>rand(0,335),"PHX"=>rand(0,335)), array(""=>"May", "ATL"=>rand(0,335) , "ORD"=>rand(0,335),"LAX"=>rand(0,335),"DFW"=>rand(0,335),"DEN"=>rand(0,335),"JFK"=>rand(0,335),"SFO"=>rand(0,335),"CLT"=>rand(0,335),"LAS"=>rand(0,335),"PHX"=>rand(0,335)), array(""=>"June", "ATL"=>rand(0,335) , "ORD"=>rand(0,335),"LAX"=>rand(0,335),"DFW"=>rand(0,335),"DEN"=>rand(0,335),"JFK"=>rand(0,335),"SFO"=>rand(0,335),"CLT"=>rand(0,335),"LAS"=>rand(0,335),"PHX"=>rand(0,335)), array(""=>"July", "ATL"=>rand(0,335) , "ORD"=>rand(0,335),"LAX"=>rand(0,335),"DFW"=>rand(0,335),"DEN"=>rand(0,335),"JFK"=>rand(0,335),"SFO"=>rand(0,335),"CLT"=>rand(0,335),"LAS"=>rand(0,335),"PHX"=>rand(0,335)), array(""=>"August", … | |
How to make popup login and register from index.php to work and to parse data in mysql I have: Index.php, login.php, register.php In index.php I have modal popup and I want to user can login and register from popup. I try with ajax but not working. Here is my code: … | |
Hello, I tried to created a social networking system in which I created a part of adding friends so the problem I am having if the firend is not in his are like he searched a friend normally so that friend is not in his system so it show as … | |
Focus not working. What is the error in my code Dynamic Textbox Code: select query $i =1; while() { <input type="text" name="class_teacher_entry[]" id="class_teacher_entry<?php echo $i; ?>" class='marks' size="5" maxlength="3" onkeypress="return onlyNumbers(event);" onblur="markValidation(this.value,document.getElementById('marktotal').value,<?php echo $i; ?>);"/> } <Script> function markValidation(a,b,i) { var c = parseInt(a); var d = parseInt(b); if(c>d) { … | |
Here's a fun one... How would you solve a basic simultanous equation with PHP? I have an array with a range [high,low] of [378,395] and I want to normalise the data in that array between the values of [-1, 1]. From that, using `x => ax + b`you get the … | |
The website has to connect to internet time, instead of the local time via computer. Any ideas? | |
Would be really appreciated your help.I have a code like this: i need to display a total figure for passengers carried on each route and in each month and highlight in green the best performing route and highlight in red the worst performing route.I constraced those tables and now stack. … | |
Hi all, I am using a for statement to generate lots of arrays, example: Array ( [0] => 2 [1] => 395.0 [2] => 0.33 ) Array ( [0] => 3 [1] => 394.0 [2] => 0.81 ) But, I want to have them all within 1 array, example: Array … | |
[CODE]<?php // CONFIGURATION ****************************************************************************** $dbHost = "Example.com"; // MySQL host $dbUser = "shen"; // MySQL username $dbPass = "XXXXXXX"; // MySQL password $dbDatabase = "shen_080892"; // MySQL database name $username = "shen08089296"; // Login Username $password = "XXXXXX"; // Login Password $logspage = 100; // Number of logs per page … | |
I am uploading max 5 images and i want to create the thumbnails of those 5 images i am successful in uploading and saving image name in database but can't able to make thumbnails. //controller $files = $_FILES; $cpt = count($_FILES['uploadfile']['name']); for($i=0; $i<$cpt; $i++) { $_FILES['uploadfile']['name']= $files['uploadfile']['name'][$i]; $_FILES['uploadfile']['type']= $files['uploadfile']['type'][$i]; $_FILES['uploadfile']['tmp_name']= … | |
Dear friends,help me please,i have a php array,how would i display table out of it,something went wrong : <?php $data = array( array ( "Hartsfield Jackson Atlanta International","Atlanta" , "ATL" ), array ( "Chicago O'Hare International", " Chicago", " ORD" ), array ("Los Angeles International", " Los Angeles", " LAX" … |
The End.