During a page's "dormant" state, I can inspect the values of any tag by entering its id in Chrome Dev Tools' console tab, like so, e.g. for a tag with the name "BeginDate":
0) Enter "BeginDate" in the console tab 1) Mash the key
...and I see the whole shebang:
<input alt="date-us" data-val="true" data-val-regex="End Date must be in the format &quot;m/d/yyyy&quot;" data-val-regex-pattern="[0-9]*[0-9]/[0-9]*[0-9]/[0-9]{4}" data-val-required="End Date must be in the format &quot;m/d/yyyy&quot;" id="EndDate" name="EndDate" style="width: 164px;" type="text" value="5/14/2013" class="hasDatepicker">
So it shows the value, which is the part I'm interested in, is today's date.
What I want to inspect, though, is just what is being passed/posted when the form's Submit button is pressed; I believe this would be, in asp.net, the contents of the Request object, but how can I see these vals using Chrome Dev Tools?
I right-clicked in the console and selected "Log XMLHTTPRequests" and "Preserve log upon navigation" but...are they logged? If so, where are they? I see nothing in the Console tab...
Thanks to David Ziemann, here's what I see:
One of the easiest ways to inspect a specific web element in Chrome is to simply right-click on that particular element and select the Inspect option. Clicking on the Inspect option from the right-click menu will directly open the Developer tools including the editor, Console, Sources, and other tools.
Once you select the HTTP request, Chrome will reveal more information on that request. Under the 'Headers' tab, you will be able to find the 'Form Data' section that contains the data that was submitted as part of that request.
The Sources panel provides the ability to watch variables within your application. This is located in the watch section of the debugger sidebar. By taking advantage of this functionality you will not need repeatedly log objects to the console.
The Network tab will show you any network communication. Within that you can select the request and view the headers which should include the form data.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With