# Windows users and \`render file: 'path\_to\_file'\`

**URL:** <https://discuss.rubyonrails.org/t/windows-users-and-render-file-path-to-file/68330>\
**Category:** rubyonrails-core\
**Created:** [January 6, 2014, 12:18pm UTC](https://discuss.rubyonrails.org/t/windows-users-and-render-file-path-to-file/68330 "2014-01-06T12:18:55Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Yaw\_Boakye](https://sea2.discourse-cdn.com/rubyonrails/user_avatar/discuss.rubyonrails.org/yaw_boakye/32/9690_2.png) [@Yaw\_Boakye](https://discuss.rubyonrails.org/u/Yaw_Boakye)\
**Post date:** [January 6, 2014, 12:18pm UTC](https://discuss.rubyonrails.org/t/windows-users-and-render-file-path-to-file/68330/1 "2014-01-06T12:18:55Z")

</div>

Unlike developers on \*nix machines, Windows users have to be explicit about rendering file. render can’t figure it out because it tries to find ?/ in it’s first argument if it’s a string or symbol.

‘/’ is the \*nix file separator. Windows uses ''. Ruby’s File::SEPARATOR, since 1.9.x knows the right separator to use depending on the operating system. Using that would let Rails developers on Windows look normal and save them some keystrokes

---

<div class="post-metadata">

**Author:** ![Steve\_Klabnik1](https://avatars.discourse-cdn.com/v4/letter/s/d07c76/32.png) [@Steve\_Klabnik1](https://discuss.rubyonrails.org/u/Steve_Klabnik1)\
**Post date:** [January 6, 2014, 7:30pm UTC](https://discuss.rubyonrails.org/t/windows-users-and-render-file-path-to-file/68330/2 "2014-01-06T19:30:13Z")

</div>

Windows supports both, and so does Ruby: [https://github.com/ruby/ruby/blob/trunk/file.c#L2751-L2756](https://github.com/ruby/ruby/blob/trunk/file.c#L2751-L2756)

---

<div class="post-metadata">

**Author:** ![Yaw\_Boakye](https://sea2.discourse-cdn.com/rubyonrails/user_avatar/discuss.rubyonrails.org/yaw_boakye/32/9690_2.png) [@Yaw\_Boakye](https://discuss.rubyonrails.org/u/Yaw_Boakye)\
**Post date:** [January 6, 2014, 11:44pm UTC](https://discuss.rubyonrails.org/t/windows-users-and-render-file-path-to-file/68330/3 "2014-01-06T23:44:29Z")

</div>

Then the guide on rendering needs an update. It’s says it’s mandatory to specify file when passing a file path argument to render.
