summaryrefslogtreecommitdiff
path: root/modules/akismet
diff options
context:
space:
mode:
Diffstat (limited to 'modules/akismet')
-rw-r--r--modules/akismet/helpers/akismet.php2
-rw-r--r--modules/akismet/tests/Akismet_Helper_Test.php2
-rw-r--r--modules/akismet/views/admin_akismet.html.php17
-rw-r--r--modules/akismet/views/admin_akismet_stats.html.php6
4 files changed, 14 insertions, 13 deletions
diff --git a/modules/akismet/helpers/akismet.php b/modules/akismet/helpers/akismet.php
index acd5cb3e..43549ffa 100644
--- a/modules/akismet/helpers/akismet.php
+++ b/modules/akismet/helpers/akismet.php
@@ -21,7 +21,7 @@ class akismet_Core {
public static $test_mode = TEST_MODE;
static function get_configure_form() {
- $form = new Forge("admin/akismet", "", "post", array("id" => "gConfigureAkismetForm"));
+ $form = new Forge("admin/akismet", "", "post", array("id" => "g-configure-akismet-form"));
$group = $form->group("configure_akismet")->label(t("Configure Akismet"));
$group->input("api_key")->label(t("API Key"))->value(module::get_var("akismet", "api_key"));
$group->api_key->error_messages("invalid", t("The API key you provided is invalid."));
diff --git a/modules/akismet/tests/Akismet_Helper_Test.php b/modules/akismet/tests/Akismet_Helper_Test.php
index d001d3ad..745b455c 100644
--- a/modules/akismet/tests/Akismet_Helper_Test.php
+++ b/modules/akismet/tests/Akismet_Helper_Test.php
@@ -26,7 +26,7 @@ class Akismet_Helper_Test extends Unit_Test_Case {
$root = ORM::factory("item", 1);
$this->_comment = comment::create(
- $root, user::guest(), "This is a comment",
+ $root, identity::guest(), "This is a comment",
"John Doe", "john@gallery2.org", "http://gallery2.org");
foreach ($this->_comment->list_fields("comments") as $name => $field) {
if (strpos($name, "server_") === 0) {
diff --git a/modules/akismet/views/admin_akismet.html.php b/modules/akismet/views/admin_akismet.html.php
index 009d8810..399053d8 100644
--- a/modules/akismet/views/admin_akismet.html.php
+++ b/modules/akismet/views/admin_akismet.html.php
@@ -1,17 +1,18 @@
<?php defined("SYSPATH") or die("No direct script access.") ?>
-<div id="gAdminAkismet">
- <h1> <?= t("Akismet Spam Filtering") ?> </h1>
+<div id="g-admin-akismet" class="g-block">
+ <h1> <?= t("Akismet spam filtering") ?> </h1>
<p>
<?= t("Akismet is a free, automated spam filtering service. In order to use it, you need to sign up for a <a href=\"%api_key_url\">Wordpress.com API Key</a>, which is also free. Your comments will be automatically relayed to <a href=\"%akismet_url\">Akismet.com</a> where they'll be scanned for spam. Spam messages will be flagged accordingly and hidden from your vistors until you approve or delete them.",
array("api_key_url" => "http://wordpress.com/api-keys",
"akismet_url" => "http://akismet.com")) ?>
</p>
+ <div class="g-block-content">
+ <? if ($valid_key): ?>
+ <div class="g-module-status g-success">
+ <?= t("Your API key is valid. Your comments will be filtered!") ?>
+ </div>
+ <? endif ?>
- <? if ($valid_key): ?>
- <div class="gModuleStatus gSuccess">
- <?= t("Your API Key is valid. Your comments will be filtered!") ?>
+ <?= $form ?>
</div>
- <? endif ?>
-
- <?= $form ?>
</div>
diff --git a/modules/akismet/views/admin_akismet_stats.html.php b/modules/akismet/views/admin_akismet_stats.html.php
index 41bad15b..32908ba0 100644
--- a/modules/akismet/views/admin_akismet_stats.html.php
+++ b/modules/akismet/views/admin_akismet_stats.html.php
@@ -1,11 +1,11 @@
<?php defined("SYSPATH") or die("No direct script access.") ?>
<script type="text/javscript">
$(document).ready(function() {
- $("#gAkismetExternalStats").css("height", "600");
+ $("#g-akismet-external-stats").css("height", "600");
});
</script>
-<div id="gAkismetStats">
- <iframe id="gAkismetExternalStats" width="100%" height="500" frameborder="0"
+<div id="g-akismet-stats">
+ <iframe id="g-akismet-external-stats" width="100%" height="500" frameborder="0"
src="http://<?= $api_key ?>.web.akismet.com/1.0/user-stats.php?blog=<?= urlencode($blog_url) ?>">
</iframe>
</div>