Skip to main content

All Questions

Filter by
Sorted by
Tagged with
0 votes
1 answer
97 views

temphangle variable missing when using wp_filesystem copy

I get the following error when using $wp_filesystem->copy(); to copy a file from one destination to another. Undefined variable: temphangle in <b>../htdocs/wp-admin/includes/class-wp-...
RafaSashi's user avatar
  • 497
2 votes
1 answer
1k views

How to append_contents using WP_Filesystem?

I have scenario that appends the contents into the files, I was using normal file system function of PHP Now I have decided to use WordPress WP_Filesystem but I cannot see any methods of it which do ...
Thamaraiselvam's user avatar
0 votes
1 answer
2k views

Right way to download file from source to destination

I'm trying to download a file from one location to another. The code is working perfect. Here is the code snippet: Helper Function - Create directory in /uploads/{$dir_name}/ and return paths. /** * ...
maheshwaghmare's user avatar
0 votes
1 answer
302 views

Should I use Filesystem API for reading files or listing directories?

I know that i should use Filesystem API to write files and I understand why but is there any difference if I read file with wp_filesystem or plain PHP? And what about listing directories? Consider ...
Mateusz Marchel's user avatar