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 902337
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T15:42:04+00:00 2026-05-15T15:42:04+00:00

I dont know how to explain this, so ill do the best that I

  • 0

I dont know how to explain this, so ill do the best that I can.

I have a page that has some simple javascript on it:

<script language="javascript" type="text/javascript">

    function clearIt(txtbox, initVal) {
        alert('f');
        if (txtbox.value == initVal) {
            txtbox.value = '';
        }
    }

    function fillIt(txtbox, initVal) {
        if (txtbox.value == '') {
            txtbox.value = initVal;
        }
    }


</script>

The above code works fine, until I add:

<script src="Scripts/jquery-1.4.2.js" type="text/javascript" />

If its ABOVE the previous script block, CSS doesnt load.

If its BELOW the previous script block, my clearIt\fillIt functions dont work. Any idea’s why referring to this script can cause my other stuff to bomb?

  • 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-15T15:42:05+00:00Added an answer on May 15, 2026 at 3:42 pm

    Try this instead –

     <script src="Scripts/jquery-1.4.2.js" type="text/javascript"></script>
    

    Also, with the jQuery version you are using, you should have all of your CSS referenced first (before javascript).

    This is from the jQuery Enlightenment book –

    As of jQuery 1.3, the library no longer guarantees that all CSS files are loaded before it fires the
    custom ready() event. Because of this change in jQuery 1.3, you should always include all CSS files
    before any jQuery code. This will ensure that the browser has parsed the CSS before it moves on to
    the JavaScript included later in the HTML document. Of course, images that are referenced via CSS
    may or may not be downloaded as the browser parses the JavaScript.

    Previously on Stackoverflow – Why don’t self-closing script tags work?

    Why don't self-closing script tags work?

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I don't know how to explain this correctly but just some sample for you
i don't know good title but heres the explain i have this link <a
Alright, i dont know how to explain it well.. but i have a switch
I dont really know how to explain exactly what function i need but ill
I dont know if this is possible. In SSIS Derived column transformation, can you
I don't know how to explain this exactly, but I'll have a go anyway.
I just don't know how to explain this clearly. So I create a simple
I'll try to explain the best I can, please let me know if you
I'm sure I've worded this question wrong, but I don't know how to explain
It's probably a long-shot that anyone can answer this without seeing all the source

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.