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

  • Home
  • SEARCH
  • 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 7637361
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T07:55:05+00:00 2026-05-31T07:55:05+00:00

<form id=search action=/search method=get autocomplete=off> <div> <input type=button name=test_button value=test /> </div> </form> <script>

  • 0
<form id="search" action="/search" method="get" autocomplete="off">
  <div>
    <input type="button" name="test_button" value="test" />
  </div>
</form>

  <script>
    document.getElementById("test_button").value = "changed_test"
</script>

Just as the HTML code above shows, I have defined a button with name test_button and value test and changing its value with the code in the script tag.

Now I am debugging a large webpage which is using a mechanism like this using Firebug and Firefox in Linux.

I want to know how I can find the script that changes the value attribute of the <input ... />, but the web page is too large, various <script> and anonymous functions which are auto-executed made it nearly impossible to find the specific script manually.

Since I am in Linux, I cannot use any Microsoft tools to search the whole web page. I only have Firebug and Chrome. Can Firebug realize that? Does anyone have a good idea of how to find the specific <script> that changed the value?

  • 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-31T07:55:07+00:00Added an answer on May 31, 2026 at 7:55 am

    Add some code like this to the document, right after the form with the button:

    <script>
    var node = document.getElementById("test_button");
    Object.defineProperty(node, 'value', {
        set: function() { throw new Error('button value modified'); }
    });
    </script>
    

    This will throw an error when anything tries to modify the button’s value.

    error log

    Expand the error and click the last line number shown. This will take you straight to the line that set the value of the button.

    offending script line

    Here’s a demo: http://jsfiddle.net/XSJZN/

    Tested in Chrome 17.

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

Sidebar

Related Questions

I do have a search form. <form method=get id=searchform action=<?php bloginfo('siteurl');?>> <div class=search_bx1><input type=text
I have a simple form like this: <form name=serachForm method=post action=/home/search> <input type=text name=searchText
i have the following form <form action=#!/search/ method=get style=display:inline; id=hdr_q> <table cellpadding=0 cellspacing=0> <tr><td><input
Given some typical search form, I can't construct this form action when submitting a
here is my html output: <script language=javascript> function append_suggestion() { $('input[name=cn]').append($('#rand-character').val()); } </script> <form
$(document).ready(function() { $('form#search').bind(submit, function(e){ e.preventDefault(); $('#content').html(''); // Define the callback function function getGeo(jsonData) {
I have a search form with a query builder. The builder is activated by
I have a search form in an app I'm currently developing, and I would
I have a search form on each of my pages. If I use form
I have a search form and result list. The form allows the user to

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.