rewriting to fit the new way to use hooks

Conflicts:
	htdocs/core/class/html.formfile.class.php