similar to: How to set session variable in plug-ins

Displaying 20 results from an estimated 900 matches similar to: "How to set session variable in plug-ins"

2006 Sep 04
2
"include" versus "extend" - what's the difference
Hi, Just wondering when one would use "include" over "extend"? Both seem to bring in methods to the class no? The context is I''m just trying to understand why both are used with the acts_as_audited plugin: Full extract from plugin (used within here): ================================================== # Copyright (c) 2006 Brandon Keepers # # Permission is hereby
2006 Jun 26
5
How can I dynamiclly generate models?
I am trying to write a plugin, ''acts_as_commentable'', for my models - Image, Book, Music and so on, I do not want to use polymorphic association, so very model should have its own comment class. Here is my code acts_as_commentable.rb module Commentable def self.included(base) base.extend(ClassMethods) end module ClassMethods def
2009 Sep 11
0
Need help with extending a plugin
hey folks I''ve installed the plugin acts_as_taggable_on_steroids (henceforth aatos), and i already have some tagging functionality set up, using the same approach (ie a Tag and a Tagging class with associated tables) as aatos. So, i want my existing Tag and Taggings methods, plus some other methods i have in a module which i include with the taggable classes (ie the ones that would call
2005 Dec 29
3
Why do plugins use class_eval?
I''m writing my own plugin and all the plugins I''ve seen use class_eval in the method that is called in the including module. For example: http://wiki.rubyonrails.com/rails/pages/HowToWriteAnActsAsFoxPlugin module Foo module Acts #:nodoc: module Fox #:nodoc: def self.included(base) base.extend(ClassMethods) end # declare the class level
2009 Dec 27
5
Difficulties in understanding Rail-Plugins in depth
Hi, i try to understand how plugins work in detail. Often you see stuff like: class Post < ActiveRecord::Base   acts_as_commentable end I wonder what''s happen all there. What kind of language-feature is behind this call "acts_as_commentable" ? In my opinion you need some kind of extend or include to extend the functionality of a model. And exactly this is which i found
2006 May 31
1
Help enhancing acts_as_nested_set
I''m trying to enhance acts_as_nested_set. Well actually I already have, but I''ve done a hack up job of it. I would like to contribute these enhancements back, but I need a little help. I''m a complete newbie to this stuff. The only thing I new before coming into this project was vanilla HTML. So over the course of two weeks I''ve picked up Ruby, Rails, MySQL,
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
2006 Jun 21
1
Plugin Panic! - no accessing a model''s class methods?
Hi plugin-authors. So this is a little bit of take two on this question, but why can''t I access a singleton on the model calling my plugin? The crux of the full plugin below is: #logger.info self.class.to_s new_copy = self.class.new( @copyable_attributes ) the logger spits out "Datatype", but I get an error from rails saying: undefined method `datatype'' for
2006 May 11
1
acts_as_paranoid and nested scopes in Rails 1.1
I have a real problem with the acts_as_paranoid plugin. The find-scope nesting does not seem to work at all. The description: I made a copy of ''acts_as_paranoid'' in the plugin directory, renamed it to ''acts_as_very_new''(just nonsense plugin for testing), and just simplified the code: #-------------------------------------------------------------- module
2006 May 26
1
access a ActionControllers protected method from plugin?
I can''t belive I fit that in as the subject! I''m writing a plugin that will allow me to grab some text from a database and call the render method from ActionController on part of the text. I can''t seem to figure out how to access the render method of ActionController::Base. I keep getting the "uninitialized constant Execute" error. How can I do this?
2006 May 11
0
acts_as_paranoid, aliasing and nested scopes in Rails 1.1
I have a real problem with the acts_as_paranoid plugin. The aliasing of find and so the nested scope does not seem to work at all, when combining it with similar plugins. The description: I made a copy of ''acts_as_paranoid'' in the plugin directory, renamed it to ''acts_as_very_new''(just a nonsense plugin for testing), and simplified the code (original code
2012 Jan 28
2
after_save in plugin
Dear list, I am trying to override an after_save callback declared in main app using plugin. The main model class is: class WorkHours < ActiveRecord::Base @after_save_call_back_called=0 after_save :after_save_call_back def after_save_call_back logger.debug "after save called" @after_save_call_back_called=1 end end And in my plugin (in the lib directory) : module
2006 Oct 31
0
6202015 fmd should only load plug-ins whose filenames end in .so
Author: mws Repository: /hg/zfs-crypto/gate Revision: 350b29b024d8b672585c7a66fcea71985a54f77f Log message: 6202015 fmd should only load plug-ins whose filenames end in .so 6369961 fmd emits identical diagnosis after repair when case was never closed 6385004 mc-amd driver leaks property string on attach 6385007 fmd is not decrementing buf total when cases are closed Files: update:
2009 Oct 17
2
Totem needs plug-ins
Just tried to play a movie/DVD and Totem (what automatically popped up when I inserted the DVD) said it needed plug-ins... it didn't say which plug-ins. The website listed in the help page no longer exists. I have four of the gstreamer packages and libdvdcss installed, but I guess there's something more needed. Anyone know? tia for the tips. -- War is a failure of the imagination.
2004 Sep 10
0
[Flac-users] Winamp 2/Winamp 3 and FLAC plug-ins
--- Paul Doland <pauld@ml1.net> wrote: ... > Okay, so where am I going. Well, for one, I've installed Winamp > 2.91, the > latest 2.x release, and the FLAC plug-in for it. When I go to try to > play a > .flac file with it, all it seems to do is just convert it to a .wav > file, > and then I have to play the .wav file. I thought the whole idea of > FLAC was >
2004 Aug 06
1
Any Speex plug-ins available for usage in a Palm device application
Hi all, I'm new to the speex development mailing list, so I don't have much experience/idea about Speex. I came to know about speex when I was working on a R&D for my application on Palm devices. I've created a Pocket PC application, which is a talking phrasebook using .NET Compact Framework. In this application I'm using a 3rd party MP3 plug-in for playing my MP3 files,
2004 Aug 06
0
Any Speex plug-ins available for usage in a Palmdevice application
Thanks a lot for your reply, Jean. >I'm not aware of anyone packaging Speex especially for a Palm device, >but I have been able to use it as a command-line executable (you need >version 1.1.x to do that). Your reply essentially means that there aren't any commercial speex plug-ins for Palm available, so the only option I do have is to write one. Actually I was thinking of that
2012 Feb 27
2
using windows vst plug-ins with logic 9 on mac osx lion
I have just discovered the existence of Wine as I was thinking of creating a Windows partition in order to process audio files using some of the great VST fx plugins (such as dblue glitch) that are only available on Windows. I could then import the files into Logic 9 on Mac OSX Lion for use in my music. A Windows partition seemed the only solution until I stumbled across the Wine website: I tried
2007 Nov 27
1
Plugin - How to access object from instance method
Quick question: Given a basic plugin... how can I access an object that I instantiated in the acts_as method from an instance method? Probably some sort of accessor... but where? def self.included(base) base.extend ClassMethods end module ClassMethods def acts_as_test object = Object.new ## This object needs to be accessible from the Instance Methods end include
2004 Sep 10
2
[Flac-users] Winamp 2/Winamp 3 and FLAC plug-ins
I know that Winamp has its loyal following. I've never used it much. Also, I'm a novice at computer music. I've always just bought CD's and never used computer music. So perhaps I'm an idiot or just not very music-software literate, but I so far haven't been impressed with Winamp, or the FLAC plug-in. Just for one example, I've got a dual-Althlon MP 2000 system