hoverscroll Yii implementation of the HoverScroll jQuery plugin.

  1. Requirements
  2. Usage
  3. Resources

This is a Yii implementation of the HoverScroll jQuery Plugin.

It makes an unordered list scrollable by hovering the mouse over it. Lists can be either horizontal or vertical as well.

Requirements

This has been tested with 1.1.8, but should work with any version.

Usage

To use this extension, you must first create an array of items to display. Each item must be another array with an HTML attribute, as well as height and width attributes (in pixels).

$items = array(
  array(
    'height' => 48,
    'width' => 64,
    'html' => '<img src="path/to/image" alt="Example" />',
  ),
  ...
);

Next specify any parameters you would like to pass to the list. The following are the defaults:

$options = array(
  'vertical'      => FALSE, // Display the list vertically or horizontally
  'width'         => 400,   // Width of the list container
  'height'        => 50,    // Height of the list container
  'arrows'        => TRUE,  // Display direction indicator arrows or not
  'arrowsOpacity' => 0.7,   // Max possible opacity of the arrows
  'fixedArrows'   => FALSE, // Fixed arrows on the sides of the list (disables arrowsOpacity)
  'rtl'           => FALSE, // Print images from right to left
  'debug'         => FALSE, // Debug output in the firebug console
);

And then finally render the widget in your view:

$this->widget('ext.hoverscroll.EHoverScroll', array(
  'items' => $items,
  'options' => $options,
)); 

Resources

5 0
7 followers
514 downloads
Yii Version: 1.1
License: (not set)
Category: User Interface
Tags: jquery, widget
Developed by: Matt Kelliher
Created on: Sep 24, 2011
Last updated: 13 years ago

Downloads

show all

Related Extensions