Title: [Plugin: WordPress Form Manager] 0 kb attachment bug
Last modified: August 20, 2016

---

# [Plugin: WordPress Form Manager] 0 kb attachment bug

 *  Resolved [revok](https://wordpress.org/support/users/revok/)
 * (@revok)
 * [14 years, 11 months ago](https://wordpress.org/support/topic/0-kb-attachment-bug/)
 * Hi, first of all thanks for the awesome plugin.
    I’m having problems with the
   attachment button, here is what happens: I choose the file, upload it, and the
   form is posted on a post / emailed too. OK
 * But when I see the post/email, under “attachment” I see “0kb” , but if I look
   at the DATA field in Form Module Settings I see perfectly the attachments and
   I’m able to view them, so it should be just a bug of visualization in the generated
   post/email.
 * **1st question**: is there a way to show the attachment link in the post and 
   email?
    **2nd question**: is there a way to show to registered users, inside 
   a page or post, the same data table I view on DATA in the FORM MODULE Settings?
 * Thanks!

Viewing 14 replies - 1 through 14 (of 14 total)

 *  Plugin Author [hoffcamp](https://wordpress.org/support/users/hoffcamp/)
 * (@hoffcamp)
 * [14 years, 11 months ago](https://wordpress.org/support/topic/0-kb-attachment-bug/#post-2116459)
 * Yes, thats a bug. It will be fixed in the next update. As for your questions,
   there isnt a way to do either of those things yet, but those are good ideas. 
   I will see what I can do.
 *  Plugin Author [hoffcamp](https://wordpress.org/support/users/hoffcamp/)
 * (@hoffcamp)
 * [14 years, 11 months ago](https://wordpress.org/support/topic/0-kb-attachment-bug/#post-2116746)
 * Version 1.5.0 fixes the bug.
 * About 2nd question, do you mean the data table along with the edit / delete options,
   or just the table style format for data?
 *  Thread Starter [revok](https://wordpress.org/support/users/revok/)
 * (@revok)
 * [14 years, 11 months ago](https://wordpress.org/support/topic/0-kb-attachment-bug/#post-2116751)
 * Thanks for the fix! now the name of the attachment works (even if I don’t understand
   why now the form send the mail 6 times, but maybe there’s a problem in my settings)
 * I was wondering:
 * 1) would be possible to find a way to make that attachment downloadable/click-
   able from the email/post?
 * 2) would be very handy to be able to post in a page/post, for registered users,
   the same view (maybe without IP), the table view you have in “Edit Form-> Data”,
   and then making the title click-able, so that would sends you to the posted version
   that has been created already for each send.
 *  Thread Starter [revok](https://wordpress.org/support/users/revok/)
 * (@revok)
 * [14 years, 11 months ago](https://wordpress.org/support/topic/0-kb-attachment-bug/#post-2116752)
 * for the 2) I think would be handy put the link of the table into an iframe inside
   a page so that it will be automatically updated when somebody send something,
   just an idea btw
 *  Thread Starter [revok](https://wordpress.org/support/users/revok/)
 * (@revok)
 * [14 years, 11 months ago](https://wordpress.org/support/topic/0-kb-attachment-bug/#post-2116753)
 * edit: it still sends the form multiple times, first try, 6 times, next try, 11
   times,third try 11 times.. (so 11 emails + 11 posts +11 fields in the Data table)
   have you checked that?
 *  Thread Starter [revok](https://wordpress.org/support/users/revok/)
 * (@revok)
 * [14 years, 11 months ago](https://wordpress.org/support/topic/0-kb-attachment-bug/#post-2116757)
 * after I pressed Reset Templates everything is back to normal, I mean, now I send
   1 email/post at time, so was my config problem. sorry
 *  Plugin Author [hoffcamp](https://wordpress.org/support/users/hoffcamp/)
 * (@hoffcamp)
 * [14 years, 11 months ago](https://wordpress.org/support/topic/0-kb-attachment-bug/#post-2116780)
 * That is a very strange problem, about the multiple e-mails and posts. I’m glad
   you were able to fix the problem, but I’m curious as to what caused it specifically.
   Had you modified the default templates at all?
 *  Thread Starter [revok](https://wordpress.org/support/users/revok/)
 * (@revok)
 * [14 years, 11 months ago](https://wordpress.org/support/topic/0-kb-attachment-bug/#post-2116781)
 * the only problem I noticed is when I tried to update the plugin, first of all
   said that I didn’t have the original files anymore, so it somehow self-uninstalled
   from wp installation, then I installed over it the new one, and had the multiple
   email problems, and then, I did a reset of the template and all went to normal..
   dunno maybe some files got corrupted in the process.
 * Anyway, I remind you the other two questions
 * 1) would be possible to find a way to make that attachment downloadable/click-
   able from the email/post?
 * 2) would be very handy to be able to post in a page/post, for registered users,
   the same view (maybe without IP), the table view you have in “Edit Form-> Data”,
   and then making the title click-able, so that would sends you to the posted version
   that has been created already for each send. (I think would be handy put the 
   link of the table into an iframe inside a page so that it will be automatically
   updated when somebody send something, just an idea btw )
 * the 1st is the most important btw, cause it’s pointless to have in email/post
   a strin saying “filename.jpg” but you can’t click it to retrieve it, and for 
   that you can just go to the admin dashboard and click on the DATA to retrive 
   the uploaded file.
 * apart from that, thanks very very much for your fast replies, I’m using your 
   plugin for a website project I’m doing for a thesis, so it’r really important
   your help 🙂
 *  Plugin Author [hoffcamp](https://wordpress.org/support/users/hoffcamp/)
 * (@hoffcamp)
 * [14 years, 11 months ago](https://wordpress.org/support/topic/0-kb-attachment-bug/#post-2116782)
 * First let me explain an important technical point: when WP updates a plugin, 
   it first removes the entire directory, then copies the new files into it. Everything
   from the previous version is deleted when you update. So unless you do something
   special, your files are lost. This is normal behavior, except, I have coded my
   plugin to take a snapshot of the /templates directory, so that in the event of
   an update, it remembers which files were there to begin with. It will also replace
   any files you delete manually, which is why you have to remove them from the 
   plugin admin. Basically, keeping the template files across updates is something
   my plugin does as a feature, it is not the normal behavior. That being said, 
   it is a bit of a hack, and I’m not positive it works in all cases, just all the
   cases I’ve tried. The ‘reset templates’ is more of a panic button, for exactly
   this reason.
 * Which brings me to your idea about the download link. The problem when designing
   the upload system in the first place was that keeping the files in a directory
   would be just fine, until you updated the plugin, at which point you would lose
   all of your files. I thought about doing the snapshot method like for the /templates
   directory, but this would literally double the amount of HDD space required, 
   since the files would be present both on disk _and_ in the database. So ultimately
   I just put the files in the database. Which means that to download an uploaded
   file, I have to create it on the spot. This works fine in the backend, because
   I can be certain the time between file creation and access is limited, and I 
   can be safe in clearing the temporary files whenever an admin logs in. In order
   to create a download link in an e-mail, I would have to make the files persist
   for much longer, which means I have to schedule an event for your server to do
   later, and I also have to put the file somewhere where your WP install will let
   the public access it, as in, from a link in an e-mail. I’m not certain how to
   do this just yet, but its an interesting problem and I’ll figure something out.
   But only because its for a thesis!
 * Also thank you for clarifying your second idea. I think its a great one and I’ve
   put it on the list of things to implement.
 *  Plugin Author [hoffcamp](https://wordpress.org/support/users/hoffcamp/)
 * (@hoffcamp)
 * [14 years, 11 months ago](https://wordpress.org/support/topic/0-kb-attachment-bug/#post-2116790)
 * I just posted 1.5.2. I add an option to specify an upload directory for the ‘
   file’ element, and a URL pointing to that directory, if you want to have links
   to the files.
 *  Thread Starter [revok](https://wordpress.org/support/users/revok/)
 * (@revok)
 * [14 years, 11 months ago](https://wordpress.org/support/topic/0-kb-attachment-bug/#post-2116791)
 * wow that was fast, thanks man!
    I was trying it, but there’s a thing I don’t 
   understand, let’s say that I want to save the files into this folder “[http://localhost/wordpress/wp-content/themes/files/&#8221](http://localhost/wordpress/wp-content/themes/files/&#8221);
   and I put this in Upload URL field, and all is ok, I get redirected there, but
   I don’t understand what should I put in UploadDirectory? I need an example of
   the path I should put there, cause right now it’s not saving, and so I get “file
   not found”. Lemme know and thanks!
 *  Plugin Author [hoffcamp](https://wordpress.org/support/users/hoffcamp/)
 * (@hoffcamp)
 * [14 years, 11 months ago](https://wordpress.org/support/topic/0-kb-attachment-bug/#post-2116793)
 * A URL is the address that your web browser sends to the server. A directory is
   part of the server’s filesystem, where one of the directories corresponds to 
   the site’s base URL. I would look up the difference elsewhere if thats confusing…
 * If you have [http://www.something.com/uploads](http://www.something.com/uploads)
   for your uploads, put that as the URL and put %doc_root%/uploads for the directory.
   The %doc_root% thing is a shortcut I added so you don’t have to know the dirctory
   structure of your server. Hope that helps.
 *  Thread Starter [revok](https://wordpress.org/support/users/revok/)
 * (@revok)
 * [14 years, 11 months ago](https://wordpress.org/support/topic/0-kb-attachment-bug/#post-2116794)
 * perfect, now it’s working, thank you so much!
 *  Plugin Author [hoffcamp](https://wordpress.org/support/users/hoffcamp/)
 * (@hoffcamp)
 * [14 years, 11 months ago](https://wordpress.org/support/topic/0-kb-attachment-bug/#post-2116840)
 * For 1.5.10 I added a ‘table’ display. Its not equivalent to the data page in 
   the admin, and it does not auto-refresh, but it does give links to the posts /
   file uploads if they exist. If you use the ‘formdata’ shortcode and add ‘table’
   as an argument, as in :
 * `[formdata (slug) table]`
 * This will display the data as a table. The same arguments for formdata apply,
   like how many per page, what to sort the table by, etc.

Viewing 14 replies - 1 through 14 (of 14 total)

The topic ‘[Plugin: WordPress Form Manager] 0 kb attachment bug’ is closed to new
replies.

 * ![](https://s.w.org/plugins/geopattern-icon/wordpress-form-manager.svg)
 * [Form Manager](https://wordpress.org/plugins/wordpress-form-manager/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wordpress-form-manager/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wordpress-form-manager/)
 * [Active Topics](https://wordpress.org/support/plugin/wordpress-form-manager/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wordpress-form-manager/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wordpress-form-manager/reviews/)

 * 14 replies
 * 2 participants
 * Last reply from: [hoffcamp](https://wordpress.org/support/users/hoffcamp/)
 * Last activity: [14 years, 11 months ago](https://wordpress.org/support/topic/0-kb-attachment-bug/#post-2116840)
 * Status: resolved