PDA

View Full Version : CMotion Image Gallery



Clorinde
12-11-2007, 04:14 PM
Hey,

I found this super cool image gallery but I can't implement it in my web page no matter where I place the codes.
Dynamic Drive DHTML Scripts- CMotion Image Gallery

Any genious out there?

This is my page, I would like the gallery inside the table after the text description what should I do?
Many Thanks.:)


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>clorinde</title>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1">
<style type="text/css">
<!--
body {
background-color: #FFFFFF;
background-image: url(template/Plaid%20Tight.gif);
}
body,td,th {
color: #000000;
font-family: Arial;
}
a:link {
text-decoration: none;
}
a:visited {
text-decoration: none;
}
a:hover {
text-decoration: none;
}
a:active {
text-decoration: none;
}
.style5 {
color: #FFFFFF;
font-family: Arial;
}
-->
</style>
<script language="JavaScript" type="text/JavaScript">
<!--


function MM_preloadImages() { //v3.0
var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0;
i<a.length; i++)
if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image;
d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
var p,i,x; if(!d) d=document;
if((p=n.indexOf("?"))>0&&parent.frames.length) {
d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++)
x=d.forms[i][n];
for(i=0;!x&&d.layers&&i<d.layers.length;i++)
x=MM_findObj(n,d.layers[i].document);
if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_nbGroup(event, grpName) { //v6.0
var i,img,nbArr,args=MM_nbGroup.arguments;
if (event == "init" && args.length > 2) {
if ((img = MM_findObj(args[2])) != null && !img.MM_init) {
img.MM_init = true; img.MM_up = args[3]; img.MM_dn = img.src;
if ((nbArr = document[grpName]) == null) nbArr =
document[grpName] = new Array();
nbArr[nbArr.length] = img;
for (i=4; i < args.length-1; i+=2) if ((img =
MM_findObj(args[i])) != null) {
if (!img.MM_up) img.MM_up = img.src;
img.src = img.MM_dn = args[i+1];
nbArr[nbArr.length] = img;
} }
} else if (event == "over") {
document.MM_nbOver = nbArr = new Array();
for (i=1; i < args.length-1; i+=3) if ((img = MM_findObj(args[i]))
!= null) {
if (!img.MM_up) img.MM_up = img.src;
img.src = (img.MM_dn && args[i+2]) ? args[i+2] : ((args[i+1])?
args[i+1] : img.MM_up);
nbArr[nbArr.length] = img;
}
} else if (event == "out" ) {
for (i=0; i < document.MM_nbOver.length; i++) {
img = document.MM_nbOver[i]; img.src = (img.MM_dn) ? img.MM_dn :
img.MM_up; }
} else if (event == "down") {
nbArr = document[grpName];
if (nbArr)
for (i=0; i < nbArr.length; i++) { img=nbArr[i]; img.src =
img.MM_up; img.MM_dn = 0; }
document[grpName] = nbArr = new Array();
for (i=2; i < args.length-1; i+=2) if ((img = MM_findObj(args[i]))
!= null) {
if (!img.MM_up) img.MM_up = img.src;
img.src = img.MM_dn = (args[i+1])? args[i+1] : img.MM_up;
nbArr[nbArr.length] = img;
} }
}
//-->
</script>
<script language="JavaScript" type="text/JavaScript">
<!--
function MM_reloadPage(init) { //reloads the window if Nav4 resized
if (init==true) with (navigator) {if
((appName=="Netscape")&&(parseInt(appVersion)==4)) {
document.MM_pgW=innerWidth; document.MM_pgH=innerHeight;
onresize=MM_reloadPage; }}
else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH)
location.reload();
}
MM_reloadPage(true);
//-->
</script>
</head>

