Hello friends,
i want to add a fading scroller where i will display some text and images in the side bar for that i have used this code from dynamicdrive and put it in this sidebar include
sidebar3.inc.php
<div id="menuBlock"><!-- left side menu -->
<div class="box boxText firstBox">
<div><a href="chatroll.htm" target="_blank" onclick='showPopup(this.href);return(false);'><img src="../images/live%20support.gif" border="0" alt="** PLEASE DESCRIBE THIS IMAGE **" /></a></div>
<div class="c10"><script type="text/javascript">
/***********************************************
* Fading Scroller- © Dynamic Drive DHTML code library (www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit Dynamic Drive at http://www.dynamicdrive.com/ for full source code
***********************************************/
var delay = 2000; //set delay between message change (in miliseconds)
var maxsteps=30; // number of steps to take to change from start color to endcolor
var stepdelay=40; // time in miliseconds of a single step
//**Note: maxsteps*stepdelay will be total time in miliseconds of fading effect
var startcolor= new Array(255,255,255); // start color (red, green, blue)
var endcolor=new Array(0,0,0); // end color (red, green, blue)
var fcontent=new Array();
begintag='<div class="c10 c9">'; //set opening tag, such as font declarations
fcontent[0]="Hello Welcome<br />to our newly Launched site<br />
<br /><strong>"www.webdesigncut.com"<br /></strong>";
fcontent[1]="This site is nearing completion<br />
<br />
<strong>A unique web-solution</strong><br />
Thank you for your visit<br />";
fcontent[2]="Check Our<br />
<strong>Special package of starting a Website</strong><br />
at <strong>Rs2688(INR)</strong> or <strong>$56</strong><br />
transaction charges extra<br />
<br />";
fcontent[3]="For any kind of business enquiry please feel free to contact us at the given email ids:<br />
<strong>webdesigncut@gmail.com</strong><br />
<br />
<strong>souravsaha0@gmail.com</strong><br />
<br />
or call us at<br />
<strong>+913326838023</strong><br />
by webdesigncut Team";
closetag='</div>';
var fwidth='150px'; //set scroller width
var fheight='150px'; //set scroller height
var fadelinks=1; //should links inside scroller content also fade like text? 0 for no, 1 for yes.
///No need to edit below this line/////////////////
var ie4=document.all&&!document.getElementById;
var DOM2=document.getElementById;
var faderdelay=0;
var index=0;
/*Rafael Raposo edited function*/
//function to change content
function changecontent(){
if (index>=fcontent.length)
index=0
if (DOM2){
document.getElementById("fscroller").style.color="rgb("+startcolor[0]+", "+startcolor[1]+", "+startcolor[2]+")"
document.getElementById("fscroller").innerHTML=begintag+fcontent[index]+closetag
if (fadelinks)
linkcolorchange(1);
colorfade(1, 15);
}
else if (ie4)
document.all.fscroller.innerHTML=begintag+fcontent[index]+closetag;
index++
}
// colorfade() partially by Marcio Galli for Netscape Communications. ////////////
// Modified by Dynamicdrive.com
function linkcolorchange(step){
var obj=document.getElementById("fscroller").getElementsByTagName("A");
if (obj.length>0){
for (i=0;i<obj.length;i++)
obj[i].style.color=getstepcolor(step);
}
}
/*Rafael Raposo edited function*/
var fadecounter;
function colorfade(step) {
if(step<=maxsteps) {
document.getElementById("fscroller").style.color=getstepcolor(step);
if (fadelinks)
linkcolorchange(step);
step++;
fadecounter=setTimeout("colorfade("+step+")",stepdelay);
}else{
clearTimeout(fadecounter);
document.getElementById("fscroller").style.color="rgb("+endcolor[0]+", "+endcolor[1]+", "+endcolor[2]+")";
setTimeout("changecontent()", delay);
}
}
/*Rafael Raposo's new function*/
function getstepcolor(step) {
var diff
var newcolor=new Array(3);
for(var i=0;i<3;i++) {
diff = (startcolor[i]-endcolor[i]);
if(diff > 0) {
newcolor[i] = startcolor[i]-(Math.round((diff/maxsteps))*step);
} else {
newcolor[i] = startcolor[i]+(Math.round((Math.abs(diff)/maxsteps))*step);
}
}
return ("rgb(" + newcolor[0] + ", " + newcolor[1] + ", " + newcolor[2] + ")");
}
if (ie4||DOM2)
document.write('<div id="fscroller" style="border:1px solid black;width:'+fwidth+';height:'+fheight+'"></div>');
if (window.addEventListener)
window.addEventListener("load", changecontent, false)
else if (window.attachEvent)
window.attachEvent("onload", changecontent)
else if (document.getElementById)
window.onload=changecontent
</script></div>
</div>
<div class="applemenu">
<div class="silverheader"><a href="http://www.webdesigncut.com/companyprofile/">Company profile</a></div>
<div class="submenu">
<p><strong>Webdesigncut</strong> has been in this industry for over 3 years and within this short span of time we have made our presence felt all over India and abroad.</p>
<p>Webdesigncut provides comprehensive business solutions and services which<br />
include <strong>Web hosting,web designing</strong>Graphic designing which includes brochure,flyers,logo designing to mention few.<br />
<a href="http://www.webdesigncut.com/companyprofile/">>> Read more <!--[if IE 7]><!--></a></p>
</div>
<div class="silverheader"><a href="">Web Services</a></div>
<div class="submenu"><strong><a href="http://www.webdesigncut.com/webdesign/">Website Design</a></strong><br />
<a href="http://www.webdesigncut.com/webdesign/smallbusiness/">Small Business Websites</a><br />
<a href="http://www.webdesigncut.com/webdesign/ecommerce/">Ecommerce Website Design</a><br />
<a href="http://www.webdesigncut.com/webdesign/cms/">CMS Websites</a><br />
<a href="http://www.webdesigncut.com/webdesign/databasedriven/">Databasedriven WebSites</a><br />
<a href="http://www.webdesigncut.com/webdesign/personal/">Personal WebSites</a><br />
<a href="http://www.webdesigncut.com/webdesign/siteredesign/">Site Redesigns</a><br />
<a href="http://www.webdesigncut.com/webdesign/websitemaintenance/">WebSite maintenance</a><br />
<strong><a href="http://www.webdesigncut.com/webhosting/">Website Hosting</a></strong><br />
<a href="http://www.webdesigncut.com/webhosting/domainnameregistration/">Domain name registration</a><br />
<a href="http://www.webdesigncut.com/webhosting/windowshosting/">Windows hosting</a><br />
<a href="http://www.webdesigncut.com/webhosting/linuxhosting/">Linux hosting</a><br />
<strong><a href="http://www.webdesigncut.com/internetmarketing/">Internet marketing</a></strong><br />
<a href="http://www.webdesigncut.com/internetmarketing/searchenginesubmission/">Search engine submission</a><br />
<a href="http://www.webdesigncut.com/internetmarketing/directorysubmission/">Directory submission</a><br />
<a href="http://www.webdesigncut.com/internetmarketing/contentwritting/">Content writing<br /></a>
<strong><a href="http://www.webdesigncut.com/templates/">Web Templates</a></strong><br />
</div>
<div class="silverheader"><a href="http://www.webdesigncut.com/internetmarketing/contentwritting/">Graphic designing</a></div>
<div class="submenu"><a href="http://www.webdesigncut.com/graphicdesign/logodesign/">Logo design</a><br />
<a href="http://www.webdesigncut.com/graphicdesign/bannerdesign/">Banner design</a><br />
<a href="http://www.webdesigncut.com/graphicdesign/brochuredesign/">Brochure design</a><br />
<a href="http://www.webdesigncut.com/graphicdesign/photoretouching/">Image retouching</a><br />
<a href="http://www.webdesigncut.com/graphicdesign/stationarydesign/Stationary design">Stationary design</a><br />
<a href="http://www.webdesigncut.com/graphicdesign/flyerdesign/">Flyer design</a><br /></div>
<div class="silverheader"><a href="http://www.webdesigncut.com/animations/">Animations</a></div>
<div class="submenu">
<a href="http://www.webdesigncut.com/animations/webbanneranimations/">Web banner animations</a><br />
<a href="http://www.webdesigncut.com/animations/3dlogoanimations/">3d logo animations</a><br />
<a href="http://www.webdesigncut.com/animations/webbanneranimations/">Web banner animations</a><br />
<a href="http://www.webdesigncut.com/animations/flashanimations/">Flash animations</a><br />
<a href="http://www.webdesigncut.com/animations/jqueryanimations/">Jquery animations</a><br />
<img src="http://i27.tinypic.com/sy7295.gif" alt="** PLEASE DESCRIBE THIS IMAGE **" /></div>
<div class="silverheader"><a href="http://www.webdesigncut.com/portfolio/">Portfolio</a></div>
<div class="submenu">
Web design<br />
Graphic design<br />
Banner design<br />
Animations<br />
</div>
<div class="silverheader"><a href="#">Tutorials</a></div>
<div class="submenu">Some random content here<br /></div>
<div class="silverheader"><a href="http://www.webdesigncut.com/blog/">Latest Blog posts</a></div>
<div class="submenu">
<a href="http://www.webdesigncut.com/blog/2010/03/essential-checks-before-launching-your-website/">Essential checks before launching website</a><br/>
<a href="http://www.webdesigncut.com/blog/2010/03/10-free-mobile-application-development-icon-sets/">Mobile Application development icons</a><br/>
<a href="http://www.webdesigncut.com/blog/2010/03/20-superb-t-shirt-designs/">20 Superb T shirt designs</a><br/>
<a href="http://www.webdesigncut.com/blog/2010/03/top-10-magazines-for-webdesigners3d-artists-and-photographers/">Magazines for webdesigners and 3d artists</a><br/>
<a href="http://www.webdesigncut.com/blog/2010/03/discover-the-power-of-contentmanagement-system/">Discover the power of CMS</a><br/>
<a href="http://www.webdesigncut.com/blog/2010/03/how-to-make-money-with-your-website/">How to make money from your website</a><br/>
<a href="http://www.webdesigncut.com/blog/2010/02/the-many-approaches-to-web-design/">Many approaches to webdesign</a><br/>
<a href="http://www.webdesigncut.com/blog/2010/02/banner-advertising-the-easiest-way-to-get-1000-visitors-a-day/">Banner Advertising Facts</a><br/>
</div>
<div class="silverheader"><a href="#">Get a Quick quote</a></div>
<div class="submenu">
<form name="quick_form" method="post" action="http://webdesigncut.com/sendmail.php" onsubmit="return form_validation()">
<table width="100%" border="0" cellpadding="5" cellspacing="0" align="center">
<tr>
<td align="center" valign="middle"><input name="name" type="text" class="form-white-text c11" id="name" value="name*" /></td>
</tr>
<tr>
<td align="center" valign="middle"><input name="email" type="text" class="form-white-text c12" id="email" value="email*" /></td>
</tr>
<tr>
<td align="center" valign="middle"><input name="phone" type="text" class="form-white-text c12" id="phone" value="phone*" /></td>
</tr>
<tr>
<td align="center" valign="middle"><select name="project" class="form-white-text c13">
<option value="project" selected="selected">project</option>
<option value="Identity Design">Web page design</option>
<option value="Brochure">Web development</option>
<option value="Ad Design">Internet marketing</option>
<option value="Poster & Banners">Website hosting</option>
<option value="Packaging">Graphic design</option>
<option value="Commercial Graphics">Banner design</option>
<option value="Illustrations">Brochure design</option>
<option value="Illustrations">Image retouching</option>
<option value="Illustrations">Flyers</option>
<option value="Illustrations">Animations</option>
</select></td>
</tr>
<tr>
<td align="center" valign="middle">
<textarea name="comments" cols="17" class="form-white-text c14">
</textarea></td>
</tr>
<tr>
<td align="center" valign="middle"><input name="Request a quote" type="submit" class="black-text" value="Request a quote" /></td>
</tr>
</table>
</form>
</div>
</div>
<br /></div>
<!-- left side menu end -->
</div>
<!-- content end -->
and added this in scroller.php
<?
// The next lines sets gzip compression on!
ob_start("ob_gzhandler");
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="cs" lang="cs">
<head>
<meta name="generator" content="HTML Tidy for Linux (vers 6 November 2007), see www.w3.org" />
<title>Webdesigncut | Website design and hosting company in Kolkata,West Bengal|Cheap Web Hosting Hooghly</title>
<?php
header("Cache-Control: must-revalidate");
$offline = 60 * 60 * 24 * 3;
header("Expires: " .
gmdate("D, d M Y H:i:s",
time() + $offline) . " GMT");
?>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"/>
<meta name="Keywords" content="Webdesigncut,web design,graphic design,website design and hosting company in Kolkata,Hooghly,West Bengal" />
<meta name="Description" content="Webdesigncut is a India based web designing and hosting company providing unique design solutions in other various fields like internet marketing,grpahic designing,logo designing,brochure designing all over West Bengal,Hooghly and throughought the country." />
<meta name="author" content="Webdesigncut Team" />
<meta name="robots" content="all" />
<meta name="verify-v1" content="kb69oTiAXXkrEREN8DuuCQDRYmCajiZj8i0ipuNfyw8=" />
<meta name="google-site-verification" content="MgltG4zOlUaigzolFotCNo48Z7XK5uC6ogJdVnX9CpA" />
<meta name="google-site-verification" content="a9IUgKAceFaMWfpMpfBAUFhr_SgKT0DZwH4sBcp-zR0" />
<meta name="y_key" content="29aad7aed01eb74c"/>
<link rel="stylesheet" type="text/css" href="css/default.css" media="screen" />
<link rel="stylesheet" type="text/css" href="css/print.css" media="print" />
<link rel="SHORTCUT ICON" href="images/favicon.ico" />
</head>
<?php flush(); ?>
<body>
<div id="view"><!--container start-->
<?php include("includes/header.inc.php"); ?>
<hr class="hidden" />
<?php include("includes/menu.inc.php"); ?>
<!-- Navigation Menu end -->
<hr class="hidden" />
<div id="logo2"><a href="#" class="block"></a><!-- header banner start -->
<h2 id="bannerheader">Webdesigncut bringing<br/> dreams to reality</h2>
<p class="banner">Webdesign,Webhosting,Webdevelopment,Internetmarketing<br /> Graphic designing,Logo designing,brochure design,<br/>Webinterface design
Content writting,<br />Animations and more....<br />
</p>
</div>
<!-- header banner end -->
<hr class="hidden" /></div>
<div id="content"><!-- content start -->
<div class="col1 item itemOdd" id="contentBlock">
<div class="c7">
<h1>Web Design and hosting Company Webdesigncut</h1>
<p><strong>Webdesigncut</strong> is one of the most promising <a>web design and hosting company</a> creating custom web design and hosting at the cheapest price</p>
<p>Every great business idea takes leaps and bounds with the launch of a professionally designed website.With the advancement of technology and internet your business can see new horizons and your website will enhance it in every possible way .<br />
A legal presence in the web world has become the ultimate need of every company to become the leader in their industry.Launching a web site only will not get the job done,but you have to build a network between you and your potential customers through this unique invention of mankind.</p>
</div>
<?php include("includes/icons.inc.php"); ?>
<?php include("includes/sidebar3.inc.php"); ?>
<hr class="hidden" />
<hr class="hidden" />
<?php include("includes/footer.inc.php"); ?>
<!--container end-->
<!---javascript-->
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js">
</script>
<script type="text/javascript" src="ddaccordion.js">
</script>
<script type="text/javascript" src="javascript/base0000.js">
</script>
<script type="text/javascript" src="javascript/menu0000.js">
</script>
<script type="text/javascript" src="javascript/form%20validation.js">
</script>
<script type="text/javascript">
//<![CDATA[
ddaccordion.init({
headerclass: "silverheader", //Shared CSS class name of headers group
contentclass: "submenu", //Shared CSS class name of contents group
revealtype: "mouseover", //Reveal content when user clicks or onmouseover the header? Valid value: "click", "clickgo", or "mouseover"
mouseoverdelay: 200, //if revealtype="mouseover", set delay in milliseconds before header expands onMouseover
collapseprev: true, //Collapse previous content (so only one open at any time)? true/false
defaultexpanded: [0], //index of content(s) open by default [index1, index2, etc] [] denotes no content
onemustopen: true, //Specify whether at least one header should be open always (so never all headers closed)
animatedefault: false, //Should contents open by default be animated into view?
persiststate: true, //persist state of opened contents within browser session?
toggleclass: ["", "selected"], //Two CSS classes to be applied to the header when it's collapsed and expanded, respectively ["class1", "class2"]
togglehtml: ["", "", ""], //Additional HTML added to the header when it's collapsed and expanded, respectively ["position", "html1", "html2"] (see docs)
animatespeed: "fast", //speed of animation: integer in milliseconds (ie: 200), or keywords "fast", "normal", or "slow"
oninit:function(headers, expandedindices){ //custom code to run when headers have initalized
//do nothing
},
onopenclose:function(header, index, state, isuseractivated){ //custom code to run whenever a header is opened or closed
//do nothing
}
})
//]]>
</script>
<script type="text/JavaScript" src="javascript/curvycorners.src.js">
</script>
<script type="text/JavaScript">
//<![CDATA[
addEvent(window, 'load', initCorners);
function initCorners() {
var settings = {
tl: { radius: 10 },
tr: { radius: 10 },
bl: { radius: 10 },
br: { radius: 10 },
antiAlias: true
}
/*
Usage:
curvyCorners(settingsObj, selectorStr);
curvyCorners(settingsObj, Obj1[, Obj2[, Obj3[, . . . [, ObjN]]]]);
selectorStr ::= complexSelector [, complexSelector]...
complexSelector ::= singleSelector[ singleSelector]
singleSelector ::= idType | classType
idType ::= #id
classType ::= [tagName].className
tagName ::= div|p|form|blockquote|frameset // others may work
className : .name
selector examples:
#mydiv p.rounded
#mypara
.rounded
*/
curvyCorners(settings, ".myBox");
}
//]]>
</script>
<!--javascript end-->
</body>
</html>
but i dont see anything here