Support Forum Softcomplex logo
About Us  | Services  | Download  | Order  | Support  | |
| Search | Today's Posts | Stats | Board Rules | Not logged in [ Login | Register ]
go to bottom
Last active: Never

Printable Version | Subscribe | Add to Favourites   Post new thread Poll:
Author: Subject: slider function parametrization
Junior Member

Posts: 4
Registered: 4/19/2007
Location: Italy (Northern)
Member Is Offline
posted on 4/19/2007 at 07:17 PM Reply With Quote
slider function parametrization

I have modified slider.js adding a function which prepares the 2 records needed to create a new slider: this function receives some parameters (15)
u can use it in your html page simply calling function & passing parameters.

here's the code: it must be appended to original slider.js script:


// sliderBar function realized by Guia -
// adapted & optimized by stev-o - parametrization added
function sliderBar(vert, see, cWidth, cHeight, slWidth, slHeight, pLeft, pTop, pLength, namevar, minValue, maxValue, initValue, step, oldValue) { //prepare main records for a new slider
var sliderImage = 'SlidGrad2.gif'; //slider image
var cursorImage = 'SliderGray.gif'; //cursor image
var A_TPL = {
'b_vertical' : vert, //orientation: vertical or not (horizontal)
'b_watch': see, //visible or not (hidden)
'n_controlWidth': cWidth, //control width
'n_controlHeight': cHeight, //control height
'n_sliderWidth': slWidth, //slider width
'n_sliderHeight': slHeight, //slider height
'n_pathLeft' : pLeft, //path horiz offset
'n_pathTop' : pTop, //path vert offset
'n_pathLength' : pLength, //path lenght
's_imgControl': sliderImage , //slider image
's_imgSlider': cursorImage, //cursor image
'n_zIndex': 1
var A_INIT1 = {
's_form' : 0,
's_name': namevar, //variable name
'n_minValue' : minValue, //min(bar)
'n_maxValue' : maxValue, //max(bar)
'n_value' : initValue, //initial cursor posit & value
'n_step' : step //cursor step
oldval = oldValue; //save original value obtained from CGI GET method
new slider(A_INIT1, A_TPL); //create the new slider with given specs
return true;
View User's Profile View All Posts By User U2U Member
Post new thread Poll:

Related Links:
Product Page
Product Demonstrations Live Demos
Multiple Designs
Free Download Free Download
Product Documentation Documentation:
Documentation Page
Change Log
Support Forum Support Forum

Go To Top

Powered by XMB 1.9.1 Nexus
Developed By Aventure Media & The XMB Group © 2002-2004