39,393 Topics
![]() | |
I need to get the earliest date and the latest date in the below query. Not sure if the while loop is necessary to achieve this though? I don't need min/max for every tbl_type but the lowest of them all and the highest of them all. // get min and … | |
I have just installed xampp on a windows 7 os and downloaded my working web application into C:/xampp/htdocs/myweb calling the website with localhost/myweb brings up the home page try calling a specific page like localhost/myweb/about.html is redirected to localhost/xampp/ calling a specific page with localhost/myweb/index.php?include=about shows the correct page I … | |
Hello. So I wrote A-star pathing algorith. It is working fine, however it is to slow, if distance between start and finish is big. This "big" isn't really that big. It may take even 30seconds in 11x11 grid... I am looking for some optimization ideas of proffesionals here. Code: <?php … | |
Is the check: if (!isset($_SERVER['HTTPS']) OR empty($_SERVER['HTTPS'])) { // We are NOT using SSL } a fool-proof way of checking if we are NOT using SSL with PHP/Apache? I understand that IIS sets to 'on/off' but that's irrelevant for me. I am just wondering if I additionally need to check … | |
Hi all, I'm not too familiar with Ajax but I believe I grasp the basics. So I'm sending an id which I retrieve from an element to a php page but I can't seem to retrieve the id being send. My javascript: function ListPart(part) { var imgdata = part; $.ajax({ … | |
The API was working fine for the past few months ago..But now I'm getting a notice in that output and message is not delivered. The notice is -" Undefined offset: 1 in C:\wamp\www\sms\sms trial.php on line 90" line 90 in my code is $userID = $match[1]; please help me to … | |
I'm trying to make my button change from saying "Submit" to "Submitting" when it's clicked. But it's for a form so if something like e-mail validation fails I want it to change back to saying "Submit". Here is the code I already have if you would like to take a … | |
Hello, I am trying to create a table which has a sort feature. I mean whenever someone click the table header, the table content must be sorted based on the header. how to do so? Here is my table codes: index.php <!-- Insert New --> <br><br><br><br> <div id="inputberita"> <p> </p> <p> </p><center> … | |
Hi, I use the following code from phpmyadmin to reset one of my table's auto increment value from 1. SET @count = 0; UPDATE `mytable` SET `mytable`.`id` = @count:= @count + 1; ALTER TABLE `mytable` AUTO_INCREMENT = 1; But I want to run this query from PHP file and set … | |
hya i have a website built in php html and javascript and at the moment when a couple registers they go straight to a single persons profile page and i want to going to a couples profile page where both there information is stored how can i do this any … | |
Hello, I have an array that returns city and state in this format: Detroit,MI I want it to be shown as Michigan/Detroit is there any way of doing this? Here is my foreach code: foreach ($i['popularCities'] as $a => $value) { echo '<li>' . $value . '</li>' . PHP_EOL; } … ![]() | |
Dear friends, I have an other problem in login form...my code is below.. //********************************connect to database and check**************************************************** $username = "root"; $password = ""; $database = "mydatabase"; $server = "127.0.0.1"; $conn= new mysqli($server,$username,$password,$database); // checkintin connection if($conn->connect_error){ die("connection failed:".$conn->connect_error); } //****************fetch the information from database for match username and password … | |
I am able to delete the file from the database but not the file found on a folder associated with it...is there somethign wrong? <?php include("../includes/mysqliconnect.php"); include("../includes/config.php"); if(isset($_GET['delpost'])){ $delpho = $mysqli->query("SELECT * FROM photos where imageID=$imageID"); $run=mysqli_fetch_array($delpho); $imageName=$run['imageName']; $dir = '/uploads'; unlink($dir.'/'.$imageName); $stmt = $db->prepare('DELETE FROM photos WHERE imageID = … | |
Hello, I have page with several sections, in each section form with submit button which will load table and execute mysql queries. I need help to make long tables in more pages, or at least make scroll so user don't have to take long time to go from part to … | |
i have 5 rows and i want to store all row data into database but it is storing only last row data instead of all four | |
Problem:On click logout it again shows the html page content which i dont want to show <?php session_start(); if(isset($_GET['action']) == 'logout'){ session_destroy(); unset($_SESSION['user']); unset($_SESSION['pass']); echo '<pre>'; print_r($_SESSION); //header('location:index.php/'); exit(); } if(isset($_SESSION['user'])== ' '){ header('location:index.php'); exit(); } if( !( isset($_SERVER['PHP_AUTH_USER']) && $_SERVER['PHP_AUTH_USER'] == "a" && $_SERVER['PHP_AUTH_PW'] == "a" ) ){ header('WWW-Authenticate: … | |
i have the following code <?php require_once 'includes/initialize.php'; set_include_path( get_include_path() . PATH_SEPARATOR . CHARTS_PATH); require_once "class/pDraw.class.php"; require_once "class/pImage.class.php"; require_once "class/pData.class.php"; // create data set $myDataset = array(0, 1, 1, 2, 3, 5, 8, 13); $myData = new pData(); $myData->addPoints( $myDataset ); $myData->setAxisName( 0, "Numbers" ); // define image object $myImage … | |
| |
first create the table [CODE] create table images ( image_id serial, filename varchar(255) not null, mime_type varchar(255) not null, file_size int not null, file_data longblob not null, primary key (image_id), index (filename) ); [/CODE] the file to output the images to the browser [B]picsrc.php[/B] [CODE]<?PHP //detect if image is called … | |
Hello friends, Please help me to sort out my problem , actually it is strange one and don't know why it appears. Actually I was trying to make a file upload form which I got success although a bit. A bit in the sense, if I include just <form> in … | |
G'day, I'm currently trying to get a input box with a submit button that puts the command into a string and executes it on a detached screen. Currently I have the following: **index.html** <form id="commandForm" method="post" action="command.php"> <input type="text" name="command" /> <input name="sendCommand" id="sendCommand" type="submit" value="Send" /> </form> **command.php** <?php … | |
Hi everyone, i want Php script for regional Language e-paper like http://epaper.pudhari.com/ that because i want same Hard copy paper on to website in that block wise news reading option (e.g. when u select block news it display pop up or new page just see link above e-paper like that) … | |
Dear Team I am creating a html form for data entry in mysql database and want to multiple rows inserted in one time when i filled a row then on enter key press a new row created automaticaly in html and php for more entering data so how is this … | |
Is it possible to list down all files from a folder then have an option to delete them one by one?if so, can you give me the right way to do it?not the code but the step by step tutorial or explanation..well if its a code I just hope I … ![]() | |
I was following a tutorial by codeNmind on Youtube about Facebook SDK V4. I've followed everything, but I keep getting the error that Fatal error: Class 'Facebook\FacebookSignedRequestFromInputHelper' not found in... Anyone with an idea what that could be? And if there is another tutorial you can recommend for posting on … | |
Hey! Long time no speak ^.^ I've been trying to make a query which would follow this logic (Which works in phpMyAdmin): UPDATE member_food SET food_id=12 WHERE member_id=4 AND food_type="breakfast" However, when I do it in PHP: $sql_breakfast1 = "UPDATE member_food SET food_id ='$breakfast1' WHERE member_id='$id' AND food_type='breakfast'"; if ($mysqli->query($sql_breakfast1) … | |
Hello I have 5000 data how can i update one time dbquery("UPDATE ".CATEGORY_TABLE." SET name='".cleanString($data['title'])."'"); | |
Hi Guys I am a rookie here... I have a function which gets information from a postgres database. And returns an array. But how do I echo a single value from the array returned by the function. Please see function below: function getDate($campid) { global $conn,$agencies; $return=array( 'date'=>'', ); $sql … | |
Hello, I had an error while compile this code. Can somebody help me.. I need the answer ASAP..Thank you search.html <form name="form" method="post" action="search0.php"> Search by Matric No.: <input type="text" name="patron_ID" placeholder="Student No."> <input type="submit" name="Submit" value="Search"> </form> search0.php <?php /* include db connection file*/ include("dbconnect.php"); /* capture student number … |
The End.