On 26 August 2010 07:38, Bob Smith <[email protected]> wrote:
> I have table being filled by a partial. When the fields are filled,
> the fields end up together or not there for half a page. See below. My
> controller code and views are below..
>
> controller:
>   �...@single = Array.new
>    for @h in households do
>      if @h.people.count == 1
>         �...@single << @h
>      end
>    end
>
> views:
> christmas.html.erb
> <table border=1 width="25%">
>        <th>Single Families</th>
>        <col>
>        <%= render :partial=>"christmas", :collection => @single %>
> </table>
>
> _christmas.html.erb
> <tr><td><%= h(christmas.name) %></td></tr>
>
> The output is:
>
>  Single Families
> Amanda Axxrn
> Paula xxxk
> Michael BxxxxRxxond Baxxt
> Carl Lxxxe Bexx
> Robert BxxxxxrdBetsy xxxxxuJason BrxxxnKeith Bxxxn
> Frances Brxxxle
> [...]

Firstly have a look at the generated html (View, Page Source or
similar in the browser) and see if it is what you expect.  If it looks
ok then copy and paste it into the w3c html validator (google for it)
to check it is valid.  See if that shows anything.

I am not sure what the <COL> tag is for there.

Colin

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to