Created
January 23, 2009 22:37
-
-
Save minichate/51239 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From 3a7ea21f6a899b2c67db9f138e6284a37736e0ff Mon Sep 17 00:00:00 2001 | |
From: Christopher Troup <chris@norex.ca> | |
Date: Fri, 23 Jan 2009 16:31:32 -0500 | |
Subject: [PATCH] fix for content page urls being possibly invalid [fix: 34] | |
--- | |
modules/Content/include/ContentPage.php | 5 +++++ | |
1 files changed, 5 insertions(+), 0 deletions(-) | |
diff --git a/modules/Content/include/ContentPage.php b/modules/Content/include/ContentPage.php | |
index 9b57c6e..d472aca 100644 | |
--- a/modules/Content/include/ContentPage.php | |
+++ b/modules/Content/include/ContentPage.php | |
@@ -53,6 +53,11 @@ class ContentPage extends DBRow { | |
} | |
} | |
+ public function getAddEditFormSaveHook($form) { | |
+ include_once(SITE_ROOT . '/core/plugins/modifier.urlify.php'); | |
+ $this->set('url_key', smarty_modifier_urlify($this->get('url_key'))); | |
+ } | |
+ | |
function checkForHomeName($elVal){return (!is_null($elVal) && ucfirst($elVal) != SiteConfig::get('Content::defaultPage'));} | |
public static function checkForHome(&$n){ | |
-- | |
1.6.1.265.g9a013+GitX |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment