New function to reset vars
|Reported by:||Sewar||Owned by:||Sewar|
Most files in wordpress/wp-admin/*.php start with 15-lines-code to reset vars in an array. So, just move this code to new function and put it in admin-functions.php. This is better than write same code in +10 files.
In the patch i used $_REQUEST because it contain both of $_POST and $_GET, this will offer some lines. Also, the var unseted according to #2595.
Also, isn't "foreach" better than "for"? or at least more cleaner?
Change History (9)
- Keywords bg|has-patch bg|needs-testing added
- Owner changed from anonymous to Sewar