I was trying to follow along in the latest 1.9.* code for jQuery - looking for the area where it handles parsing the data parameter from $.get (get's 2nd argument). I'm getting lost somewhere. Where does this get turned into a URL with the correctly encoded parameters?
问问题
237 次
1 回答
1
$.get()
只是一个镜头$.ajax()
。你在那里找到
// Convert data if not already a string
if ( s.data && s.processData && typeof s.data !== "string" ) {
s.data = jQuery.param( s.data, s.traditional );
}
并在jQuery.param
:
s[ s.length ] = encodeURIComponent( key ) + "=" + encodeURIComponent( value );
于 2013-07-08T18:57:02.417 回答