PHP memory limit sometimes makes it problem to upload. please check way to increase your memory limit. Way 1: Modify php.ini Search “memory_limit” in your php.ini, and change the value of it. If no “memory_limit” found, add the following line at the end of php.ini memory_limit = 2568M ; Save file. And restart Apache. Way […]
Read More28 January 2015 Boston: As the date for PHP 7’s release is approaching rapidly, the group is working really hard to fix certain issues by removing the artifacts and adding some features. There are several RFCs on which we can discuss and study a lot more. But here, we are just concentrating on the three main […]
Read MoreMemcache module provides handy procedural and object oriented interface to memcached, highly effective caching daemon, which was especially designed to decrease database load in dynamic web applications. The Memcache module also provides a session handler (memcache). Memcached is a high-performance, distributed memory object caching system, generic in nature, but intended for use in speeding up […]
Read MoreIt is very simple. Just add below code. echo str_replace(array(“\r”,”\n”),””, $str);
Read MoreIt has very simple solution <?php ob_start(); session_start(); ?> Above session write before head section . Like <?php ob_start(); session_start(); ?> <!DOCTYPE html> // html code </html>
Read MoreIt is very simple. PHP random array function : array_rand() http://php.net/manual/en/function.array-rand.php $ran = array(1,2,3,4); $randomValue = array_rand($ran, 1);
Read MoreVery simple <?php // Turn off all error reporting error_reporting(0); ?> Other interesting options for that function: <?php // Report simple running errors error_reporting(E_ERROR | E_WARNING | E_PARSE); // Reporting E_NOTICE can be good too (to report uninitialized // variables or catch variable name misspellings …) error_reporting(E_ERROR | E_WARNING | E_PARSE | E_NOTICE); // Report […]
Read MoreThis is only memory limit problem. you can increase ini_set() function. Hope so it will work.
Read MoreThis is memory limit problem. You can solve your problem several way. Answer 1 : ini_set(‘memory_limit’, ‘-1’); // it mean memory unlimited Answer 2 : If you have access to your PHP.ini file, change the line in PHP.ini try with memory_limit = 64M ; Maximum amount of memory a script may consume (64MB) If you […]
Read More<?php $directory = “folder_name/”; // Folder name of images //get all image files with a .jpg extension. $images = glob($directory . “*.jpg”); $i= 1; foreach ($images as $fileinfo) { $fromImg = “D:/xampp/htdocs/imagesize/”.$fileinfo; // Read all images of you directroy $imageName = “gallery”.$i.”.jpg”; // Rename your own way $toImg = “D:/xampp/htdocs/imagesize/rename/”.$imageName; //Rename images location copy($fromImg,$toImg); $i++; […]
Read More