Skip to content
Advertisement

Tag: php

Unable to unzip large Linux zipped archive in Windows

Server environment: Linux RHEL5 x86_64, Apache, PHP Client environment: Windows 10 64 bit (VirtualBox MacOS host), 4GB Ram, 30GB free space, Browser IE11 (also tested with Edge/Firefox), 7zip The scenario is the following: I upload a zip (there is a file inside the archive that is 2.5GB) via browser to my PHP web server, SHA2 checksum match when the zip

PHP passthru execution status

I’m trying to use the PHP passthru function to execute an OS command on Linux. I am using it as follows. The Linux command is just to list files in a directory I know does not exist and then I am just echoing the status to make sure it’s not 0. However the status seems to be the entire output

How to restrict PHP file access to execution directory?

I have a bunch of PHP scripts inside of, say, /public_html/mydir/, and these scripts may possibly try to delete files / do other stuff to the filesystem. I want to allow all filesystem modifications within the /public_html/mydir/ directory, but any access (or deletion) outside of the mydir directory shouild not be allowed. How can I do this? Answer You either

PHP pthreads failing when run from cron

Ok, so lets start slow… I have a pthreads script running and working for me, tested and working 100% of the time when I run it manually from the command line via ssh. The script is as follows with the main thread process code adjusted to simulate random process’ run time. So while the above script will run via a

cURL empty request data if https connection

I try to send the file via POST. Before that i used http connection and everything worked. But now var_dump($_REQUEST); in my php-file returns an empty array. This my curl log: $ curl -X POST -F “id=1” -F “file=@/tmp/file.txt” https://MY_DOMAIN/save_file.php -v Hostname was NOT found in DNS cache Trying MY_IP… Connected to MY_DOMAIN (MY_IP) port 443 (#0) successfully set certificate

PHP isn’t able to read file

I’m stuck trying to open a file with fopen in php. I checked following items: chmod for statuseing.php 0777 owner is www-data with groud www-data script is running as user www-data groups are uid=33(www-data) gid=33(www-data) groups=33(www-data) pwd is /var/www/html as expected the path the scripts want’s to open is correct checked openbase dir in php.ini showed in phpinfo(), added /var/www/html,

can’t upload file to wordpress

I move my wordpress website to my vps with Cpanel, after move every thing is working well, but my media option can’t upload file to my library, I try to set permission for uploads folder and subfolders to 755,775 even 777 but media uploader get me this error : The uploaded file could not be moved to wp-content/uploads/2016/10. I try

Advertisement