similar to: render_component vs. render_component_as_string?

Displaying 20 results from an estimated 700 matches similar to: "render_component vs. render_component_as_string?"

2006 Aug 14
2
Undefined Method error for call to ''render_component_as_string''- Why?
I want to put a ''search_box'' text_field in the header of each page. This common header template is implemented in ''views/layouts/application.rhtml''. The search_box is implemented in a controller named ''users''. (so ApplicationController is calling an :action in UserController) When I add this line to my
2006 Feb 15
11
VPS hosting
Speaking of hosting, have any of you used a VPS provider that offers gentoo as the VPS OS? All of the ones I know of use fedora, debian, ubuntu, or CentOS. -- - Adam ** Expert Technical Project and Business Management **** System Performance Analysis and Architecture ****** [ http://www.everylastounce.com ] [ http://www.aquick.org/blog ] ............ Blog [
2006 Aug 14
0
undefined method ''render_component_as_string'' - why?
I want to put a ''search_box'' text_field in the header of each page. The search_box is implemented in a controller named ''users''. (so Controller_A is calling a component in Controller_B) When I add this line to my ''controllers/application.rb'' file, I don''t understand why I get and ''undefined method'' error. After all,
2006 Feb 11
1
Retaining multiple select values from action to action?
Suppose I have a multiple select form on an initial page called things[], and two target actions. The initial page submits to target action 1, and target view 1 submits to target action 2. When I submit the form on the initial page, I can access that set of values in target action 1 and turn it into an array of objects by doing something like this (assuming that the option values are object ids,
2006 Feb 17
1
Developing reusable components?
Is there a development guide for best practices when making reusable components? For example, none of the login generators fit my requirements, and I want to write my own. But after I''m done, I''ll want to share it with multiple applications. Is there documentation for the right way to go about doing this? -- - Adam ** Expert Technical Project and Business Management ****
2006 Jun 30
1
using routes.rb from inside a controller / render_component_as_string / generally stumped
Hi, In an action I have a string representing a url for a get request. A simple and seemingly ridiculous example might be something like the following. What I''m trying to do is much more complicated but I think this tiny example shows where I am stuck. Into their browser a user types "http://my.domain.com/admin/category/updates". I have a controller roughly like the following
2006 Feb 12
4
[newbie] if expression "weirdness"
Ok first i am running linux with lighttpd and apache proxy''ing to the lighttpd process. ruby version is ruby 1.8.4 (2005-12-24) [i686-linux] def test @count = Question.count if(@params[:id]) then breakpoint() if (params[:id].to_i > @count) then redirect_to :action => ''finish'' end end end this is a stripped down version of
2006 Feb 10
4
Handling a relationship between users and newsletter subcriptions.
Hey Everyone! I have a newsletter system that contains a multitude of different newsletters. In this case three but the system allows the user to add more. Every user can be subscribed to any amount of given newsletters. So what I did was I created a user model, newsletter model, and subscription model. The subscription model belongs to one user and one newsletter. However,
2006 Feb 09
30
why there is no automatic relationship discovery
When I explain RoR to someone I don''t have a convincing argument that explains why everything is so automatic and transparent, but relationships have to be encoded by hand in models. That shows I don''t understand well that part of AR. There''s the argument that says that not all databases offer metadata about foreign keys, but the natural question then is that,
2009 Aug 11
1
[PATCH server] remove appliance bits
This removes the appliance configuration bits from the installer and associated files since it has been deprecated --- installer/modules/ovirt/files/cobbler-import | 6 - .../modules/ovirt/files/ovirt-appliance-setup | 4 - installer/modules/ovirt/files/ovirt-storage | 73 ---------- installer/modules/ovirt/manifests/appliance.pp | 152 -------------------- 4 files
2006 May 24
22
Components going out of style?
I see in the new Agile Rails 2nd edition that components are going out of style? Is this so? has anybody abandoned the idea of components for helpers? Specifically I''m considering a menu sytem for a website that depends heavily on the users permissions to decide which menu options a user would need to see. I thought that components, since they have the logic in the controller and
2006 Jan 26
21
pagination_links help
I want append custom query parameters to my pagination links, like ?page=1&foo=bar. I can''t quite figure out how to do this with the pagination_links helper, although I believe the API says you should be able to: pagination_links(paginator, options={}, html_options={}) options are: :params: any additional routing parameters for page URLs Has anyone tried this? thanks, jeff --
2006 Feb 24
18
I need more bling!
Hello everyone, I just showed a friend a prototype of a site offering a service I''m trying to sell (sorry, not on the Internet yet - he saw it at my house). His comment: "Looks like it does everything, but also looks pretty ugly. You''re not going to wow anybody with that". Sitting back and thinking about it, he''s dead right - it needs some bling to make it
2006 Feb 08
3
Extends ActiveRecord from the application ?
Hello, I just want to create a method that will be available for all models. Is it possible ?
2006 Feb 22
0
Word wrap?
Say I have a long block of text that has no line breaks. What''s the right way to wrap it at a column barrier? Obviously, I can write the logic for this, but if there''s some way written already, I''ll use that. Suggestions? -- - Adam ** Expert Technical Project and Business Management **** System Performance Analysis and Architecture ****** [
2006 Feb 26
0
ActionMailer view templates don''t pick up application_helper.rb?
It seems that helper methods defined in application_helper.rb aren''t available in ActionMailer views. Is that intentional? -- - Adam ** Expert Technical Project and Business Management **** System Performance Analysis and Architecture ****** [ http://www.everylastounce.com ] [ http://www.aquick.org/blog ] ............ Blog [ http://www.adamfields.com/resume.html ].. Experience [
2006 Feb 28
0
Word wrap regexp question
>From the rails helper, there''s a text wrap method that does this (I''ve removed the trailing .strip): text.gsub(/\n/, "\n\n").gsub(/(.{1,#{line_width}})(\s+|$)/, "\\1\n") The way I read this, it''s "replace every newline with two newlines (and it''s not clear to me either what this first part is supposed to accomplish), then replace
2006 Feb 16
21
RoR VS Rails ???
I didn''t get a chance to go to this meeting debating WebObjects Vs Rails, but here''s a report about it: http://desperatepundit.com/blog/cremes/technology/2006/02/15/WebObjects-versus-Ruby-On-Rails.html I don''t get what he''s saying, hand coding the model? yeah, you COULD ... but what about script/generate ??? And is that so what he said about security? --
2006 Feb 26
28
A Follow up to my fedora question: Favorite Flavor Of Linux?
Than my question is this? Now that I have switchtowerized and migrate enabled my app I can start down a new path if need be on a different OS as the base of the system. We have already tried CentOS and found it to have more issues than those mentioned about fedora and through it away faster than one could shake a stick at. Here are our requirements for a stage/dev box and production:
2006 Feb 24
4
Any way to pass state to a component?
I am trying set up a rails app that utilizes components. I need to be able to pass some state (a bunch of name value pairs) from the Main controller to the component. Is there any way to pass this state info using render_component? Regards -- Posted via http://www.ruby-forum.com/.