Image Rollovers in Posts?

3,124
Bradopoly
Sorry if this has been asked before, did a search but didn't come up with anything.

I was just wondering if there was any way to make an image rollover in a post?

Here is my code for a test rollover where the images are hosted at imageshack.


HTML:
<HTML>
<HEAD>
<TITLE>Untitled-1</TITLE>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<!-- ImageReady Preload Script (Untitled-1) -->
<SCRIPT TYPE="text/javascript">
<!--

function newImage(arg) {
	if (document.images) {
		rslt = new Image();
		rslt.src = arg;
		return rslt;
	}
}

function changeImages() {
	if (document.images && (preloadFlag == true)) {
		for (var i=0; i<changeImages.arguments.length; i+=2) {
			document[changeImages.arguments[i]].src = changeImages.arguments[i+1];
		}
	}
}

var preloadFlag = false;
function preloadImages() {
	if (document.images) {
		Untitled_1_01_over = newImage("http://img149.imageshack.us/img149/334/untitled101yt5.gif");
		preloadFlag = true;
	}
}

// -->
</SCRIPT>
<!-- End Preload Script -->
</HEAD>
<BODY BGCOLOR=#FFFFFF LEFTMARGIN=0 TOPMARGIN=0 MARGINWIDTH=0 MARGINHEIGHT=0 ONLOAD="preloadImages();">
<!-- ImageReady Slices (Untitled-1) -->
<A HREF="#"
	ONMOUSEOVER="changeImages('Untitled_1_01', 'http://img267.imageshack.us/img267/4299/untitled101overns4.gif'); return true;"
	ONMOUSEOUT="changeImages('Untitled_1_01', 'http://img149.imageshack.us/img149/334/untitled101yt5.gif'); return true;">
	<IMG NAME="Untitled_1_01" SRC="http://img149.imageshack.us/img149/334/untitled101yt5.gif" WIDTH=269 HEIGHT=269 BORDER=0 ALT=""></A>
<!-- End ImageReady Slices -->
</BODY>

</HTML>


Thanks.

Drift2XS
 
Well, for various reasons, HTML code is prohibited from posts. The most you can do using Vbulletin tags is use the image in place of link text in a [ url ] tag. That may not even work if the image is hosted at Imageschack because I believe that the VB/IS integration means that all images hosted there and posted inline (rather than as a thumb) are automatically a generic link to Imageshack.
 
Sorry, it is not possible to create any kind of image rollover effect in posts here.
 
No problem, just wanted to know. Thought it would be a cool idea for presentations in my gallery. :)

Thanks for the quick response Duke and Jordan. Suburb work on the site too, love being a member here. 👍
 
Back