Skip to content

Commit 02ad34e

Browse files
committed
Merge pull request #25 from CleanTalk/version3.3
Version3 3
2 parents e1b50fd + da55603 commit 02ad34e

File tree

2 files changed

+11
-8
lines changed

2 files changed

+11
-8
lines changed

antispambycleantalk.php

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
/**
44
* CleanTalk joomla plugin
55
*
6-
* @version 3.3
6+
* @version 3.4
77
* @package Cleantalk
88
* @subpackage Joomla
99
* @author CleanTalk (welcome@cleantalk.org)
@@ -22,7 +22,7 @@ class plgSystemAntispambycleantalk extends JPlugin {
2222
/**
2323
* Plugin version string for server
2424
*/
25-
const ENGINE = 'joomla-33';
25+
const ENGINE = 'joomla-34';
2626

2727
/**
2828
* Default value for hidden field ct_checkjs
@@ -324,7 +324,10 @@ public function onAfterInitialise()
324324
//print_r($_POST);
325325
//die();
326326

327-
if(isset($_GET['option'])&&$_GET['option']=='com_rsform'&&isset($_POST)&&sizeof($_POST)>0&&!$app->isAdmin() || isset($_POST['option'])&&$_POST['option']=='com_virtuemart'&&isset($_POST['task'])&&$_POST['task']=='saveUser')
327+
if(isset($_GET['option'])&&$_GET['option']=='com_rsform'&&isset($_POST)&&sizeof($_POST)>0&&!$app->isAdmin() ||
328+
isset($_POST['option'])&&$_POST['option']=='com_virtuemart'&&isset($_POST['task'])&&$_POST['task']=='saveUser' ||
329+
isset($_GET['api_controller'])
330+
)
328331
{
329332
$sender_email = '';
330333
$sender_nickname = '';
@@ -1477,23 +1480,23 @@ private function getCTConfig() {
14771480
$config['general_contact_forms_test'] = '';
14781481
$config['relevance_test'] = '';
14791482
$config['user_token'] = '';
1480-
if (class_exists('JParameter')) { //1.5
1483+
/*if (class_exists('JParameter')) { //1.5
14811484
$jparam = new JParameter($plugin->params);
14821485
$config['apikey'] = $jparam->def('apikey', '');
14831486
$config['server'] = $jparam->def('server', '');
14841487
$config['jcomments_unpublished_nofications'] = $jparam->def('jcomments_unpublished_nofications', '');
14851488
$config['general_contact_forms_test'] = $jparam->def('general_contact_forms_test', '');
14861489
$config['relevance_test'] = $jparam->def('relevance_test', '');
14871490
$config['user_token'] = $jparam->def('user_token', '');
1488-
} else { //1.6+
1491+
} else { //1.6+*/
14891492
$jreg = new JRegistry($plugin->params);
14901493
$config['apikey'] = $jreg->get('apikey', '');
14911494
$config['server'] = $jreg->get('server', '');
14921495
$config['jcomments_unpublished_nofications'] = $jreg->get('jcomments_unpublished_nofications', '');
14931496
$config['general_contact_forms_test'] = $jreg->get('general_contact_forms_test', '');
14941497
$config['relevance_test'] = $jreg->get('relevance_test', '');
14951498
$config['user_token'] = $jreg->get('user_token', '');
1496-
}
1499+
//}
14971500

14981501
return $config;
14991502
}

antispambycleantalk.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22
<extension version="2.5" type="plugin" group="system" method="upgrade" >
33
<name>Antispam by CleanTalk</name>
44
<author>CleanTalk team</author>
5-
<creationDate>09.06.2015</creationDate>
5+
<creationDate>26.08.2015</creationDate>
66
<copyright>(C) CleanTalk</copyright>
77
<license>GNU/GPLv2</license>
88
<authorEmail>welcome@cleantalk.org</authorEmail>
99
<authorUrl>cleantalk.org</authorUrl>
10-
<version>3.3</version>
10+
<version>3.4</version>
1111
<description>PLG_CLEANTALK_DESCRIPTION</description>
1212
<files>
1313
<filename plugin="antispambycleantalk">antispambycleantalk.php</filename>

0 commit comments

Comments
 (0)