Skip to content
Advertisement

Tag: file

Files in directory not in order

I use this code to list all files in directory: But, the result is not in the numerical order. How can I fix it? Answer Get a list of all the filenames, then you can use a sorting function.

Weird file in php (xampp)

I could not find anything anywhere on the internet explaining what you can see in the screenshot. This is in my xampp folder (as you can see at the top of the screenshot), there is a file why.tmp which was apparently created in 2013. I got this PC in 2017 and now it’s 2020. You can also see the content

List and download clicked file from FTP

I have FTP and I need list all files in FTP in uploads directory and after click on any listed file it will download the specific file from FTP. It list my files in uploads directory but when I will try to download file so it types me “no file” My code: Answer Your link in the generated <a> tag

How can I omit Helvetica with TCPDF?

I’m making a PDF with TCPDF, and I’m trying to make the file as small as possible. The font I’m using is Open Sans. I’m not (intentionally, at least) using Helvetica anywhere in the PDF. When I view the included fonts with Adobe Reader in my outputted PDF file, both Open Sans and Helvetica are listed. I have noticed that

Reading floats from binary file javascript

I’m trying to read floats in javascript from a binary file that is created using Java. The file is created in Java using DataOutputStream: The file is retreived by http request and read like this: dataLoaded function: Output: Expecting: The file is sent with php: It seems that somewhere there is a flaw in the conversion but I can’t figure

Laravel 5.3 multiple file uploads

How can I upload multiple files in Laravel 5.3. If I try it with 1 image it works but multiple images are not uploaded. This is my code: if($request->hasFile(‘attachment’)) { foreach($request-…

Chmod 640 for uploaded file after SUPEE 7405 patch

After installing the SUPEE 7405 patch, we noticed a problem uploading images from the admin. All file permissions are being set to CHMOD 640 which makes them inaccessible to all users. Is there a solution that does not involve rewriting the /lib/Varien/File/Uploader.php file? Answer A new version of SUPEE-7405 has been released that resolves this issue: http://magento.com/security/patches/supee-7405 Updated February 23,

How to copy very large files from URL to server via PHP?

I use the following code to copy/download files from an external server (any server via a URL) to my hosted web server(Dreamhost shared hosting at default settings). However the function stops running at about once 2.5GB (sometimes 2.3GB and sometimes 2.7GB, etc) of the file has downloaded. This happens every time I execute this function. Smaller files (<2GB) rarely exhibit

Advertisement