PLEASE NOTE: These forums are no longer utilized and are provided as an archive for informational purposes only. All support issues will be handled via email using our support ticket system. For more detailed information on this change, please see this blog post.

How to replace an uploaded file?

  1. I am able to incorporate a file upload into a form OK, but if the user wishes to replace that file with a different one, the process runs into an error. Users can access the content they entered in a form via the dashboard widget. When Edit mode is activated, they can click on an "x" button to delete a file, which is then replaced by a Browse button.

    However, even if they browse a new file and then Update, the file is not replaced. I suspect this is not the correct method to do this. What can I do?

    Posted 12 years ago on Monday October 29, 2012 | Permalink
  2. How are you allowing users to access their entry in a widget, and what is edit mode? Those don't sound like core functions in WordPress. How did you add that functionality to your WordPress site?

    Posted 12 years ago on Wednesday October 31, 2012 | Permalink
  3. Ah! I forgot that I am using the Gravity Forms Update Post plugin: http://wordpress.org/extend/plugins/gravity-forms-update-post/

    Perhaps I should contact this developer. This is great feature for websites that are using Post fields as an easy way to publish content without access to the dashboard. I am using this method for a dirt-simple college e-portfolio system. The post revision method (which relates to my original question) is a necessary feature if we use the "form as publish" method.

    Posted 12 years ago on Wednesday October 31, 2012 | Permalink
  4. Yes, that functionality is coming from another plugin and we won't be able to help you troubleshoot that.

    Posted 12 years ago on Wednesday October 31, 2012 | Permalink
  5. ... Also, I am granting Editors access to their form entries via dashboard widget with an added function in functions.php:

    // Giving Editors Access to Gravity Forms
    function add_grav_forms(){
    	$role = get_role('editor');
    	$role->add_cap('gform_full_access');
    }
    add_action('admin_init','add_grav_forms');
    Posted 12 years ago on Wednesday October 31, 2012 | Permalink