search for: find_tagged_with

Displaying 20 results from an estimated 26 matches for "find_tagged_with".

2006 Apr 20
5
acts_as_taggable patch 3866 needs some testing
...e last year @blog.articles.tags :conditions => [''published_at > ?'', 1.year.ago] # Get related tags from article tags in a blog @blog.articles.find_related_tags [''code'', ''rails''] # Get blog articles tagged with any/all tags @blog.articles.find_tagged_with :all => [''code'', ''rails''] @blog.articles.find_tagged_with :any => [''code'', ''rails''] @blog.articles.find_tagged_with [''code'', ''rails''] # Depreciated interface I would appreciate any f...
2006 Apr 01
3
acts_as_taggable, wrong number of arguments
Hello, When I try: @tagged_items = Problem.find_tagged_with :all => ''kuba'' or @tagged_items = Problem.tags_count :limit => 100 I get this error: ArgumentError in Volume#index wrong number of arguments (2 for 3) RAILS_ROOT: script/../config/.. Application Trace | Framework Trace | Full Trace /usr/local/lib/ru...
2006 Mar 05
0
Pagination Question [Tagging: find_tagged_with]
Hello experts, I am trying to paginate the following query but no matter what I try I am unable to paginate it. In controller I have: q_webpages=Webpage.find_tagged_with(:any => params[:tag], :separator=>'','', :order=>''updated_at DESC'') @webpage_pages, @webpages = paginate_collection(:collection=>q_webpages) In my view I have: <%= link_to ''Previous page'', { :page => @w...
2006 Jan 30
2
:condition not being applied
I am using acts_as_taggable and everything seems to be working except that :condition => "tags_resources.portal_id=#{portal_id}" is not being applied. @resource_pages = Paginator.new self, Resource.find_tagged_with(:any => tag, :condition => "tags_resources.portal_id=#{portal_id}").length, 25, @params[''page'']; @resources = Resource.find_tagged_with( :any => tag, :condition => "tags_resources.portal_id=#{portal_id}", :separator=> '' '...
2006 Jul 14
5
Acts_As_Taggable Plugin multiple controllers.
I have Acts_As_Taggable Plugin working. I have a HR controller and a sales controller. I have a document in hr tagged whitepaper and a differnent document in sales tagged whitepaper when I am in hr I see the hr document tagged with whitepaper and not the sale document (what I want). but if I click on the tag whitepaper I return two documents, hr and sales. I just want to return the hr document
2005 Sep 06
9
acts_as_taggable v4 - Tag Counting Anyone?
ThereĀ“s already a new version of the acts_as_taggable mixin available and look what it is capable of now: # Gets the top 10 tags for all photos Photo.tags_count :limit => 10 # => { ''beer'' => 68, ''wine'' => 37, ''vodka'' => ''22'', ... } # Gets the tags count that are greater than 30 Photo.tags_count :count =>
2006 Jun 02
1
Sorting records from acts_as_taggable plugin
I am using the acts_as_taggable plugin, which works rather nicely by the way. My question is this: When using find_tagged_with, how do I sort the resultant data? It is currently sorting based on the "id" of the record. For instance, I have posts, with tags. If I want to find all posts tagged with "RubyOnRails" it displays them, but not in chronological order, they are displayed based on their id'...
2006 Nov 11
0
acts_as_taggable plugin - paging through tagged model
...ular tags. i.e. page through all Model records that have been tagged with "artist" I could not work out how to do this with the plugin, so I made the changes outlined below. Did I need to do this..? & does anyone else find this useful? -------------------- Usage Original - Model.find_tagged_with("artist") New - Model.find_tagged_with("artist", { :limit => x }) New - Model.find_tagged_with("artist", { :limit => x, :offset => y }) File: vendor/plugins/acts_as_taggable/lib/acts_as_taggable.rb replace old find_tagged_with - with the below.....
2006 Feb 16
1
[PATCH] acts_as_taggable plugin
hi, I started today to use the acts as taggable plugin and it''s working as expected. I added a method find_tagged_with_all since I needed to find the elements tagged with all the items in a list while find_tagged_with finds all the elements tagged with any of the list terms. Attached to this mail there''s a patch which adds the find_tagged_with_all method and which solves a small problem with having du...
2006 Jun 21
7
acts_as_taggable and paginate?
Hi there, I''ve been trying to paginate over a list of members that all share a tag in common using the acts_as_taggable plugin. The regular way of paginating over a collection doesn''t seem to work with acts_as_taggable. Here''s what my method looks like that takes in a tag name, finds all the members that share the tag and then displays all the members. Nothing too fancy
2006 May 06
3
Extending Rails plugins?
Gents, I''m using the acts_as_taggable rails plugin (not gem), and would like to add some additional methods to it. For example, the find_tagged_with methods essentially does a find tag in a list (effectively an OR), while I''d like to implement a find_tagged_with_all method that would implement an AND (so if I specified 4 tags, it would only return items that were tagged with all four inclusively). Is there a proper way to exte...
2006 Aug 10
2
search acts_as_taggable for multiple tags
Hey...I''m trying to search a Model that uses acts_as_taggable for multiple tags. I''d like to pass in a search string containing a space delimited tags names (i.e. "tag1 tag2") and return the objects that have been tagged by either one of those. Thanks! -------------- next part -------------- An HTML attachment was scrubbed... URL:
2006 Sep 27
1
acts_as_taggable with single-table inheritance?
...this work? I installed the plugin and tried the following: class SomeClass < ActiveRecord::Base acts_as_Taggable end class SubClass1 < SomeClass end class SubClass2 < SomeClass end SubClass1.tag_with("tag") and notice that taggable_type = SomeClass when I do SubClass2.find_tagged_with("tag") a SubClass1 object is returned. Any help would be greatly appreciated! .Martin -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk&q...
2006 Dec 26
0
acts_as_taggable Plugin issue (not gem)
...t getting it. Because in the console, using a string in place of params(:tag_name) returns an actual entry. *Controller* <code> def tagged # This should take the :tag_name in the url string and pull elements that match # It does not. I suck as a programmer. @elements = Element.find_tagged_with(params[:tag_name]) respond_to do |format| format.html # index.rhtml format.xml { render :xml => @elements.to_xml } end end </code> *Models* <code> class Element < ActiveRecord::Base acts_as_taggable [...] end </code> *CONSOLE* This does work...
2008 Feb 21
4
undefined method `save' for :Array
hi all when i m trying to save my tags.this error s cmng........cn anybody help me to how to save the array error depicting = undefined method `save'' for []:Array --~--~---------~--~----~------------~-------~--~----~ 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
2006 Feb 09
3
acts_as_taggable Produces Bad SQL - Find Fails
...n my application and on the tagging side of things, no problem at all. Running edge Rails and PostgreSQL 8.1. I am then trying to find all my AR objects with a certain tag. The tag is: lasvegas and I know that there are at least 3 records with that tag. So, I''m doing this: @lists = List.find_tagged_with :any => @search_string, :separator => ''+'' The problem is that the SQL generated looks like this: SELECT lists.* FROM lists, tags, taggings WHERE lists.id = taggings.taggable_id AND taggings.taggable_type = ''List'' AND taggings.tag_id = tags.id AND tags.nam...
2006 May 19
1
acts_as_taggable pagination
Im using the acts_as_taggable plugin, is there a way to paginate the find_tagged_with results? -- Posted via http://www.ruby-forum.com/.
2006 Apr 28
1
acts_as_taggable help
Ahoy, having a bit of difficulty w/ the acts as taggable GEM. I was able to create a tagcloud, but now i want to filter items by tags. in my controller i have def show_tagged_with <-- snip snip --> @items = Item.find_tagged_with( :any => params[:tag_name]) @categories = Category.find_all @tag_name = params[:tag_name] @tagged_items = Item.tags_count(:limit => 100) end IN the VIEW <% @items.each do |item| %> <%= render :partial => ''list_stripes'', :locals => { :item =...
2006 Mar 29
3
tagtools vs acts_as_taggable
tagtools and acts_as_taggable are both folksonomy tools for rails,any one who has used them both and can give a compare between them? Grateful! -- Posted via http://www.ruby-forum.com/.
2006 Feb 28
0
acts_as_taggable vulnerable to attacks ?
Hi all ! I''d like to confirm if I''m reading correctly. It seems ActiveRecord::Acts::Taggable::SingletonMethods#find_tagged_with is vulnerable to SQL injection attacks: def find_tagged_with(options = {}) options = { :separator => '' '' }.merge(options) tag_names = ActiveRecord::Acts::Taggable.split_tag_names(options[:any] || options[:all], options[:separator]) raise "No tags were passed to :an...