https://www.mediawiki.org/w/index.php?title=Special%3ASearch&profile=advanced&search=Foo&fulltext=Search&debug=true

TypeError: this.form is null mediawiki.special.search.js:53

		// Change the header search links to what user entered (line 34)
		$headerLinks = $( '.search-types a' );
		$( '#searchText, #powerSearchText' ).change( function () {
			var searchterm = $( this ).val();
			$headerLinks.each( function () {
				var parts = $( this ).attr( 'href' ).split( 'search=' ),
					lastpart = '',
					prefix = 'search=';
				if ( parts.length > 1 && parts[1].indexOf( '&' ) !== -1 ) {
					lastpart = parts[1].slice( parts[1].indexOf( '&' ) );
				} else {
					prefix = '&search=';
				}
				this.href = parts[0] + prefix + encodeURIComponent( searchterm ) + lastpart;
			} );
		} ).trigger( 'change' );

		// When saving settings, use the proper request method (POST instead of GET).
		$( '#mw-search-powersearch-remember' ).change( function () {
			this.form.method = this.checked ? 'post' : 'get';
		} ).trigger( 'change' );

When I view source of the page:
lines=10
    mw.user.options.set( {
        "ccmeonemails": "1",
        "date": "mdy",
        "editsectiononrightclick": "1",
        "enotifwatchlistpages": "1",
        "extendwatchlist": "1",
        "gender": "male",
        "imagesize": "3",
        "math": "6",
        "previewonfirst": "1",
        "rcdays": "30",
        "rclimit": "500",
        "showhiddencats": "1",
        "stubthreshold": "100",
        "thumbsize": "6",
        "uselivepreview": "1",
        "usenewrc": "1",
        "watchlistdays": "30",
        "wllimit": "1000",
        "lqtnotifytalk": "1",
        "visualeditor-betatempdisable": "1",
        "translate-editlangs": "en",
        "echo-subscriptions-email-edit-user-talk": 1,
        "echo-subscriptions-web-article-linked": "1",
        "echo-subscriptions-email-mention": "1",
        "uls-preferences": "{\"ime\":{\"language\":\"en\",\"previousLanguages\":[\"en\"],\"previousInputMethods\":[],\"imes\":{\"en\":\"system\"}}}",
        "searchNs1": "1",
        "searchNs2": "1",
        "searchNs3": "1",
        "searchNs4": "1",
        "searchNs5": "1",
        "searchNs6": "1",
        "searchNs7": "1",
        "searchNs8": "1",
        "searchNs9": "1",
        "searchNs10": "1",
        "searchNs11": "1",
        "searchNs13": "1",
        "searchNs90": "1",
        "searchNs91": "1",
        "searchNs101": "1",
        "searchNs103": "1",
        "betafeatures-vector-compact-personal-bar": "0",
        "gadget-DotsSyntaxHighlighter": "1",
        "gadget-HotCat": "1",
        "gadget-Navigation_popups": "1",
        "gadget-TabOverride": "1",
        "gadget-UTCLiveClock": "1",
        "gadget-ajaxrecentchanges": "1",
        "gadget-contribsrange": "1",
        "gadget-externalsearch": "1",
        "gadget-oldeditor": "1",
        "gadget-templatedata": "1",
        "popups": "0",
        "timecorrection": "ZoneInfo|-300|America/New_York",
        "uls-compact-links": "0",
        "watchlisttoken": "/* (redacted) */"
    } );
...

and
    mw.loader.load(["mediawiki.page.startup","mediawiki.legacy.wikibits","mediawiki.legacy.ajax","ext.gadget.site","ext.centralauth.centralautologin.clearcookie","skins.vector.compactPersonalBar.defaultTracking","ext.visualEditor.viewPageTarget.init","ext.uls.init","ext.uls.interface","ext.centralNotice.bannerController","skins.vector.js"]);