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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T01:27:32+00:00 2026-05-27T01:27:32+00:00

I have this code <html> <head> <script type=text/javascript src=my-search.js></script> </head> <body onLoad=my_Init();> <div> <form

  • 0

I have this code

<html>
<head>
<script type="text/javascript" src="my-search.js"></script>
</head>
<body onLoad="my_Init();">
<div>
<form name="id_msearchform" onsubmit="my_EventHandler_Action(); return false;">
  <input type="text" name="id_searchphrase" value="example"></input>
  <br><br>
  <input type="submit" name="id_searchsubmit" value="Search"></input>
</form>
<br><br>
<div id="id_searchresults">No search done...</div>
</div>
</body>
</html>

I don’t want the browser to request a new URL. That is why “onsubmit” has “return false;”. This code works in Internet Explorer, but Firefox generates a new request. Any ideas what I am doing wrong?

FireBug changes between not wanting to acknowledge there is Javascript reference and showing the Javascript file without any errors… I will update this when i have more to add. I will try various thingsm e.g. try upload it to the net and see if FireFox behaves differently when not running JS on local disk.

  • 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-27T01:27:32+00:00Added an answer on May 27, 2026 at 1:27 am

    Are you sure that you haven’t got any errors?

    I try with a simple html:

    <html>
    <head>
    <script type="text/javascript" src="my-search.js"></script>
    </head>
    <body onLoad="my_Init();">
    <div>
    <form name="id_msearchform" onsubmit="my_EventHandler_Action(); return false;">
      <input type="text" name="id_searchphrase" value="example"></input>
      <br><br>
      <input type="submit" name="id_searchsubmit" value="Search"></input>
    </form>
    <br><br>
    <div id="id_searchresults">No search done...</div>
    </div>
    </body>
    </html>
    

    And a simple javascript called my-search.js in the same path of my html with the next code:

    var my_Init = function(){
        alert('Hello Onload');
    }
    var my_EventHandler_Action = function(){
        alert('Hello OnSubmit');
    }
    

    And it works fine.

    Can you show a live demo (with dropbox or something)?

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

Sidebar

Related Questions

OK i have this code HTML: <html> <head> <script type=text/javascript src=http://code.jquery.com/jquery-1.7.1.min.js> </script> <script type=text/javascript>
I have this html code <html> <head> <title>JQuery Problem 2</title> <script type=text/javascript src=jquery-1.4.min.js></script> <script
Ok, I have this code: <html> <head> <script type=text/javascript src=http://code.jquery.com/jquery-1.7.1.min.js></script> <script type=text/javascript> function get()
I have this HTML code for radios: <input type='radio' name='a_27' value='Yes' id='a_27_0' /> <input
I have this HTML code: <div class='com_box'> <div class='com_box_c'> <div class='com_box_info'> <a id='quote'>quote</a> </div>
I have this HTML code: <div id=main> <div id=dv_7>...</div> <div id=dv_1>...</div> <div id=dv_8>...</div> <div
I have this HTML code which simulates a dropdown multi-checkbox <div> <div class=select> <span>Select
I have this html code: <div class=action> some_text <a class=delete_action name=q1>some</a> </div> <div class=action>
I have this HTML code multiple times one after the other: <li> <img src=path/to/my/picture.jpg
I have this code: <body onLoad=subcatSelection();> The function is inside a .js file which

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.