Hello, I wanted to report a strange thing, after creating a file field to insert a document for downloading, if I want to modify it, going to click on the pen, (see image),
it doesn’t let me do it, I still have the document I have previously entered,
what should i do?
I wanted to ask how can I delete the pen icon by modifying the php code
Not sure you’ve given enough information. I what are you trying to accomplish?
my idea is to create a document tree, with posts, inserting a file field, for download, but I can’t replace the documents already inserted. I can only delete them and insert the new file, without changing an entry already made (using the pencil icon). I hope I explained myself.
That is they only way with only ACF to change the file, remove and insert a new one. If you want to replace and existing file try this https://wordpress.org/plugins/enable-media-replace/
ok, but what is the purpose of the pen button?
is there a way to delete the button by acting on the php?
The pen button opens the standard WP edit screen for the file. This works the same as if you went to the media folder and opened the WP editor for it from there. You can’t delete the button, but you can probably hide it with some custom CSS added to the admin of your site.
Ok thank-you,can you kindly tell me, the name of the div, which I have to hide? Thanks.
I solved the problem by myself.
In the file class-acf-field-file.php
<a class="acf-icon -pencil dark" data-name="edit" href="#" title="<?php _e('Edit', 'acf'); ?>"></a>
You must be logged in to reply to this topic.
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
© 2020 Advanced Custom Fields. Subscribe