I’m interested in removing the Quick Save button from one of my client sites. I could just comment it out of the code, but because I’m curious about extensions, I went looking for a way to remove the button using the existing extension hooks.
Near as I can tell, there are only two extensions that have a hope of influencing the Quick Save button—“publish_form_start” which would require me to rewrite the whole publish page, and “publish_form_end,” which seemed promising.
But “publish_form_end” only lets me add additional HTML code onto the end of the form page:
if (isset($EXT->extensions['publish_form_end']))
{
$r .= $EXT->call_extension('publish_form_end', $weblog_id);
}
The variable $r is local in scope, so I can’t reach up to access and/or change any of the already generated page, I can only append to $r. This diminishes the flexibility of the form_end hook.
For a counter example, the hook “publish_form_body_props” works like this:
$DSP->body_props .= ' onLoad="set_catlink();" ';
$edata = $EXT->call_extension('publish_form_body_props');
if ($EXT->end_script === TRUE) return;
Because the body_props are stored in $DSP at the time the hook is called, they are globally accessible to the extension hook.
Anyway, if anyone can think of a hook (or other method) that can modify the publish page to remove the quick save button, please share.
Update Sept.: I did make an extension; version 1.0 was downloaded 35 times.
Update (Nov. 2, 2006): I’ve updated the extension to version 1.1., downloaded 31 times.
Update (Dec. 7, 2006): I’ve updated the extension to version 1.2. See below for details, downloaded 4 times.
Update (Dec. 8, 2006): I’ve updated the extension to version 1.2.1 Stupid bug. Downloaded 20 times.
Update (Jan. 3, 2007): I’ve updated the extension to version 1.5. Downloaded 37 times.
Update (Jan. 20, 2007): I’ve updated the extension to version 1.5.1. Downloaded 226 times.
Update (July 5, 2007): I’ve updated the extension to version 1.6. Downloaded 9 times.
Update (June 26, 2007): I’ve updated the extension to version 1.7. Downloaded 59 times.
Update (Sept 5, 2007): I’ve updated the extension to version 2.0. This adds EE 1.6 compatibility and a handful of new options. I’m taking suggestions, too.
