PDA

View Full Version : Problems implementing CMotion gallery_oo



MatthewNBooth
10-24-2008, 04:11 PM
1) Script Title: C-Motion OO, 2 CMotion scripts on one page

2) Script URL (on DD): http://www.dynamicdrive.com/forums/showthread.php?t=13242&highlight=motion

3) Describe problem: Hi there, I am having problems implementing the two C-motion scrollers on my page. I have read the previous entrys and had one working fine but trying to add the second (with the new scripts) I am getting nothing appearing.

Please see: http://www.matthewboothphotography.com/weblog/blog.html

There should be one under Friday, September 19
and a second under Tuesday, August 26

I am sure its just a minor coding problem but just cant work it out.

great code by the way!

many thanks Matt

jscheuer1
10-24-2008, 07:39 PM
You need to be consistent in your use of variable names in this section (not important in the //commented lines, but that helps keep things straight) additions highlighted:


//declare gallery1's name:
var gallery1=new Array();
// Use a space character between each image for this gallery? (use 1 for yes, 0 for no):
gallery1.usespace=0;
//define gallery1's image train:
gallery1[0]='<img src="http://www.matthewboothphotography.com/weblog/media/boundaries1.jpg" border="0">';
gallery1[1]='<img src="http://www.matthewboothphotography.com/weblog/media/boundaries2.jpg" border="0">';
gallery1[2]='<img src="http://www.matthewboothphotography.com/weblog/media/boundaries3.jpg" border="0">';
gallery1[3]='<img src="http://www.matthewboothphotography.com/weblog/media/boundaries4.jpg" border="0">';
gallery1[4]='<img src="http://www.matthewboothphotography.com/weblog/media/boundaries5.jpg" border="0">';
gallery1[5]='<img src="http://www.matthewboothphotography.com/weblog/media/boundaries6.jpg" border="0">';
gallery1[6]='<img src="http://www.matthewboothphotography.com/weblog/media/boundaries7.jpg" border="0">';
gallery1[7]='<img src="http://www.matthewboothphotography.com/weblog/media/boundaries8.jpg" border="0">';
gallery1[8]='<img src="http://www.matthewboothphotography.com/weblog/media/boundaries9.jpg" border="0">';
gallery1[9]='<img src="http://www.matthewboothphotography.com/weblog/media/boundaries10.jpg" border="0">';
gallery1[10]='<img src="http://www.matthewboothphotography.com/weblog/media/boundaries11.jpg" border="0">';
gallery1[11]='<img src="http://www.matthewboothphotography.com/weblog/media/boundaries12.jpg" border="0">';

//optional additional gallery names, image trains, and usespace properties may be used:
//declare gallery2's name:
var gallery2=new Array();
// Use a space character between each image for this gallery? (use 1 for yes, 0 for no):
gallery2.usespace=1;
//define gallery2's image train:
gallery2[0]='<img src="http://www.matthewboothphotography.com/weblog/media/David_Northedge_004-1.jpg" border="0" hspace="4">';
gallery2[1]='<img src="http://www.matthewboothphotography.com/weblog/media/David_Northedge_005-1.jpg" border="0" hspace="4">';
gallery2[2]='<img src="http://www.matthewboothphotography.com/weblog/media/David_Northedge_006-1.jpg" border="0" hspace="4">';
gallery2[3]='<img src="http://www.matthewboothphotography.com/weblog/media/David_Northedge_007-1.jpg" border="0" hspace="4">';

//declare gallery3's name:
var gallery3=new Array();
// Use a space character between each image for this gallery? (use 1 for yes, 0 for no):
gallery3.usespace=1;
//define gallery3's image train:
gallery3[0]='<img src="http://www.matthewboothphotography.com/weblog/media/GasWorks_Martin_Beck_028.jpg" border="0" hspace="4">';
gallery3[1]='<img src="http://www.matthewboothphotography.com/weblog/media/GasWorks_Martin_Beck_028.jpg" border="0" hspace="4">';
gallery3[2]='<img src="http://www.matthewboothphotography.com/weblog/media/GasWorks_Martin_Beck_025.jpg" border="0" hspace="4">';
gallery3[3]='<img src="http://www.matthewboothphotography.com/weblog/media/GasWorks_Martin_Beck_017.jpg" border="0" hspace="4">';
gallery3[4]='<img src="http://www.matthewboothphotography.com/weblog/media/GasWorks_Martin_Beck_008.jpg" border="0" hspace="4">';
gallery3[5]='<img src="http://www.matthewboothphotography.com/weblog/media/GasWorks_Martin_Beck_010.jpg" border="0" hspace="4">';
gallery3[6]='<img src="http://www.matthewboothphotography.com/weblog/media/GasWorks_Martin_Beck_012.jpg" border="0" hspace="4">';
gallery3[7]='<img src="http://www.matthewboothphotography.com/weblog/media/GasWorks_Martin_Beck_014.jpg" border="0" hspace="4">';
gallery3[8]='<img src="http://www.matthewboothphotography.com/weblog/media/GasWorks_Martin_Beck_013.jpg" border="0" hspace="4">';


There could also be other problems, but these need to be fixed first and may be the only issues.

MatthewNBooth
10-25-2008, 11:51 AM
Problems solved, many thanks for your help. Thats sorted out the issue perfectly.