PAID WORK: Javascript

Miscellaneous Forums/General Discussion/PAID WORK: Javascript

Hi, we are using OSAKit to get a blitz application on-line, and would like someone to help us with the way the embedded object loads into the page. What we are after is something like how quick time works.

I can't seem to find an example, but we would like an image to be on the web page, the browser is detected and if running i.e. or firefox a different image is shown.

Then when the visitor clicks on the image the embedded object loads in in its place. We want this so a visitor to a site with an osakit object in it won't get asked to install the plug-in when they first load the page, only if/when they click on the image and want to use it.

Please send me and email to me@... and your rates, I can provide a more detailed spec if you need it.

How much are you paying?

Darkheart

Can you provide an OSAKit license for testing?

We cannot provide an OSAKit licence for testing, but you shouldn't need one, it is nothing specific to OSAKit, I assume it can be handled just as an embedded object. We have the object that needs embedding, which obviously will be provided.

If you send us an email with the amount we will review it. Not knowing too much about Javascript, I would assume it would be under 500 lines of code. In essence its a 'when clicked on the image, then load the object'.

I whipped this up (quick and dirty method) and should be easy to understand :

<html>
<body>
	<div id="ImageHolder"></div>

	<script language="javascript">
		var isIE	= (navigator.appName.indexOf("Microsoft")!=-1)?1:0;
		var isOpera	= (navigator.appName.indexOf("Opera")!=-1)?1:0;
		var isNetscape	= (navigator.appName.indexOf("Netscape")!=-1)?1:0; // isNetscape works for firefox too

		function loadImage() {
			if (isIE) 	{ document.getElementById("ImageHolder").innerHTML = "<a href='#' onclick='loadGame();'><img border='2' src='IE_Image.jpg' width='100' height='100' /></a>"; }
			if (isOpera) 	{ document.getElementById("ImageHolder").innerHTML = "<a href='#' onclick='loadGame();'><img border='2' src='Opera_Image.jpg' width='100' height='100' /></a>"; }
			if (isNetscape)	{ document.getElementById("ImageHolder").innerHTML = "<a href='#' onclick='loadGame();'><img border='2' src='Firefox_Image.jpg' width='100' height='100' /></a>"; }

		}

		function loadGame() {
			if (isIE) 	{ document.getElementById("ImageHolder").innerHTML = "I am Internet Explorer"; }
			if (isOpera) 	{ document.getElementById("ImageHolder").innerHTML = "I am Opera"; }
			if (isNetscape)	{ document.getElementById("ImageHolder").innerHTML = "I am Firefox / Netscape"; }
		}

		loadImage();
	</script>
</body>
</html>


It loads an image in for each browser (no images to supply so I've set the border to 2 so you can see) and clicking on it displays which browser it is. Simply replace the "I am Firefox" text with your embedded object code (in one line).

If you get it working then perhaps send me a nice paypal donation :p

*edit* I've assumed that OSAKit has different methods per browser? - I never used it. If OSAKit launches the same way for each browser then replace the loadGame() code with just one line of document.getElemen....etc

Hi Qube, did you get my email?


Hi Qube, did you get my email?


Nope, I've not had an email arrive - could you send again? :)

Hi, I have resent it, if you don't have it still then send me an email to my addy in my profile with your msn or skype address in (if you have one) :)

are you on msn Qube?

Got your email :) - No, I don't use MSN