similar to: CSS Effects? (javascript?)

Displaying 20 results from an estimated 6000 matches similar to: "CSS Effects? (javascript?)"

2006 Jun 28
2
Assign CSS class to Link to Remote
I''m trying to get link_to_remote to assign a CSS class to the link it generates. My code is as follows: <%= link_to_remote "Show Full Info", :update => "fullcontact" + reparray.last.to_s, :url => "/cm/full_contact/" + reparray.last.to_s, :classname => "contactlink" %> Which produces this HTML: <a href="#"
2006 Aug 07
5
RJS Change Background Color
What''s the page.method to change the background color of a DOM element? I''m trying to change the background color of a couple of styled <li>''s when an Ajax link is clicked. Thanks, David -------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060807/63de04bf/attachment.html
2005 Sep 25
2
Preventing/allowing exceptions to occur in Element.add/remove ClassName
Hello everyone ! Thomas asked me to discuss here the behavior of Element.addClassName, as relating to ticker #2232 [1]. In HEAD, if the element passed-in to Element.addClassName does not exist, an exception is thrown, and script execution stops there. I believe this is inconsistent with other functions: Object.extend(Element, { hasClassName: function(element, className) { element =
2006 Jul 26
3
adding class or id tags to tags like linkto and form
I''m trying to figure out things like this by myself so I don''t bother my developer and slow him down. How do I add class or id css attributes to tags like this: <%= form_remote_tag :url => { :action => "send_url" } %> <%= link_to_remote "My Profile URL", :url => { :action => "send_profile_url", :id => @user.id } %>
2006 Feb 10
13
Element.observe () binding
Hey all, I working on a project, but I am not sure I can do what I want to do. The following works beautifully: Event.observe(el, ''click'', function () { this.className += " myClass"; return false; }); I have also tried doing this: this.varname = ''test''; Event.observe(el, ''click'', function () { alert (this.varname); }.bind
2008 Jan 09
4
Using Prototype - Getting Javascript Error - "Object doesn't support this property or method"
I have the following javascript being called on my site and I am getting a Javascript error - "Object doesn''t support this property or method". The error is invoked on the line that has - "listItems = $ ("vidList").childElements("li");". The purpose of the Javascript is two fold: ''swapVideo'' to change the Youtube video and
2006 Feb 16
3
Retrieve a property defined in a css
Hi all, I have a property, defined in an external stylesheet: .my_class { background-color: #FF0000; } I want to retrieve the value of this background-color of the class my_class. How can I do that with prototype/scriptaculous ? Thanks in advance, Nicolas Terray
2007 Oct 24
3
addClassName and removeClassName
Hi, and sorry for the noob question! I have an unordered list of 4 links where the links use Ajax.Updater in the onclick: onclick="new Ajax.Updater(''ajaxarea'', ''link1.php'', {asynchronous:true, evalScripts:true }); return false;" How would I go about using addClassName and removeClassName to show the current link? Thanks for any help with this.
2006 Aug 17
2
link_to_remote option :onsuccess, execute js function
How should I define the :onsuccess option in my - link_to_remote - tag, to execute a Js function I wrote : :success => "toggleButton(this, /db_bfilter/i);" ''this'' is the current element defined in my view : <span id="db_bfilter0" class="depressed"><%= filter_link_helper "This week" %></span> <span
2006 Mar 02
7
Timing of effects before and after Ajax call
Hello, I have a problem with the timing of effects. I do have a tag (with id: post1). When the link is clicked, the block "post1" must BlindUp. Then the block is updated with the new content and then the effect BlindDown is executed. Below is the source code of the link_to_remote I am using. <%= link_to_remote("Ajax Edit", :update =>
2006 Jul 05
10
Google/Netflix Like Tooltips
I need to have a toolip-like object which has dynamic content in it. I plan on using scriptaculous with an ajax call to retrieve the content, but I would like to make the popup/tooltip/balloon text look as nice as possible. Does anyone have any examples or anything useful to create a popup like the ones that Google and Netflix have? I''d like to have one which must be
2006 Jan 23
16
Adding form fields (extending a form) on the fly
Hello, I just can''t seem to find a way to extend a form dynamically in ROR. Say I am writing a recipe website. There is one form to enter the recipe. There is room for N number of ingredients (let''s say a text field for each ingredient name and selection list for the amount). What if the user wants to add more than N ingredients as he types them in? how do I do this without
2008 Jun 30
1
javascript onclick for thumbnails
Hi, i was struggling for a function where only 1 thumbnail should be active and others inactive when clicked on the particular thumbnail. code: 1. view: 2. <script type="javascript"> 3. function PlayVideo_options(videoFile, id) { 4. document.getElementById(id).className = ''video_option active_video''; 5. } 6. </script> 7. 8.
2006 Apr 10
2
RJS newbie - need help with iterating / existence test
Greetings! I''m new to Ajax and am trying to get a basic app working as a vehicle for learning it. The app is an extension of the cookbook tutorial. My intent is to be able to add a list of ingredients for a recipe. The page to add ingredients uses Ajax. As ingredients are added to the page they''re displayed in a "green-bar" format like that used in the Depot
2006 Jul 29
2
Instance Variables within Controller during AJAX request
Hey all, I''m trying to do something sorta simple... There are three button ids: ''view'', ''build'', ''search'' My controller looks like this: class RandomController < ApplicationController before_filter :login_required, :except => [:index, :initialize] def initialize @mode = ''view'' end def index
2005 Dec 28
6
Sudden Javascript Console noise in firefox
I have been using the latest version of Firefox and Scriptaculous for about a week now, with no problems. Now I get a lot of noise in the javascript console out of the blue: http://img481.imageshack.us/img481/7913/screen4nt.jpg -- ============================ Brian Peiris Brampton, Ontario, Canada brianpeiris-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org or
2006 Feb 23
25
reloading fragments of pages
Hello, I have a treeview, that works with scriptaculous in order to load the nodes dynamically. I also have in the main part of the page, a table with the list of elements. The lists of elements can be drag-dropped on the treeview in order to move them around (they are also draggable on other parts of the page) I need though, to refresh the treeview to reflect changes when a folder was moved
2006 Apr 04
2
How to add CSS tips to link_to_remote?
The following code of tag clouds implementation: <%= link_to(h("<#{tag}>"), "tags/listmytag/#{tag}", { :style => "font-size: #{font_size}" } ) -%> I want to change it to ajax style: <%= link_to_remote "<#{tag}>", { :url => { :controller => ''tags'', :action => ''listmytag'', :id =>
2006 Apr 08
1
How To ??? change class of DIV
I''m trying to replicate the "green-bar" effect used in the Depot app using Ajax. And I''m almost there ;-) I''m about to set off on the last stage and would appreciate any advice that would set me off in the right direction. On the page, each record is represented by a <div>. Each <div> has id = "item#{record.id}" with class = either
2006 Jul 14
4
Help with link_to_remote or javascript generator
Hi all, I''m a relative noob to rails so I apologize in advance for asking such a basic question. I am trying to do multiple AJAX calls using the link_to_remote helper or the JavaScript generator update_page. I have googled and read the docs for both, but can''t seem to figure out exactly what i need to do. Say I have the following html: <div