| robotpoke | i wouldn't agonize over it too much though as that gets in the way of getting things done. besides, what does it really matter, in small projects we're the ones that get to live with our decisions so as long as your resigned to that... you shouldn't have any problems. :) |
| thoraxe | robotpoke: if i want this partial to be available to all views everywhere, do i put it in the views folder? |
| mcarr | does someone know where i can see ajax scaffold in action? |
| robotpoke | ajaxscaffold.com |
| oomwrtu | hi all, i have currency symbols stored in a table and i am generating a select field from that (select 'site', 'currency_id', Currency.find(:all, :conditions => ["is_available = ?", 1]).collect {|c| [ c.symbol, c.id ] } %>) but it prints the ascii code literally... how can i change it so that it prints out the actual symbol? |
| robotpoke | thoraxe: not sure, i haven't had to do that before. can't you give the partial command a path? |
| mcarr | cool, thanks robotpoke: do you know of any good tutorials on how to do uploading gmail style? where it auto uploads the file while you are doing other things? |
| robotpoke | hahahaah, working on that as we speak actually what is your setup? |
| mcarr | mongrel, rails 1.2.1 , |
| thoraxe | robotpoke: no clue, sortof? |
| robotpoke | actually, i've been working on that on and off for the last month |
| mcarr | i was looking at this too: http://mongrel.rubyforge.org/docs/upload_progress.html |
| robotpoke | yeah, i'm just about to start that |
| mcarr | and this: http://kpumuk.info/ruby-on-rails/in-place-file-upload-with-ruby-on-rails/ |
| robotpoke | i looked high and low for other ways to solve the problem. thoraxe: i'd just read up on partials but i'm sure there is a way to share partials across views |
| mcarr | create views/common and do render :partial => 'common/user_form', :object => 'user_form' |
| robotpoke | sean treadway (IIRC) has a page about using the iframe trick as well. |
| mcarr | and put _user_form.rhtml in views/common |
| thoraxe | mcarr: good call |
| robotpoke | the other option is to use something like backgroundrb along with ajax. i have a bunch of links regarding file uploading and tried a few to no avail or they wouldn't work with the host i was using at the time. |
| mcarr | lets stay in touch on this |
| robotpoke | sounds good. i think there is a real opportunity for a tutorial on how to do this from start to finish because it seems like most are old and not necessarily complete |
| mcarr | ya, and making it scalable too |
| oomwrtu | hi all, i have currency symbols stored in a table and i am generating a select field from that (select 'site', 'currency_id', Currency.find(:all, :conditions => ["is_available = ?", 1]).collect {|c| [ c.symbol, c.id ] } %>) but it prints the ascii code literally... how can i change it so that it prints out the actual symbol? |
| robotpoke | yep oomwrtu: my best guess: sounds like you may need to get the html equivalents like ", etc. for all the ASCII chars that are unusual. |
| thoraxe | http://pastie.caboo.se/51823 mccarr, i've created _phonenum.rhtml in views/common |
| oomwrtu | robotpoke: ok, so no storing $ for $ and so on? |
| thoraxe | ah, simple code fix |
| AngryElf | instead of using send_data with Gruff, how do I actually generate an image tag -- currently it's sending a bunch of jumbled stuff to my view "PNG IHDRX" etc. etc.. |
| mcarr | robotpoke: are you using acts as attachment? |
| robotpoke | oomwrtu: i just tried your $ in a .rhtml and it printed a $ just fine i did for a little while. i'm using attachment_fu now |