PDA

View Full Version : Need help with CMOTION



rmitchnm
11-12-2007, 05:10 AM
1) Script Title: CMOTION

2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex4/cmotiongallery.htm

3) Describe problem: I love this script. Thanks to the author!!!
But, how do I slow down the initial scrolling speed? Am new to css and am certainly missing something probably easy...

Thanks for any help :)

jscheuer1
11-12-2007, 05:48 AM
With this script, there is no initial speed. The gallery, if installed according to the instructions on the demo page will start out stopped (speed 0).

Perhaps you mean the top speed. That can be adjusted in the motiongallery.js file, using a plain text editor like notepad (from the beginning of the file):


/***********************************************
* CMotion Image Gallery- Dynamic Drive DHTML code library (www.dynamicdrive.com)
* Visit http://www.dynamicDrive.com for source code
* This copyright notice must stay intact for legal use
* Modified for autowidth and optional starting positions in
* http://www.dynamicdrive.com/forums/showthread.php?t=11839 by jschuer1 8/5/06
***********************************************/

//1) Set width of the "neutral" area in the center of the gallery.
var restarea=6;
//2) Set top scroll speed in pixels. Script auto creates a range from 0 to top speed.
var maxspeed=7;
//3) Set to maximum width for gallery - must be less than the actual length of the image train.
var maxwidth=1000;
//4) Set to 1 for left start, 0 for right, 2 for center.
var startpos=0;
//5) Set message to show at end of gallery. Enter "" to disable message.
var endofgallerymsg='<span style="font-size: 11px;">End of Gallery</span>';

function enlargeimage(path, optWidth, optHeight){ //function to enlarge image. Change as desired.
var actualWidth=typeof optWidth!="undefi . . .

Instead of 7, try 3. Experiment until you find a value that works for you.

rmitchnm
11-12-2007, 04:34 PM
John, Thanks for the reply. I'm having a hard time with this one and guess there's a conflict somewhere. I've tried several speed settings, but still can't get the initial startup speed to change. www.artguidesource.com/bbd/html/for_the_garment.html is one of the pages. Would surely appreciate your thoughts. Thanks!
Bob

jscheuer1
11-12-2007, 08:10 PM
I see. You are using a modified version of the script that starts out in motion and returns to motion when the mouse moves away from it. With the mod you are using, there are two spots in the motiongallery.js file where you will see:


scrollspeed=2

To slow it down, you have only one other possible value for those two places, you guessed it:


scrollspeed=1

If you'd like the more conventional Cmotion gallery that starts out stopped and that stops each time the mouse moves away from the images, reinstall it using the files and instructions from the demo page.

rmitchnm
11-12-2007, 11:33 PM
Many thanks :-) my errors exceeded my trials... But this works now as I need it. Love your script!