39,320 Topics
| |
please can anyone help me with the code on how to generate pin. | |
Main content <?php echo $test; include "index.php?test=solved"; echo $test; // expected: "solved" if (isset($_get["test"])){ $test = $_get["test"]; } ?> File ends here error starts here. Notice: Undefined variable: test in C:\-------\XAMPP\htdocs\index.php on line 4 Warning: include(index.php?test=solved): failed to open stream: No error in C:\-------\XAMPP\htdocs\index.php on line 5 Warning: include(): Failed … | |
I am starting a new project and I dont have experience in PHP in general. To help me up and speed things up some of my coworkers told me about CakePHP and Yii. I want to make a hotel reservation system (frontend and backend) and I was wondering wich to … | |
Hi All, I'm battling to get this query to work. I have a select form that allows user to select dates. When he submits it it needs to remove weekends from the request. $DateStart='2013-09-01'; $DateStart='2013-09-05'; $DateSTR=strtotime($DateStart); $DateSTO=strtotime($DateStop); for($i=$DateSTR; $i<=$DateSTO; $i++){ $NewDate=strtotime($i); $DateCalc=date('D', $NewDate); $TotalCount++; if($DateCalc == 'Sat' || $DateCalc == … | |
Hi Everyone, I am using the following slugify script and would like to concatenate two php variables. The two variables I would like to concatenate are $firstname & $surname. The end result should be firstname-surname. function slugify($text) { // replace non letter or digits by - $text = preg_replace('~[^\\pL\d]+~u', '-', … | |
*Yes, the reoccurring issue* I have yet to solve: Posting the contents (Saved to a DB) of a form to a redirected page. Everything works except the rendering of the form data on the redirected page. I've been trying everything that I can think of. I've been researching this for … | |
I am trying to upload multi-images I am using this script everything is fine and the images uploaded successfully the problem here is I don't want to duplicate the images name so I used this script to avoid this but no luck any idea this is my code <?php if(isset($_POST['submit'])){ … | |
I call it "Compartmentalization", that is, taking a long .php file and breaking it down into smaller components; Seperate .php files. This will keep everything tidier, cleaner, more organized, reusable and I believe, more secure. **Example** (Not my code - Maybe not a *perfect* example of this idea, but for … | |
I want to use calander to pick a date as DD.MM.YYYY and post to database. Please help............ Entry.php <?php require 'config.php'; if (isset($_GET['logout'])) { unset($_SESSION['isLogged']); unset($_SESSION['isLogged']); session_destroy(); header('location: index.php'); exit; } if (!isset($_SESSION['userLogin']) && !isset($_SESSION['isLogged'])) { header('location: index.php'); exit; } ?> <!doctype html> <html> <head> <meta itemprop="image" content="mainlogo_title.png"> <title>SEA TURTLE … | |
I need to redirect specific URLs to their new equivalent. i have a single dynamic page(pages.php) and i fetch data from database.(like domain_name.com/pages.php?id=4) and i want to redirect to domain_name.com/pages/name or domain_name.com/name on same page with different names(for example if pages.php id=4(example- domain_name.com/pages.php?id=4) and id 4 have name welcome then … | |
I am new in web and PHP want to learn about session... how they are made on login... and how they are carried to next page... i know to make database and queries.. | |
Hey guys! I'm working on an open-source video game and things are going well enough, except for the part where I'm trying to work around my n00bish socket-programming background to build the server component. I had the server software working from a single-user perspective, but when I tried to add … | |
I've been having tonnes of issues with Mod Security. I am busy writing a CMS for a project at work and while developing a page to edit a certain database record I kept getting 403 errors. After hours of banging my head against my desk, adjusting bits of code I … | |
Hey everyone, Hope everyone is doing well! So I might seem a little dumb to post this but I've googled and searched every possible thing I can think of to get my contact form to work and send an email. The validation, which in this case is defaulted to jquery … | |
plugin for admin panel in which user can login on its ftp details and download all files(.csv I have Ingram Micro products details) and show only check information on sites.so any plugin is available for that ?? | |
Hi Any one ever wrked on live helper chat? [This](http://livehelperchat.com/) This is following template structure may be symfony or smarty and I am looking to change some form labels, but cannot figure out where to chage? Thanks in advance for help | |
Dear all! I am creating a proxy website, which will open a restricted site. Proxy is working very fine and I am happy with it.Now there is a site which only allow in my clients country. Site need username and password to allow user to view contents, Now I want … | |
Here, i'm trying to fetch the image from database. In my database i can see a image file size ([BLOB - 62.3 KiB]). But, it didn't work. i didn't get any error here. i'm confused where i made a mistake here? <?php include('config.php'); ini_set('display_errors', '1'); error_reporting(E_ALL); try { $stmt = … | |
Recently i've rewritten my code to PDO from mysql query. Insert, fetch, update, delete everything working fine. But, pagination not displaying in my page. Before i've used mysql query. In that time pagination worked perfectly. Now, i've changed my codes into prepared statements. pagination not dispalying i don't know what … | |
hey...i need help with magento...with a travel booking engine integration i have got the directory structure figured in magento. There is this static block where i need the booking form to be put up, then i need to create page where the results are to displayed... i jus dont how … | |
//index.php $img_dir ="C:/xampp/folders/img/*.jpg"; $thumb_width = 100; // Open a known directory, and proceed to read its contents $scan= glob($img_dir); foreach($scan as $image) { $im= imagecreatefromjpeg($image); $img_width = imagesx($im); $img_height=imagesy($im); $thumb_height= floor ($img_height *($thumb_width/$img_width)); $new_img=imagecreatetruecolor($thumb_width,$thumb_height); imagecopyresized($new_img, $im, 0,0, 0, 0, $thumb_width, $thumb_height, $img_width, $img_height); $thumb_path = "C:/xampp/folders/thumbs/"; imagejpeg($new_img,$thumb_path); } The error … | |
Hello Firends, I am developing a fashion website where visitors can come and select branded T-Shirts. Visitors will have to choose Man, Woman or Kid Avatar in order to check out the display of the Clothes. What I need is that, on the COLOUR CATEGORY, if the visitor click on … | |
Hi. I have a mysql field with a record like: [2,5,11]. I have a query like: $query = $this->select() ->from($this->_name) ->where('id = ?', $id); This query work if record is of integer type: 5. Is it possible to create a query to find 5 in the array? Please advise. Thanks. | |
This my site..http://www.vibrationlive.net. I just uploaded the progran to my Godaddy server. And im getting a lot of warnings and notices, how do i turn them off. And here is my php5.ini file (code) allow_url_fopen = off apc.enabled=0 expose_php = Off max_input_time = 60 variables_order = "EGPCS" extension_dir = ./ … | |
Hello, I have csv filename with date. Everyday i have same csv file with respective date. I need to read filename (*everyday date changes in filename*) and do operation. For example, I have file "**cells_20140106_165532.csv**". I did like this to read it in general: $filename = "cells_".date('Ymd_hmi').".csv"; $file_contents = file_get_contents($filename); … | |
anyone have a php code for arranging the inputed value of A B C D, from highest to lowest using if,elseif statement, ty :D | |
Hi Guys, I want to be generating random quote of the day. I want it to be so random and not repeating itself the same quote What is the trick (If code exclude simple db stuffs like mysql_connect et al) Thanks | |
Hi everyone, I am new to PHP. I have a problem. I have a simple HTML form where when I select the country from select / option list provided, i want PHP to echo message on country I selected. Also I want PHP include function to list the form specific … | |
Does anyone know how to move around the tables using PHP. |
The End.