Home

Castle Stronghold

Effects2Helper API Document

Exposes the effect script from Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)

Constructors

Effects2Helper()

Initializes a new instance of the Castle.MonoRail.Framework.Helpers.Effects2Helper class.

Methods

GetJavascriptFunctions() : String

Renders a Javascript library inside a single script tag.

Appear(String elementId) : String

Make an element appear. If the element was previously set to display:none; inside the style attribute of the element, the effect will automatically show the element.

Quick Note

Microsoft Internet Explorer can only set opacity on elements that have a 'layout'. To let an element have a layout, you must set some CSS positional properties, like 'width' or 'height'.

ParameterDescription
elementId

Fade(String elementId) : String

Makes an element fade away and takes it out of the document flow at the end of the effect by setting the CSS display property to false.

Quick Note

Works safely with most HTML block elements (like DIV and LI). Microsoft Internet Explorer can only set opacity on elements that have a 'layout'. To let an element have a layout, you must set some CSS positional properties, like 'width' or 'height'.

ParameterDescription
elementId

Puff(String elementId) : String

Gives the illusion of the element puffing away (like a in a cloud of smoke).

Quick Note

Works safely with most HTML block elements (like DIV and LI).

ParameterDescription
elementId

DropOut(String elementId) : String

Makes the element drop and fade out at the same time.

Quick Note

Works safely with most HTML block elements (like DIV and LI).

ParameterDescription
elementId

Shake(String elementId) : String

Moves the element slightly to the left, then to the right, repeatedly.

Quick Note

Works safely with most HTML block elements (like DIV and LI).

ParameterDescription
elementId

SwitchOff(String elementId) : String

Gives the illusion of a TV-style switch off.

Quick Note

Works safely with most HTML block elements (like DIV and LI).

ParameterDescription
elementId

BlindUp(String elementId) : String

This pair of effects simulates a window blind, where the contents of the affected elements stay in place.

Quick Note

Works safely with most HTML block elements (like DIV and LI), except table rows, table bodies and table heads.

ParameterDescription
elementId

BlindDown(String elementId) : String

This pair of effects simulates a window blind, where the contents of the affected elements stay in place.

Quick Note

Works safely with most HTML block elements (like DIV and LI), except table rows, table bodies and table heads.

ParameterDescription
elementId

SlideUp(String elementId) : String

This pair of effects simulates a window blind, where the contents of the affected elements scroll up and down accordingly.

Quick Note

You must include a second DIV element, wrapping the contents of the outer DIV. So, if you call new Effect.SlideDown('x'), your element must look like this:

 <div id="x"><div>contents</div></div>

Because of a bug in Internet Explorer 6 (overflow not correctly hidden), an additional wrapper div is needed if you want to use these effects on absolutely positionend elements (wrapper is the absolutely positioned element, x has position:relative; set; ):

<div id="wrapper">
 <div id="x"><div>contents</div></div>
</div>
Works only on block elements.

ParameterDescription
elementId

SlideDown(String elementId) : String

This pair of effects simulates a window blind, where the contents of the affected elements scroll up and down accordingly.

Quick Note

You must include a second DIV element, wrapping the contents of the outer DIV. So, if you call new Effect.SlideDown('x'), your element must look like this:

 <div id="x"><div>contents</div></div>

Because of a bug in Internet Explorer 6 (overflow not correctly hidden), an additional wrapper div is needed if you want to use these effects on absolutely positionend elements (wrapper is the absolutely positioned element, x has position:relative; set; ):

<div id="wrapper">
 <div id="x"><div>contents</div></div>
</div>
Works only on block elements.

ParameterDescription
elementId

Google
Search WWW Search castleproject.org