Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4119426
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T23:05:20+00:00 2026-05-20T23:05:20+00:00

I am having some trouble getting a function to work in internet explorer (7-8).

  • 0

I am having some trouble getting a function to work in internet explorer (7-8). My problem is that I need to hide some links until a user logs in, I would do this server side; however, suffice to say I have no way of doing this.

My approach has been to load a set of text (login/logout) that will change server side and test for the logout value. I was doing this by loading a div by id in Jquery and using the .text() when IE 7-8 both refuse to run this ie dev tools told me that “object doesn’t support this property or method” with a reference back to the line of code containing this lookup. Code posted below:

function logintest(){
        login_test= "Sign out";
        alert($('#log').text());
        login = $('#log').text();
        if(login.search(login_test) == -1){
            $('#hiddenBox').css('display','none');
        }
    };

The fun thing is that the alert runs properly and displays the right text string. Upon this failing I tried using the .attr() and got identical results. Any help would be great!

Jquery version: 1.4.4
Site: http://www.brainwellnesspro.com
IE: 7-8 on win xp

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T23:05:21+00:00Added an answer on May 20, 2026 at 11:05 pm

    Looking at your site I’d start by fixing the html to be valid, this isn’t good:

    <div id="log" name="<a href='http://www.brainwellnesspro.com/login.php' onclick=''>Sign in</a> or <a href='http://www.brainwellnesspro.com/login.php?action=create_account' onclick=''>Create an account</a>">
    <a href='http://www.brainwellnesspro.com/login.php' onclick=''>Sign in</a> or <a href='http://www.brainwellnesspro.com/login.php?action=create_account' onclick=''>Create an account</a>
    </div>
    

    and since you already have jquery you can check the current text value of the login link like this

    function logintest(){
       if($("#log a").first().text() !== "Sign out"){
         $('#hiddenBox').css('display','none');
       }
    };
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm having trouble getting some PHP code to work. Here is the function: function
Basically I am trying to show hide divs and links, but having some trouble.
I'm sure this is fairly straightforward but i'm having trouble getting it to work.
I'm having some trouble getting JSON to store some Javascript as a string value.
I'm having some trouble getting jquery to post some json data to a rest
I think I am having trouble with binary file io. If I run my
I find myself wanting to use Emacs, mostly because of org-mode, but I'm having
I'm writing xslt code which concatenates some string: <xsl:attribute name='src'> <xsl:value-of select=concat('url(&apos;', $imgSrc, '&apos;)')
I'm looking to create an associative array in JavaScript, but use constants defined as
I'm really new to OpenGL but have quite a good grasp of basic trigonometry

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.