2013-03-22, 06:55 PM
2013-03-22, 07:03 PM
Weird it's changed now, it was:
When I looked before. xD
But odd it's not working.
<div id="register-section" style>
Register here
</div>
When I looked before. xD
But odd it's not working.
2013-03-22, 07:04 PM
(2013-03-22, 05:41 PM)Eric J. Wrote: [ -> ]Try this out brad:
<script type="text/javascript"> jQuery.noConflict(); jQuery(function($) { $('.register-link').click(function () { $('#register-section').show(); $('#login-section').hide(); }); $('.login-link').click(function () { $('#login-section').show(); $('#register-section').hide(); }); }); </script>
I just added in a page load function and passed in $. Also you have style just sitting there in your #register-section tag. xD
This should work fine brad. At least if you didn't mean hide a div and show another div at the same time (in parallel). Then you should use callbacks.
2013-03-22, 07:13 PM
I think my message in the OP makes pretty clear that's exactly what I'm trying to accomplish.
Also, maybe it should work, but it doesn't.
Also, maybe it should work, but it doesn't.
2013-03-22, 07:15 PM
<script type="text/javascript">
jQuery.noConflict();
jQuery(function($) {
$('.register-link').click(function (event) {
event.preventDefault();
$('#register-section').show();
$('#login-section').hide();
});
$('.login-link').click(function (event) {
event.preventDefault();
$('#login-section').show();
$('#register-section').hide();
});
});
</script>
Sorry, this is the correct code. You are trying to trigger a click event on a HTML element quite particular ("a"). Preventing the default behavior should be enough to make it work.
2013-03-22, 07:19 PM
Also does not work
That said, I don't have to use a element. I can use any element.
That said, I don't have to use a element. I can use any element.
2013-03-22, 07:28 PM
Fixing these would probably help to avoid random errors as well. xD
http://i2.minus.com/izOpmOg8x2nUH.png
http://i2.minus.com/izOpmOg8x2nUH.png
2013-03-22, 07:30 PM
Analyzing your page with Chrome Console it seems to be an error within a previous script in the same page, which causes all the following code to be ignored and therefore not executed.
There's no overlay(); method. Simply remove that line to correctly execute the following code, or place your script before that one.
Ninjed by Eric
jQuery.noConflict();
jQuery(document).ready(function($){
jQuery("a[rel=logbox]").overlay();
});
There's no overlay(); method. Simply remove that line to correctly execute the following code, or place your script before that one.
Ninjed by Eric
2013-03-22, 08:18 PM
This was given to me by someone else ...
Thank you guys, I'll try some more later tonight.
Thank you guys, I'll try some more later tonight.
2013-03-22, 08:35 PM
(2013-03-22, 08:18 PM)brad-t Wrote: [ -> ]This was given to me by someone else ...
Thank you guys, I'll try some more later tonight.
Lies! It was in your headerinclude but had an error, which I fixed because I was guessing that was the overlay plugin you were using, but I later found out it wasn't and fixed that problem.