# Soft Ball? Validating either-or fields

**URL:** <https://www.ruby-forum.com/t/soft-ball-validating-either-or-fields/163303>\
**Category:** Rails\
**Created:** [March 19, 2009, 3:54am UTC](https://www.ruby-forum.com/t/soft-ball-validating-either-or-fields/163303 "2009-03-19T03:54:39Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![blacknight](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/c68b51/32.png) [@blacknight](https://www.ruby-forum.com/u/blacknight)\
**Post date:** [March 19, 2009, 3:54am UTC](https://www.ruby-forum.com/t/soft-ball-validating-either-or-fields/163303/1 "2009-03-19T03:54:39Z")

</div>

I have a situation where the user will either put text into a text-  
area or upload a file (ala attachment\_fu). I need to check if either  
field has data (both is okay, too). Any suggestions?

thanks in advance.
