Using a custom variable in a 3rd party jQuery plugin
I am not so great at writing jQuery yet so pardon the naive question:

I would like the place the value of a clicked href into the 'backstretch' jQ plugin. ( http://srobbin.com/jquery-plugins/jquery-backstretch/ )

my code looks like this:


	$(function() {

		var bgImage = $('.active').attr("href"); //gets the value of the href on the a with the class 'active' and puts it in a variable.
	
		
		$('.clicks a').click(function() {
			$('.clicks a').removeClass('active');
			$(this).addClass('active');
			return false;
		}) //removes all 'active' classes, and puts the 'active' class on the clicked a tag.
		
		
		$.backstretch("bgImage", {speed: 150}); // uses the value the variable in this plugin.

	}); //end.ready


Its not working though, any ideas? Thanks in advance!
Using a custom variable in a 3rd party jQuery plugin
===

I am not so great at writing jQuery yet so pardon the naive question:

I would like the place the value of a clicked href into the 'backstretch' jQ plugin. ( http://srobbin.com/jquery-plugins/jquery-backstretch/ )

my code looks like this:


	$(function() {

		var bgImage = $('.active').attr("href"); //gets the value of the href on the a with the class 'active' and puts it in a variable.
	
		
		$('.clicks a').click(function() {
			$('.clicks a').removeClass('active');
			$(this).addClass('active');
			return false;
		}) //removes all 'active' classes, and puts the 'active' class on the clicked a tag.
		
		
		$.backstretch("bgImage", {speed: 150}); // uses the value the variable in this plugin.

	}); //end.ready


Its not working though, any ideas? Thanks in advance!