PDA

View Full Version : ASP.NET 2.0 / XHTML-MP Examples



LaMondeA
11-20-2007, 04:44 PM
I'm a veteran ASP.NET developer that is struggling with a move to .mobi

I'm looking for a basic page that will submit a form and capture values from a textbox. The validators don't seem to recognize the div that .NET places around the viewstate, so it fails. Very frustrating because I know that div is there.

I've searched the net, and cannot find any working examples of how to get .NET working and valid. If anyone knows a good site, please let me know.

GijsZePa
11-20-2007, 08:18 PM
I'm a veteran ASP.NET developer that is struggling with a move to .mobi

I'm looking for a basic page that will submit a form and capture values from a textbox. The validators don't seem to recognize the div that .NET places around the viewstate, so it fails. Very frustrating because I know that div is there.

I've searched the net, and cannot find any working examples of how to get .NET working and valid. If anyone knows a good site, please let me know.'

Hi LamondeA

Some tips:
1)
http://msdn2.microsoft.com/en-us/library/exc57y7e.aspx

2)
Also in your web.config:



<configuration>

<system.web>
.........
..........

<xhtmlConformance mode="Strict" />

</system.web>

</configuration>


3)
If you're using a webform without a submit button (gives you troubles in ready.mobi)...just fake this:
<input type="submit" id="btnSubmit" class="hidden"/>

.hidden {visibility:hidden}

4)
If you don't need the viewstate in some pages, just use enableviewstate="false" in your page directive

Good luck with it...

Martin