Displaying 20 results from an estimated 1000 matches similar to: "RJS visual_effect toggle?"
2006 Apr 07
5
RJS support "toggle" effect?
Does RJS inherently support the Element.toggle effect? I haven''t been
able to call it the way you call "appear", "fade", etc...
Jeff
--
Posted via http://www.ruby-forum.com/.
2006 Jul 27
3
How do I update a div''s content in the controller?
Without using an RJS, is there a call I can do in the controller? All I
want to do is this statement, but in the controller:
new Effect.toggle(''notifier_nav'',''appear'', {duration:12.0});
Thanks,
Ben Lisbakken
--
Posted via http://www.ruby-forum.com/.
2009 Jan 20
4
Shared templates across controllers
Hey all,
Here''s my situation: I have a pair of controllers with associated
models (called Services and Testimonials) that are quite similar.
Because their CRUD behavior is executed via AJAX, the "templates" for
the actions are all short .rjs files. Now, because of the similarity
of the models, most of the templates are exactly the same, with only
the object names changed. That
2008 Aug 24
11
link_to_function check javascript attribute
How could I check the value of an javascript object''s attribute?
<div id="new_item_details" style="display:none"></div>
<%= link_to_function("Show details...", nil, :id => "show_details") do
|page|
page.visual_effect(:toggle_blind, :new_item_details)
if (page[:new_item_details].style.visibility ==
2006 Jul 26
4
can you pass data when you render :action
how can i do:
render :action => "headline", :id => @user.id
Thanks,
Ben Lisbakken
--
Posted via http://www.ruby-forum.com/.
2006 Jul 19
4
Using Application.rhtml as layout for all controllers
I put my nav system in application layout. that way any controller
loading will have the nav system. I have one problem though - the <%=
yield %> is in the body, so how would my controllers specify other css
files?
my application layout would look like this:
<html>
<head>
title
css include
javascript include
</head>
<body>
nav system
<%=yield%>
2006 Feb 11
6
Rails 1.1?
I have a few very basic questions.
Is anyone using rails 1.1?
How/Where can I get Rails 1.1 (I don''t see it on RubyonRails.org?
What are the issues involved in moving from Rails 1.0 to Rails 1.1?
If I move to Rails 1.1, can I downgrade? Just curious.
Thank you very much for your assistance.
Frank
---------------------------------
Yahoo! Mail
Use Photomail
2006 Jul 18
3
Navigation techniques, everyone?
I''m rewriting the code to my first app. I want to reuse a lot of it,
but tidy it up a lot. The first thing I will tackle is my nav-bar.
Throughout a user''s experience on my app, I want it to reload as little
as possible (I''ll have about 7 or 8 controllers with about 70 actions).
So, I''ve thought of a few ways of doing it, and was wondering if you
guys
2006 Jul 20
7
How do you use :message with validation?
If I do validates_uniqueness_of :name, :message => "It''s not
uniqueeee!!!"
then how do I have it display that message when the check fails?
-Ben Lisbakken
--
Posted via http://www.ruby-forum.com/.
2006 Jun 21
3
Call action & display nothing?
Can you do a periodically_call_remote to an action but then not display
any new view? say the new action was called ADD. I don''t want to do an
rhtml file for add, and I don''t want to render anything in the
controller... I want to leave the page as it is. How is this done?
Thanks,
Ben Lisbakken
--
Posted via http://www.ruby-forum.com/.
2006 Jul 19
2
Mouse Location
Is the only way to get the mouse location by using javascript? Or does
rails do it for me?!? :)
Does anyone have a simple script that they use? I''m trying to put a div
right where the mouse is clicked on a link... so I''m looking for it to
work like this:
a hre f=. onclick=Element.setStyle(''title_login'', {left:
MOUSEX,top:
MOUSEY;});new
2006 Aug 10
4
How to upload all images in a folder?
Instead of making a form to upload one picture at a time, I''d like to
have the File Column plugin accept a directory, and have each picture be
uploaded and thumbnails created (w/ RMagick).
Has anyone done this?
Anyone have a good idea where to start if I were to do it on my own?
Thanks,
Ben Lisbakken
--
Posted via http://www.ruby-forum.com/.
2006 Apr 07
1
changing visual_effect defaults
what is the correct syntax for changing an effect like :highlight? i
tried looking through the api, and found it, but i can''t seem to get it
right.
i want to change the start color of visual_effect(:highlight,
''user-list''). i tried visual_effect(:highlight, ''user-list'', :startcolor
= ''#990000'') and several other variations of
2006 Apr 03
4
page.visual_effect :highlight not working
I just upgraded Ruby to 1.8.4 and Rails to 1.1 and I''m in the middle of
changing my Javascript code over to the Scriptaculous helper functions.
page.visual_effect :highlight, "some_div" seems to be broken. Instead
of fading, the background color of the element stays highlighted.
page.visual_effect works for other effects, though. Any ideas?
Thanks.
--
Posted via
2006 Jul 25
11
Prevent users from entering urls
How could I make it so that links on my page could link to a controllers
action, but if the user manually entered the url, it would redirect them
back to the main page? Is this possible?
Thank you,
-Ben Lisbakken
--
Posted via http://www.ruby-forum.com/.
2006 Jan 10
5
using dynamic element ids with visual_effect
Mike and I demo an Ajaxified version of the Depot application in the
Rails Studio. Part of the demo is a cart in the sidebar which updates
when you add a product to it. As well as updating the div, it also
highlights the most recently added link item. Right now, we do it with:
<script language="JavaScript">
function flash_cart(request) {
var id =
2006 Oct 09
2
page.visual_effect :highlight
I have some code that will do the highlight, fade effect on a block of
text. It seems to work just fine until it is fired multiple times very
rapidly.
The end color matches a grey background and the start color is a yellow.
Say its run 4 times a second for 3-5 seconds. When the flashing catches
up the text will fade for the last time to the end color, then the
background will switch to a
2006 Aug 11
5
Why does no one like render_component?
Maybe I''m missing the point?
Lets take for example albums of pictures. If I have a scaffold for
each, and I''m showing an album, what if I want to list all of the
pictures that are in the album?
Surely, I''d want to call the List action in the picture controller.
render_component would do this perfectly. But we''re told not to use
render_component. So
2006 Jul 18
6
RJS - Insert at top of table?
Quick question regarding RJS and inserting to the top of a table. Here''s
the view I''m working with:
<table id="links-list">
<tr>
<th>Display title</th>
<th>URL</th>
<th>Description</th>
<th>Category</th>
</tr>
<% for link in @links %>
<tr id="link-<%= h link.id
2006 Jul 17
7
Ajax Tabbed Browsing
I was wondering if anyone has done this, namely make tabbed browsing
exactly like a web browser, but have it within the page.
I would like to make a search function that updates a section of the
page with the results, as well as makes a new tab that displays those
search results. Then, if a user did 5 searches, there would be 5 tabs.
Each tab would hide the other 4 results and show the