<body
onLoad="MM_preloadImages('template/live%20on.gif','template/info%20on.gif','template/images%20on.gif','template/works%20on.gif','template/extra%20on.gif','template/guestbook%20on.gif','template/news%20on.gif','template/links%20on.gif','template/contact%20on.gif','template/news.gif')">
<table width="200" align="center" cellpadding="0" cellspacing="1"
bordercolor="#000000" bgcolor="#CCCCCC">
<tr>
<td height="83"><object
classid="clsid27CDB6E-AE6D-11cf-96B8-444553540000"
codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0"
width="765" height="96">
<param name="movie" value="template/head%20animation.swf">
<param name="quality" value="high">
<embed src="template/head%20animation.swf" quality="high"
pluginspage="http://www.macromedia.com/go/getflashplayer"
type="application/x-shockwave-flash" width="765" height="96"></embed>
</object></td>
</tr>
<tr>
<td height="33" bgcolor="#FFFFFF"><div align="center">
<table border="0" cellpadding="0" cellspacing="0">
<tr>
<td><a href="index.htm" target="_top"
onClick="MM_nbGroup('down','group1','news','',1)"
onMouseOver="MM_nbGroup('over','news','template/news%20on.gif','',1)" onMouseOut="MM_nbGroup('out')"><img
src="template/news.gif" alt="news" name="news" width="60" height="33" border="0"
onload=""></a></td>
<td><a href="live.htm" target="_top"
onClick="MM_nbGroup('down','group1','live','',1)"
onMouseOver="MM_nbGroup('over','live','template/live%20on.gif','',1)" onMouseOut="MM_nbGroup('out')"><img
src="template/live.gif" alt="live" name="live" width="42" height="33" border="0"
onload=""></a></td>
<td><a href="javascript:;" target="_top"
onClick="MM_nbGroup('down','group1','info','',1)"
onMouseOver="MM_nbGroup('over','info','template/info%20on.gif','',1)" onMouseOut="MM_nbGroup('out')"><img
src="template/info.gif" alt="info" name="info" width="44" height="33"
border="0" onload=""></a></td>
<td><a href="images.htm" target="_top"
onClick="MM_nbGroup('down','group1','images','',1) "
onMouseOver="MM_nbGroup('over','images','template/images%20on.gif','',1)" onMouseOut="MM_nbGroup('out')"><img
src="template/images.gif" alt="images" name="images" width="76"
height="33" border="0" onload=""></a></td>
<td><a href="works.htm" target="_top"
onClick="MM_nbGroup('down','group1','works','',1)"
onMouseOver="MM_nbGroup('over','works','template/works%20on.gif','',1)" onMouseOut="MM_nbGroup('out')"><img
src="template/works.gif" alt="works" name="works" width="66" height="33"
border="0" onload=""></a></td>
<td><a href="extra.htm" target="_top"
onClick="MM_nbGroup('down','group1','extra','',1)"
onMouseOver="MM_nbGroup('over','extra','template/extra%20on.gif','',1)" onMouseOut="MM_nbGroup('out')"><img
src="template/extra.gif" alt="extra" name="extra" width="60" height="33"
border="0" onload=""></a></td>
<td><a href="http://clorinde.123guestbook.com/"
target="_blank" onClick="MM_nbGroup('down','group1','guestbook','' ,1)"
onMouseOver="MM_nbGroup('over','guestbook','templa te/guestbook%20on.gif','',1)"
onMouseOut="MM_nbGroup('out')"><img src="template/guestbook.gif"
alt="guestbook" name="guestbook" width="106" height="33" border="0"
onload=""></a></td>
<td><a href="links.htm" target="_top"
onClick="MM_nbGroup('down','group1','links','',1)"
onMouseOver="MM_nbGroup('over','links','template/links%20on.gif','',1)" onMouseOut="MM_nbGroup('out')"><img
src="template/links.gif" alt="links" name="links" width="50" height="33"
border="0" onload=""></a></td>
<td><a href="contact.htm" target="_top"
onClick="MM_nbGroup('down','group1','contact','',1 )"
onMouseOver="MM_nbGroup('over','contact','template /contact%20on.gif','',1)"
onMouseOut="MM_nbGroup('out')"><img src="template/contact.gif" alt="contact" name="contact" width="81"
height="33" border="0" onload=""></a></td>
</tr>
</table>
</div></td>
</tr>
<tr bgcolor="#0099FF">
<td height="19" bordercolor="#000000" bgcolor="#6699CC"><div
align="center" class="style5">- Info about Clorinde -</div></td>
</tr>
<tr bgcolor="#0099FF">
<td height="500" valign="top" bordercolor="#000000"
bgcolor="#DBDBDB"><blockquote>
<p align="justify">Clorinde was formed in the year 2005 in the
city of Glasgow , Scotland by two Italian brothers Andrea Salvatici and
Simone Salvatici. <br>
Their musical roots lie around the town of Florence , Italy .
Each one of them had formed a number of music projects in the late
90's exploring a variety of music styles, from Punk and Experimental to
Ambient/Noise and Electronica, with a particular interest in video art.
Both Andrea and Simone have been developing their skills in a wide range
of musical instruments since an early age. <br>
Amongst the instruments used are electric, acoustic and
classical guitars, bass guitars, 6 string banjo, mandolin, glockenspiels,
accordion, kalimbas, concert zither, percussive woods, laptops, keyboards
and electronic devices.
</p>
<p align="justify">Fat Cat Records described their music as a
really luscious minimalist style that recalls Steve Reich / Arnold
Dreyblatt / etc. Very cool and beautiful stuff with everything sounding like
it's in its right place. </p>
</blockquote> </td>
</tr>
<tr bgcolor="#0099FF">
<td height="18" bordercolor="#000000" bgcolor="#6699CC">&nbsp;</td>
</tr>
</table>

