April 13, 201115 yr <!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"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Untitled Document</title> <link rel="stylesheet" href="slider.css" type="text/css" media="screen" /> <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js" type="text/javascript"></script> <script src="jquery.nivo.slider.pack.js" type="text/javascript"></script> <script type="text/javascript"> $(window).load(function() { $('#slider').nivoSlider() }); </script> </head> <body> <div id="wrapper"> <div id="slider"> <img src="images/slide1.jpg" alt="motherwell school of motoring" /> <img src="images/slide2.jpg" alt="driving lessons motherwell" /> <img src="images/slide3.jpg" alt="motherwell school of motoring car" /> <img src="images/slide4.jpg" alt="motherwell driving lessons" /> </div> </div> </body> </html> @charset "utf-8"; /* CSS Document */ #slider { position:relative; width:960px; /* Change this to your images width */ height:250px; /* Change this to your images height */ background:url(images/loading.gif) no-repeat 50% 50%; } #slider img { position:absolute; top:0px; left:0px; display:none; width:940px; /* Change this to your images width */ height:250px; /* Change this to your images height */ } #slider a { border:0; display:block; } #wrapper { width: 960px; } so the slider is working but for some strange reason down the left hand side of the page its seems to be showing the image going down the way ive attached image to show use what i mean and ive included my code and css
April 14, 201115 yr Author no dont have a link was just trying a few images i had lying about to see if i could get a slider to work
April 14, 201115 yr Make sure #slider and #slider img have the same width. Also try adding: overflow: hidden; for #slider
April 17, 201115 yr Author ive tried adding overflow: hidden; for #slider and all image widths are the same the overflow has helped now the images are not leaking out their container but its still not working properly ive uploaded it to a free server so use can see http://testerslide.comuf.com/
April 19, 201115 yr Don't do anything suggested above! It's not working because you've not included the CSS that came with Nivo Slider. If you want it working properly, upload the original CSS file. It's a complex plugin and trying to write your own CSS from scratch for it will be a complete nightmare and it doesn't look like you've got the technical ability to do it (not trying to be offensive, just honest). You'd be far better off customising the original CSS - it will be a lot easier and take a lot less time.
April 19, 201115 yr Author ive not wrote my own css the css file im using is the one that came with it, also im very up to date and no how to use both html and css very well so no offence taken, ive just seen sliders being used on other sites n thought they looked good hence why i wanted to try to get one working
April 19, 201115 yr ive not wrote my own css the css file im using is the one that came with it, also im very up to date and no how to use both html and css very well so no offence taken, ive just seen sliders being used on other sites n thought they looked good hence why i wanted to try to get one working Fair enough. I'm sorry for making that assumption then. I still can't see the nivo-slider.css file on your site though. I've attached a copy for you, if you upload it or just past the contents into your slider.css then the slider should work properly. nivo-slider.css
Create an account or sign in to comment