Go Back   CodingForums.com > :: Client side development > JavaScript programming > JavaScript frameworks

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 09-16-2012, 05:59 PM   PM User | #1
nolvorite
Regular Coder

 
nolvorite's Avatar
 
Join Date: Dec 2006
Posts: 170
Thanks: 7
Thanked 0 Times in 0 Posts
nolvorite is an unknown quantity at this point
this is strange... :/

For some reason in this test message board http://vanishingpoint.b1.jcink.com/index.php (not advertising lol its just a place im currently coding my skin) none of the things I had changed in the syntax with jQuery were working (like the entire jQuery code didnt work) when i'm logged in.

In order to see the difference you have to register an account.

here's the entire code
Code:
<script type="text/javascript">
$("#userlinks td:contains('Welcome Guest')").wrapInner("<div id='lag1'></div>").html($("#userlinks td:contains('Welcome Guest')").html().replace(/Guest/, '<span class="guestbx">Guest</span>'));
$("div#lag1").insertBefore("#logostrip");
$("#navstrip").html($("#navstrip").html().replace(/&nbsp;/, ''));
$("#menux a:last").attr("id","sadfix");
$("div#navstrip a:first-child").attr("id","original");
$("#menux a:last").hover(function(){$("div#stupidpad").css("background-image","url('http://vanishingpoint.b1.jcink.com/uploads/vanishingpoint//23125i.png')")},function(){$("div#stupidpad").css("background-image","url('http://vanishingpoint.b1.jcink.com/uploads/vanishingpoint//23125g.png')");});
</script>
(that looks like its terribly coded lol)

I don't think doctypes/errors in html is the issue here, but oh well
I need help guize. thanks
__________________
http://stereo.wired.x10.mx/cloud/The...loudmixsig.png
the cloud soup. opened July 15 -- like on facebok /////////////// like on twiter
nolvorite is offline   Reply With Quote
Old 09-16-2012, 06:11 PM   PM User | #2
xelawho
Senior Coder

 
xelawho's Avatar
 
Join Date: Nov 2010
Posts: 2,437
Thanks: 52
Thanked 454 Times in 452 Posts
xelawho will become famous soon enoughxelawho will become famous soon enough
Quote:
Originally Posted by nolvorite View Post
In order to see the difference you have to register an account.
well, that's not going to happen (not me, anyway)

what might get you more help is if you set up a guest account, post the login details here and then delete it once your problem is solved.
xelawho is offline   Reply With Quote
Old 09-16-2012, 06:19 PM   PM User | #3
nolvorite
Regular Coder

 
nolvorite's Avatar
 
Join Date: Dec 2006
Posts: 170
Thanks: 7
Thanked 0 Times in 0 Posts
nolvorite is an unknown quantity at this point
username: dundun
password: nononono1

there

thanks for helping
__________________
http://stereo.wired.x10.mx/cloud/The...loudmixsig.png
the cloud soup. opened July 15 -- like on facebok /////////////// like on twiter
nolvorite is offline   Reply With Quote
Old 09-16-2012, 06:56 PM   PM User | #4
xelawho
Senior Coder

 
xelawho's Avatar
 
Join Date: Nov 2010
Posts: 2,437
Thanks: 52
Thanked 454 Times in 452 Posts
xelawho will become famous soon enoughxelawho will become famous soon enough
without really understanding what you are trying to do, I can see (from the error console...) that your code is failing when you have a registered user because that td does not contain the phrase "Welcome Guest".

if you want to run a simple test to see if it is there, wrap the whole code in an if statement...
Code:
<script type="text/javascript">
if($("#userlinks td:contains('Welcome Guest')").length>0){
$("#userlinks td:contains('Welcome Guest')").wrapInner("<div id='lag1'></div>").html($("#userlinks td:contains('Welcome Guest')").html().replace(/Guest/, '<span class="guestbx">Guest</span>'));
$("div#lag1").insertBefore("#logostrip");
$("#navstrip").html($("#navstrip").html().replace(/&nbsp;/, ''));
$("#menux a:last").attr("id","sadfix");
$("div#navstrip a:first-child").attr("id","original");
$("#menux a:last").hover(function(){$("div#stupidpad").css("background-image","url('http://vanishingpoint.b1.jcink.com/uploads/vanishingpoint//23125i.png')")},function(){$("div#stupidpad").css("background-image","url('http://vanishingpoint.b1.jcink.com/uploads/vanishingpoint//23125g.png')");});
}
</script>
xelawho is offline   Reply With Quote
Old 09-16-2012, 07:21 PM   PM User | #5
nolvorite
Regular Coder

 
nolvorite's Avatar
 
Join Date: Dec 2006
Posts: 170
Thanks: 7
Thanked 0 Times in 0 Posts
nolvorite is an unknown quantity at this point
I was having a problem having the code work when I was logged in
thats what I was tryna solve

anyways I just moved the right bracket before the call for #lag1 and it works fine now
__________________
http://stereo.wired.x10.mx/cloud/The...loudmixsig.png
the cloud soup. opened July 15 -- like on facebok /////////////// like on twiter

Last edited by nolvorite; 09-16-2012 at 07:29 PM..
nolvorite is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 04:50 PM.


Advertisement
Log in to turn off these ads.