Remove JavaScript __doPostBack function

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Waldy

    #1

    Remove JavaScript __doPostBack function

    Hi there,
    I have a customer requirement to provide a web application
    without JavaScript. A function is being written to the HTML output on some
    pages. The function is called __doPostBack. How do I get rid of it. There
    is no call to the function in the rest of the page, so why is it being
    written to the client?


  • darrel

    #2
    Re: Remove JavaScript __doPostBack function

    I have a customer requirement to provide a web application
    without JavaScript. A function is being written to the HTML output on
    some pages. The function is called __doPostBack. How do I get rid of it.
    There is no call to the function in the rest of the page, so why is it
    being written to the client?
    Have a link to the page to show us?

    I believe that function is added by the .net framework. If it's not being
    used by any of your controls (ie, you don't have AUTOPOSTBACK set to to
    TRUE) then it won't necessarily hurt to have it there.

    -Darrel


    Comment

    • =?Utf-8?B?YnJ1Y2UgYmFya2Vy?=

      #3
      RE: Remove JavaScript __doPostBack function

      _dopostback is rendered in three cases:

      1) the page has a postback control that can only postback via javascript.
      the only asp controls that don't need javascript to postback are the
      asp:button and asp:imagebutton .

      2) the page uses clientside validation. Set CauesValidation to false to turn
      this off.

      3) a command argument is specified for postback.

      -- bruce (sqlwork.com)


      "Waldy" wrote:
      Hi there,
      I have a customer requirement to provide a web application
      without JavaScript. A function is being written to the HTML output on some
      pages. The function is called __doPostBack. How do I get rid of it. There
      is no call to the function in the rest of the page, so why is it being
      written to the client?
      >
      >
      >

      Comment

      • Waldy

        #4
        Re: Remove JavaScript __doPostBack function

        "bruce barker" <brucebarker@di scussions.micro soft.comwrote in message
        news:69E6FB4C-5C38-42CE-88F3-106A15080ABE@mi crosoft.com...
        _dopostback is rendered in three cases:
        >
        Thanks Bruce,
        but surely in each of those cases, there would be a
        call to the function somewhere in the HTML output?


        Comment

        • darrel

          #5
          Re: Remove JavaScript __doPostBack function

          but surely in each of those cases, there would be a
          call to the function somewhere in the HTML output?
          I'm looking at some asp.net 1.1 pages I've built purposely without any
          javascript and I don't have that function there. So I would imagine you
          might have a control you've missed that requires it. Can you post a link to
          the page in question?

          -Darrel


          Comment

          Working...