Displaying 5 results from an estimated 5 matches for "my_pages".
2006 Jun 02
3
Custom Pagination Links
...o paging i.e. the full collection is
displayed, when it still display a "1" to represent the current page.
How can I suppress that?
Thanks!
<div class="pager">
<%= link_to(''< Prev'', {:params => params.merge(''page'' =>
@my_pages.current.previous)}, {:class => "prevlink"}) if
@my_pages.current.previous %>
<% for page in @my_pages -%>
<%= link_to_unless(params[:page].to_i == page.number, page.number,
{:params => params.merge(''page'' => page)},
{:class =&g...
2006 Apr 25
5
Routing and extensions.
I would like my something like "my_page.html" to map to :controller =>
''page'', :action => ''my_page''. How can I accomplish that?
Is there a way to make the routing parse other things other than ''/''?
--
Posted via http://www.ruby-forum.com/.
2009 Apr 09
1
undefined method ''text'' ...
Just trying to run the example
*****
require ''rubygems''
require ''mechanize''
a = WWW::Mechanize.new
a.get(''http://rubyforge.org/'') do |page|
# Click the login link
login_page = a.click(page.links.text(/Log In/))
# Submit the login form
my_page = login_page.form_with(:action => ''/account/login.php'')
2010 Jan 26
6
Subclassing ActiveRecord::Base
First of all, sorry for the crossposting, but I put this into the Ruby
Forum first of all, but was pointed to this as a more appropriate
location.
I''m using ActiveRecord and ActiveSupport in a non-rails environment
to connect to multiple databases, and I''ve found the following (single
database) to cause me an error. Note that params is my database settings
and omitted for
2005 Dec 30
4
AJAX Drag and Drop Detecting Drop Coordinates
This one''s kicking me in the *(&#^. All I want to do is create a draggable
item and then detect the coordinates where it is dropped. So my first
approach was to just use the draggable_element with :revert => false, like
so:
<%= draggable_element "my_element", :revert => false %>
That works great and lets me drag stuff all over the place. In the
scriptaculous