|
|
|
MyBlog Integration 1 Year, 3 Months ago
|
|
To integrate with MyBlog, go to:
/yourjoomladirectory/components/com_myblog/task and open write.phpOn line 256, it should display:| Code: : | if(isset($_POST['closeme']) && $_POST['closeme'] == '1'){
|
add the following directly underneath (configure the number of points and entry to your liking):
| Code: : | global $mainframe,$my;
require_once( $mainframe->getCfg('absolute_path') . '/components/com_karma/karma.class.php' );
$points = CLASS_karma::getConfig("Custom6");
CLASS_karma::addPoints($my->id, 8, "Blog Entry");
|
and the result should look like:
| Code: : | // If everything is ok, close th thickbox if needed
if(isset($_POST['closeme']) && $_POST['closeme'] == '1'){
global $mainframe,$my;
require_once( $mainframe->getCfg('absolute_path') . '/components/com_karma/karma.class.php' );
$points = CLASS_karma::getConfig("Custom6");
CLASS_karma::addPoints($my->id, 8, "Blog Entry");
// somehow, the parent_url might contain &task;=adminhome etc..
// and that would fail the input filter
//$_POST['parent_url'] = str_replace(';=' , '=', $_POST['parent_url']);
//$closeme = 'parent.window.location = \''.$_POST['parent_url'].'\';';
//$tpl->set('closeme', $closeme);
$onload = 'parent.azrulWindowSaveClose();';
} else {
$onload = 'parent.azrulWindowSave('.$id.');';
}
$tpl->set('onload', $onload);
} else {
$message = 'Save error';
|
This is for MyBlog version 1.2 version 236.
|
|