Questions tagged [filesystem]
The filesystem tag has no usage guidance.
15
questions
0
votes
1
answer
42
views
Magento cron jobs fail because of attempts to write to the wrong part of the filesystem
I noticed for a while that although I could run the commands in my crontab just fine, they would not run from cron itself; when I looked at magento.cron.log, I found lines like this:
Directory "...
0
votes
1
answer
99
views
How to save Magento 2 invoice PDF file with order ID instead of date?
When I print any invoice in Magento 2 the pdf save according to the current date I am saving it as for example
invoice2023-05-10_05-58-26.pdf
Instead, I wanted to save this pdf with order id like
...
0
votes
2
answers
803
views
Move pub/media/catalog and /downloadable files to another server?
Is it possible, with Magento 2 to move product images and downloadables files (attached to downloadable products type, and sold) to another server and keep things still working ?
I'm not talking about ...
0
votes
1
answer
1k
views
How to get product image full file path directory in magento 2?
I have a custom extension that needs the full path directory file of the product image not the URL of the product image, for example:
/var/www/Mage2Dir/pub/media/catalog/product/d/i/base_image_product....
0
votes
1
answer
1k
views
Delete a file from directory magento 2
Is there any way to delete files from var directory, if the file name matched with a condition. I need to delete log files based upon given date. Please let me know how to achieve this in magento2?
1
vote
2
answers
128
views
Magento 2 issue diffence CSS content on same file domain/pub/static/.../file.css and domain/static/.../files.css?
I have problem with magento 2.2.7 but cannot find way fix so hope someonce can help.
File name: domain/pub/static/.../file.css and domain/static/.../file.css.
After I changed content of file.css and ...
1
vote
1
answer
6k
views
Magento 2 .htaccess file missing in pub folder
I was recently trying to upgrade my Magento 2.2.7 to Magento 2.3.0 and the following message came up in component dependencies
Found non-writable path(s):
/var/www/vhosts/powermyself.com/httpdocs/pub/...
2
votes
1
answer
3k
views
Magento2: How to get content of file from remote sftp?
I have one requirement in which i need to get zip file from remote sftp and read its data after extract it.
I see there is class Magento\Framework\Filesystem\Io\Sftp which i can use like below.
\...
0
votes
2
answers
142
views
Files uploaded through Manage Attachments changes filename - how to keep original name?
Is it possible to deactivate the auto renaming of file uploaded through manage attachments?
e.g. test.PNG is getting saved as File-1540823510.png on the webserver.
Is there a way to deactivate this ...
2
votes
0
answers
525
views
Css/js/font files not loading in the Admin area - except two
I'm just starting with Magento 2.0 and after realizing I won't be able to use it on my web server (MySQL 5.5) I decided to install it within my local XAMPP environment on Win 10.
Installation went ...
0
votes
1
answer
2k
views
How can I run phpunit commands from any location in CLI?
In Magento 2 documentation "Running Unit Tests in the CLI" is text:
To run all tests, navigate to the Magento base directory and execute
the following command:
$ ./vendor/bin/phpunit -c dev/...
13
votes
4
answers
8k
views
Filesystem best practices
I'm working on some Magento 2 extension that requires reading files from the file system.
When running the php sniffer using the ECGM2 standards, it complains about the fact that I'm using functions ...
1
vote
1
answer
7k
views
Magento 2 external library folder
I am trying to keep the google library files but confused on the destination folder. In magento 1.9 we can kept in lib folder.
Can any one please give the solution for that
0
votes
2
answers
869
views
.php file auto converting to php.suspected
I am facing new problem within 2 days. My Many PHP file are showing extension as suspected. However, i renamed all as earlier , it again came as php.suspected within 8 hrs. Kindly Suggest me the ...
3
votes
0
answers
163
views
Magento 2 filesystem permissions [closed]
In Magento 2 we have a new filesystem permissions guidelines.
Reading this link I understand that Magento requires php user inside www-data group.
What I do not understand is why static filesystem ...