I have a problem with the GD functions. When I upload an image on localhost, everything works fine, and a thumbnail is created, but when I upload my website on hosting then imagecopyresized just fails. When I insert in a blank page, that function (whole resize function), it works just fine.
What could be the problem?
Actually, when the upload function try to upload the file then the GD functions don't work.
If your scripts work fine on a blank (free and not bound) page, then the problem surely goes to the CMS you are using. It may redirect to htaccess file you are using or even some specifications of your website.
Related
on my computer the website works fine.
when I upload the website the the server the images and css does't work.
I've tried to solve this problem myself but failed.
I had some problem. Do not upload site with file zila or total commander they can loose some files.
Upload site directly using c-panel, zip-it and upload.
If this dont work call administrator
I have some photos on my iPhone I would like to upload to my website. However, when I try to upload it fails. Some of the errors I received were File name cannot be empty and File is not an image. The thing is when I download a image from the web it works just fine. What am I not understanding here? I am using PHP to upload files to the folder. The example I followed was on W3schools Thanks to all that help.
I'm trying to move images from one folder to another. I'm using the following code:
rename("/public_html/wp-content/uploads/image.png","/public_html/wp-content/uploads/folder/image.png");
The image gets moved fine to the new folder and the new path is accessible, only the image breaks. It gets a file size of 0.01k and shows the broken image icon.
I'm using the same rename function for files and folders and everything gets moved without any problems. What could be the problem for the images?
EDIT: The problem only seems to occur when the code gets fired from an ajax request. If I load the same code directly it works fine. If it gets loaded from ajax the image breaks.
I'm using the Smart Image Resizer plugin to resize images. I've been testing on a local server for a while, and now when I uploaded to the server, the image doesn't pull up.
There's really no code to post-has anyone ever had this problem, and if so, is there a solution?
Thanks!
Found the error-I had changed the code to go into a specific directory for the images. The script was removing the slashes from the image variable, so it was looking for imagesIMG_1234.JPG instead of images/IMG_1234.JPG.
Thanks!
I made a class that converts a string of text into a png image and uploads on the server:
http://testing.mehhh.org/php/png.php (you can view php source on the page)
http://testing.mehhh.org/php/phg.php <-- shows php version
this one works great.
now I am trying to get this to work on a clients server
http://autoxplorer.com/~tameem/png.php This doesn't work!
http://autoxplorer.com/~tameem/php.php <-- also using same php version
what gives? I thought it's a permission thing.. but the png folder has full access.. and I tried a super simple uploading script and it runs and saves files to that folder. What is going on here?
You have just put online some PHP scripts that link to images. The link to the images actually is different.
http://testing.mehhh.org/php/png/4de9441d68cf8_1307132957.png
http://autoxplorer.com/~tameem/png/4de9424d41208_1307132493.png
While the first link returns actually an image, the second image link gives a 404 error. Looks like you have not configured your server properly to actually execute the PHP in the second case to return an image.