I am sorry Zhao but I still don't understand the problem. A concrete
example would probably help. However, lets try something here to see
if it helps.

You should be able to split your page and put into partials whatever
parts of the full page you want/need. As long as the final complete
page is valid HTML it should work fine. An example:

Supposing you need to display something like this:
<tr>
  <td>Text A<td>
  <td>Text B<td>
</tr>
<tr>
  <td>Text C<td>
  <td>Text D<td>
</tr>

You could leave in your main page the following:
<tr>
  <td>Text A<td>
  <%= :render :partial => 'your_partial' %>
  <td>Text D<td>
</tr>

And if your partial delivers:
  <td>Text B<td>
</tr>
<tr>
  <td>Text C<td>

Your final product should be what you originally intended.

Another sample based on the original listed above. You cold leave in
your page:
<tr>
  <%= :render :partial => 'your_A_and_B_partial' %>
</tr>
<tr>
  <%= :render :partial => 'your_C_and_D_partial' %>
</tr>

If 'your_A_and_B_partial' delivers:
  <td>Text A<td>
  <td>Text B<td>

And 'your_C_and_D_partial' delivers:
  <td>Text C<td>
  <td>Text D<td>

You would get the expected results.

I hope it helps. If it still does not help send a concrete example of
what the final page should look like and what parts of the page you
want to make partials and I'll try to help.

Pepe

On Jan 2, 3:39 am, Zhao Yi <[email protected]> wrote:
> pepe wrote:
> > Hello.
>
> > I don't see anything wrong with this code. Do you want to do something
> > different than this? I guess I am not understanding the problem?
>
> > On Dec 31 2008, 6:07 am, Zhao Yi <[email protected]>
>
> I mean in this way, I have to split the <tr> tag. Take this partial for
> an example:
>
>     ...
>   </tr>
>   <tr>
>     ....
>
> The other part of the <tr> is in the view page. Have you tried this? I
> got a display problem.
> --
> Posted viahttp://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
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