Support > cpg1.5 plugins
Plugin hook suggestions for cpg1.5.x
Αndré:
Both suggestions can already be done without new plugin hooks.
--- Quote from: paperlife on May 10, 2012, 10:33:33 pm ---upon upload, have uploader remember last location of last image
--- End quote ---
Check for the 'album' parameter and if it isn't submitted, get the latest upload from the database (there's also stored the album) and redirect the user accordingly.
--- Quote from: paperlife on May 10, 2012, 10:33:33 pm ---remove time limit on selecting images to upload
--- End quote ---
That's related to the form token config setting.
Veronica:
I have now been working on this plugin and want to release the plugin version 1.0.
In the install/uninstall functions I have code which will add/delete this hook until an official hook is released.
--- Quote from: Veronica on September 19, 2012, 11:55:18 pm ---I'm currently working on an Youtube URL user upload plugin which will work with this plugin Remote videos for cpg1.5.
I have added a third upload form in addition to swf and single file uploads.
Also I have made a conversion tool for the old Youtube hack for cpg1.4 by Nibbler so Coppermine sites still on cpg1.4 can upgrade and keep their Youtube links.
To make this plugin installable by anybody I want a new hook in db_input.php to process "uploads" which are not file uploads.
My suggestion for a new hook is like this in the last lines of db_input.php:
--- Quote ---default:
if(CPGPluginAPI::action('upload_process',$event)) break;
// Unknown event
if ($CONFIG['log_mode'] != 0) {
log_write('Denied privileged access to db_input.php (unknown event) for user '.$USER_DATA['user_name'].' at ' . $hdr_ip, CPG_SECURITY_LOG);
}
cpg_die(CRITICAL_ERROR, $lang_errors['param_missing'], __FILE__, __LINE__);
}
?>
--- End quote ---
--- End quote ---
Αndré:
Why do you need a plugin hook in db_input.php? Isn't it possible to submit the third upload form to another file (which will reside in your plugin folder)? I've currently no time to look into this in detail.
Veronica:
OK I will do input to another plugin script without going via db_input.php
Veronica:
--- Quote from: Αndré on September 27, 2012, 11:36:27 am ---Why do you need a plugin hook in db_input.php? Isn't it possible to submit the third upload form to another file (which will reside in your plugin folder)? I've currently no time to look into this in detail.
--- End quote ---
I made the correct set_include_path to get all script includes to execute with form processing directed to the plugin folder.
Using a submit destination to a script in the plugin folder will make init.inc.php fail in testing
--- Quote ---if (file_exists('include/config.inc.php'))
--- End quote ---
giving me an attempt to reload install.php from the plugin folder.
Now I will go back to my first setup with a hook in db_input.php
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version