Question java script and login box issue

Status
Not open for further replies.

jjohns12

Customer
Hi

Can you help me to get forum ads to play nice with my themes login box?

Forum Ads - Purchase Advertisements - East Coast Surfcasters The Forum none of the forum ads functions work like add to cart and packages tab.

everything works good in the default theme and it must be with the login box for the current theme.

Code:
<script type="text/javascript">
$(document).ready(function() {
	$('a.login-window').click(function() {
		
		var loginBox = '#login-box';

		$(loginBox).fadeIn(300);
		
		var popMargTop = ($(loginBox).height() + 24) / 2; 
		var popMargLeft = ($(loginBox).width() + 24) / 2; 
		
		$(loginBox).css({ 
			'margin-top' : -popMargTop,
			'margin-left' : -popMargLeft
		});
		
		$('body').append('<div id="mask"></div>');
		$('#mask').fadeIn(300);
		
		return false;
	});
	
	$('a.close, #mask').live('click', function() { 
	  $('#mask , .login-popup').fadeOut(300 , function() {
		$('#mask').remove();  
	}); 
	return false;
	});
});
</script>

Thank you
James
 
That JS code doesn't work with the newest version of jQuery v1, which is what they are loading.

Change it to this:
Code:
<script type="text/javascript">
$(document).ready(function() {
	$('a.login-window').on('click', function() {
		
		var loginBox = '#login-box';

		$(loginBox).fadeIn(300);
		
		var popMargTop = ($(loginBox).height() + 24) / 2; 
		var popMargLeft = ($(loginBox).width() + 24) / 2; 
		
		$(loginBox).css({ 
			'margin-top' : -popMargTop,
			'margin-left' : -popMargLeft
		});
		
		$('body').append('<div id="mask"></div>');
		$('#mask').fadeIn(300);
		
		return false;
	});
	
	$('a.close, #mask').on('click', function() { 
	  $('#mask , .login-popup').fadeOut(300 , function() {
		$('#mask').remove();  
	}); 
	return false;
	});
});
</script>

And it should work.
 
WOW thanks for the quick response!

I tried the new code for the login box but no luck same issue maybe its not the login box causing the issue. Any Idea how i can solve this?

Thanks for your help
James
 
Ah I see the issue, it would appear as if the ForumAds JS file hasn't been updated. Could you please make sure you've updated to v2.1.1?
 
I checked in installed products and v2.1.1 was installed.

I re downloaded v2.1.1 and uploaded the files and ................

It worked! :)

I don't know what happened the first time with the upload but you know how it is "the human error thing" :eek:

Thank You so muck for the quick response!
James
 
Hello jjohns12,

This ticket has now been closed with the status Answered.

We hope your issue or question has been addressed to your satisfaction. If not, please feel free to re-open it by clicking this link.

If you have any further issues or questions, please feel free to start a new support ticket via the button at the top of every page.

Thank you!
 
Status
Not open for further replies.

Legacy DragonByte Forum Ads

vBulletin 4.x.x
Seller
DragonByte Technologies
Release date
Last update
Total downloads
337
Customer rating
0.00 star(s) 0 ratings
Back
Top