# Simple Captcha - files still in "/tmp" directory and not displaying

**URL:** <https://www.ruby-forum.com/t/simple-captcha-files-still-in-tmp-directory-and-not-displaying/194755>\
**Category:** Rails\
**Created:** [September 9, 2010, 11:35pm UTC](https://www.ruby-forum.com/t/simple-captcha-files-still-in-tmp-directory-and-not-displaying/194755 "2010-09-09T23:35:06Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![andy](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/aeb1de/32.png) [@andy](https://www.ruby-forum.com/u/andy)\
**Post date:** [September 9, 2010, 11:35pm UTC](https://www.ruby-forum.com/t/simple-captcha-files-still-in-tmp-directory-and-not-displaying/194755/1 "2010-09-09T23:35:06Z")

</div>

I’m trying to use the Rails3 Simple Captcha version from here:

> **[GitHub - galetahub/simple-captcha: Rails 3 support now! Simple Captcha is the...](https://github.com/galetahub/simple-captcha)**
>
> Rails 3 support now! Simple Captcha is the simplest and a robust captcha plugin. Its implementation requires adding up a single line in views and in controllers/models. - GitHub - galetahub/simple-...

It’s working 100% fine on my local environment.

In Production, I had to point the “convert” command to the correct  
directory and then reinstall ImageMagick with the FreeType lib.

Now I’m not getting any errors in production.log but the images are  
coming up as broken images.

Any ideas?

---

<div class="post-metadata">

**Author:** ![andy](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/aeb1de/32.png) [@andy](https://www.ruby-forum.com/u/andy)\
**Post date:** [September 10, 2010, 1:00am UTC](https://www.ruby-forum.com/t/simple-captcha-files-still-in-tmp-directory-and-not-displaying/194755/2 "2010-09-10T01:00:35Z")

</div>

I’m starting to narrow down the problem.

The files are being created in the “/tmp” folder.

But when image.rb passes it up to simple\_captcha\_controller.rb, the  
files are coming through empty.

The versions in “/tmp” are not empty files though.

I’m using a CentOS server I configured myself (rather than a Rails  
host like EngineYard) so I’m guessing it’s some sort of server  
issue.

---

<div class="post-metadata">

**Author:** ![andy](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/aeb1de/32.png) [@andy](https://www.ruby-forum.com/u/andy)\
**Post date:** [September 10, 2010, 1:09am UTC](https://www.ruby-forum.com/t/simple-captcha-files-still-in-tmp-directory-and-not-displaying/194755/3 "2010-09-10T01:09:57Z")

</div>

Found the solution:  
[https://rails.lighthouseapp.com/projects/8994/tickets/4063-rails-30-beta1-send\_file-with-0-byte](https://rails.lighthouseapp.com/projects/8994/tickets/4063-rails-30-beta1-send_file-with-0-byte)
