Displaying 20 results from an estimated 200000 matches similar to: "caches_action - can I change the path?"
2008 Sep 24
3
caches_page :if not executing (but caches_action :if) does
Hi folks -
Seeing a weird problem and would love some help. It''s documented in
http://pastie.org/278310 to be more readable.
In short, I have a
caches_page "action", :if => {stuff}
but the :if is never being called - the action is just caching every
time. (If I put a debugger call in the :if block, it never stops.)
If I replace caches_page with caches_action, the if
2007 Jan 22
2
caches_action :index for site root gets propagated to lower levels (how to stop?)
Hello all,
I am running a blog system which has its "/" (home page) cached like
this:
class ApplicationController < ActionController::Base
before_filter :index_cache_expirer, :only => [:index]
caches_action :index
so the site''s top page is caches for 60 seconds in my case
(index_cache_expirer is a home-made function to expire)
on the site, there is also a
2006 Aug 23
0
Caches_action/ before_filter problem .
Hello, I have a method called "check_permission" that is set to run as a
before_fitler and which checks if a user has the authorization to view a
page.
This page is displayed through the method "show" which is cached through
the tag "caches_action :show"
My problem is that once a user with authorization to a page accesses it,
then afterwards all users (with or
2007 Feb 03
1
How can I bypass caching for some users
I have action caching setup for several actions of an application but I
want the caching to only run for my administrators and have all other
users see non-cached pages. Is there a way to do this? Perhaps
something like passing a block to caches_action or setting some sort of
flag in my authentication method? If this is not possible with action
or fragment caching does anyone know of a
2007 Mar 19
2
Controller url_for modifies request object?
Hi,
In my controller, I do something like this:
MyMailer.deliver_signup_notification(url_for(:subdomain =>
account.subdomain, :controller => ''hello''))
And a few lines later:
redirect_to :action => ''index''
Much to my confusion, the redirect routes me to the subdomain used in
the url_for. I''ve tried
redirect_to :action =>
2008 Feb 20
3
Can Rails and PHP work together?
Hello everyone,
I am new to RoR, coming from an ASP.NET background. I''m currently working
on a politically-themed social network, and I want to have multiple bloggers
who will blog about various topics. My web host offers several PHP-based
blogging engines, and I like WordPress, so I am trying to set it up with a
subdomain such as blogs.mydomain.com/blog_name. However, I''m
2006 Aug 24
2
Handling sub-domains
I want users to have their own landing pages: http://username.domain.com.
Since this is dynamic (any user will have a subdomain), is there a way
to do this without creating a DNS record for each of them?
Can you DNS records be dynamic?
--
Austin Govella
Thinking & Making: IA, UX, and IxD
http://thinkingandmaking.com
austin.govella-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org
2007 Mar 31
1
Subdomains, Routing, and Subdirectory Controllers
For reference, this question is similar to "Subdomains, Session Data,
& Routing" posted Oct. 31, 2006. Link:
http://groups.google.com/group/rubyonrails-talk/browse_thread/thread/d3c5072c3588a1e0/f87d0fdfded31650
----
I would like to set up a subdomain and, using the request_routing
plugin, have requests to that subdomain call corresponding "sub-
controllers" inside a
2007 Nov 27
1
routing
Hi all,
My site uses subdomains to define an item. Eg http://itemname.mysite.com
I fetch the itemname and render the appropriate site from that
itemname. The subdomain is used everywhere (eg http://itemname.mysite.com/events,
http://itemname.mysite.com/products/show/11, ...)
I now want to give the user the possibilty to use a ''real'' domain like
www.itemname.com that should
2009 Dec 16
5
Caching comments: timestamps and subdomains
Hi,
I''m working on a website that has a very slow loading frontpage. I
wanted to start by caching certain elements that have high load. For
example, it loads the last 50 comments, along with the corresponding
usernames, avatars and more. So I cached that fragment and created a
sweeper that observes Comment and expires after every create or
destroy action.
However, I have two problems:
2006 Sep 29
0
Authentication question
I have a slightly odd need, and since I''m still somewhat new to Rails,
I''d love your feedback.
My app has a set of public stuff, (which will live at
www.mydomain.com), a set of admin pages (which will live at
admin.mydomain.com), and the bulk of the app, which will live at
subdomain.mydomain.com, where "subdomain" is chosen by the user when
they sign up for my service.
2007 May 09
1
How can I change a form's onsubmit event handler using rjs?
Hi all,
I have a ajax form creating by "form_remote_for", whose url is to
create a new model by default. The page doesn''t change after the ajax
call on submit button so the form is still there after the new model
is created. But if I submit the form for the second time, I want to
update the formerly created model using an Ajax post.
I think I could render an rjs at the end of
2007 Jan 22
5
rails helpers are adding extra folders
i have a new rails site that i am setting up just like i normally do with
all of the other sites. i created a subdomain which is pointed to a
subfolder in my public_html.
i can view the site both at test.mywebsite.com and mywebsite.com/test/ but
when i view it by the subdomain, rails helpers are adding the /test/ to all
of my resources, so none of my images or style sheets are found.
this
2008 May 26
5
Noob SASS error (permission denied)
I just created the sass directory in my stylesheets directory and
when
I reload my page I get this error:
Status: 500 Internal Server Error
Permission denied - /Users/Justin/kicksite/trunk/public/
stylesheets/
application.css
/usr/local/lib/ruby/gems/1.8/gems/haml-2.0.0/lib/sass/plugin.rb:
72:in `initialize''
/usr/local/lib/ruby/gems/1.8/gems/haml-2.0.0/lib/sass/plugin.rb:
72:in
2008 Feb 08
1
Wildcard Subdomains & OS X Local Development
I''m using the simple account_location plugin to have virtual
subdomains on my app (account.myapp.com - see Basecamp, Blinksale,
etc.)
How do you go about setting up your OS X system to play nice? I''d like
to use Apache & Mongrel.
Notes: The only thing I''ve able to accomplish is hardcoding the
subdomains directly in my hosts file. I can get
2007 Dec 18
2
attachment_fu and S3 -- cannot download file correctly
I don''t know why this isn''t working. If I download a word doc that I
uploaded, all I get is the S3 file path in the document. If I access
the s3 file path directly in my browser, it downloads the file
correctly.
Here is my controller method:
def download
@curriculum = @school.curriculums.find(params[:id])
send_data @curriculum.attachment.public_filename,
:filename
2007 May 28
5
validates_uniqueness_of does not pass unit test
I am doing some very very basic unit testing. If I take away the
uniqueness validation, the tests pass. Could this be a bug in Edge
Rails?
--~--~---------~--~----~------------~-------~--~----~
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
2008 Jun 30
1
access of WML site through cell phone seems flakey
I just started a new subdomain on hosting rails. I launched it a
couple of days ago. It is a site that
can render onto mobile devices using WAP/WML or through a regular
browser.
It seems flaky with the mobile cell phone access, because sometimes
it works and sometimes it stops working for several hours and then it
seems like it''s fine again, with a regular browser it seems ok, though
2009 Jan 09
6
Accessing request.host in UserMailer
I am using subdomains in my application to control context. Therefor,
during user registration, password reset, and other actions that require
an email to be sent with a link to be clicked, I need to ensure that the
subdomain appropriate for the user is used.
It seems I need to be able to access request.host from within an
ActionMailer model. But I am not clear how to do this.
Any help would be
2007 Feb 09
1
First steps: superclass mismatch
Hi guys,
just doing my first steps with ruby and ror. besides some theoretical
learning i wanted to setup typo as a development blog and kind of a ror
playground.
I use plesk 8 on a debian sarge machine with ruby on rails support
installed into plesk 8. I updated to 1.8.5 manually and ruby -v says
1.8.5 is perfectly installed. I also installed rubygems and with that
rails, typo and the dependent