<p>&nbsp;</p>
</body>
</html>

jscheuer1
12-12-2007, 05:01 PM
Warning: Please include a link to the DD script in question in your post. See this thread (http://www.dynamicdrive.com/forums/showthread.php?t=6) for the proper posting format when asking a question.

Sounds like an onload conflict, but I don't see the DD script or its markup anywhere in your code. As a test, place the code on your page according to the instructions on the demo page, and get rid of this:


onLoad="MM_preloadImages('template/live%20on.gif','template/info%20on.gif','template/images%20on.gif','template/works%20on.gif','template/extra%20on.gif','template/guestbook%20on.gif','template/news%20on.gif','template/links%20on.gif','template/contact%20on.gif','template/news.gif')"

Then get back to me and tell me what happened. Also, pasting source code to an entire page in the editor isn't the best way for us to see what's going on:

Please post a link to the page on your site that contains the problematic code so we can check it out.

Clorinde
12-13-2007, 06:02 PM
Sounds like an onload conflict, but I don't see the DD script or its markup anywhere in your code. As a test, place the code on your page according to the instructions on the demo page, and get rid of this:


onLoad="MM_preloadImages('template/live%20on.gif','template/info%20on.gif','template/images%20on.gif','template/works%20on.gif','template/extra%20on.gif','template/guestbook%20on.gif','template/news%20on.gif','template/links%20on.gif','template/contact%20on.gif','template/news.gif')"


Thanks, for replying. I can't get rid of that, it's my navigation bar...
I didn't post a link cause it's not online yet.
I notice that if I put the script in the body before the html code it works fine.
Don't know much about this stuff, I'm afraid...

jscheuer1
12-13-2007, 06:18 PM
Warning: Please include a link to the DD script in question in your post. See this thread (http://www.dynamicdrive.com/forums/showthread.php?t=6) for the proper posting format when asking a question.

Please work with us here, or go elsewhere for help.

I said as a test:


As a test, place the code on your page according to the instructions on the demo page, and get rid of this:


onLoad="MM_preloadImages('template/live%20on.gif','template/info%20on.gif','template/images%20on.gif','template/works%20on.gif','template/extra%20on.gif','template/guestbook%20on.gif','template/news%20on.gif','template/links%20on.gif','template/contact%20on.gif','template/news.gif')"

Then get back to me and tell me what happened.

If you don't want to, fine. But I just wanted to test it, if that solved it, and you provide a link to the script here on DD, it should be easy to combine the two. Putting the script in the body as you say will effectively perform the same test, as it will override the body onload event.