This is a newbie question (I’m sure it is). I have tried for the first time in a little ASP.NET web application I am working on what happens if I disable Javascript in a browser (I’m testing mainly with Firefox).
Result: My application is completely broken, although I didn’t ever write any single line of Javascript.
For instance: I have a link button on a page from a LoginStatus control. Looking at the generated HTML code in my browser I see this:
<a id="ctl00_ctl00_LoginStatus" href="javascript:__doPostBack('ctl00$ctl00$LoginStatus$ctl02','')">Login</a>
Similar with some link buttons in a ListView control which allow to sort the list by certain data fields: The href of the generated anchor tag contains this: javascript:WebForm_DoPostBackWithOptions(...).
So clicking on “Login” or trying to sort does not work without having Javascript enabled.
Does this mean: With disabled Javascript in the browser ASP.NET applications won’t work properly? Or what do I have to do to get the application working with disabled Javascript?
Thanks for your feedback!
Some stuff will work, some won’t (see here). This is not to say you can’t use ASP.NET without Javascript, you’ll just have to avoid the below mentioned controls (and I’m sure a plethora of 3rd party controls as well).