[geeklog-cvs] geeklog: Hide meta tag entry fields from Topic editor when meta ...

geeklog-cvs at lists.geeklog.net geeklog-cvs at lists.geeklog.net
Tue Dec 1 03:51:03 EST 2009


changeset 7509:1d014c213404
url:  http://project.geeklog.net/cgi-bin/hgwebdir.cgi/geeklog/rev/1d014c213404
user: Dirk Haun <dirk at haun-online.de>
date: Mon Nov 30 11:56:03 2009 +0100
description:
Hide meta tag entry fields from Topic editor when meta tag support is disabled

diffstat:

 public_html/admin/topic.php                                   |  5 +++++
 public_html/docs/english/theme.html                           |  4 ++++
 public_html/docs/history                                      |  2 ++
 public_html/layout/professional/admin/topic/topiceditor.thtml |  4 ++--
 4 files changed, 13 insertions(+), 2 deletions(-)

diffs (58 lines):

diff -r 930d9df2ff7e -r 1d014c213404 public_html/admin/topic.php
--- a/public_html/admin/topic.php	Mon Nov 30 11:37:02 2009 +0100
+++ b/public_html/admin/topic.php	Mon Nov 30 11:56:03 2009 +0100
@@ -203,6 +203,11 @@
     if (! empty($A['meta_keywords'])) {
         $topic_templates->set_var('meta_keywords', $A['meta_keywords']);
     }
+    if ($_CONF['meta_tags'] > 0) {
+        $topic_templates->set_var('hide_meta', '');
+    } else {
+        $topic_templates->set_var('hide_meta', ' style="display:none;"');
+    }
 
     $topic_templates->set_var ('lang_defaulttopic', $LANG27[22]);
     $topic_templates->set_var ('lang_defaulttext', $LANG27[23]);
diff -r 930d9df2ff7e -r 1d014c213404 public_html/docs/english/theme.html
--- a/public_html/docs/english/theme.html	Mon Nov 30 11:37:02 2009 +0100
+++ b/public_html/docs/english/theme.html	Mon Nov 30 11:56:03 2009 +0100
@@ -198,6 +198,10 @@
 <h2><a name="changes">Theme changes in Geeklog 1.6.2</a></h2>
 
 <ul>
+<li>New variable <code>{hide_meta}</code> in the Topic editor template,
+    <tt>admin/topic/topiceditor.thtml</tt>, to hide the text entry fields for
+    the meta description and meta keywords when meta tag support is
+    disabled.</li>
 <li>In <tt>admin/config/config_element.thtml</tt>, in the section for the
     <code>select-element</code>, <code>{hide_row}</code> was added for the
     table row and a <code>{delete}</code> option was added after the
diff -r 930d9df2ff7e -r 1d014c213404 public_html/docs/history
--- a/public_html/docs/history	Mon Nov 30 11:37:02 2009 +0100
+++ b/public_html/docs/history	Mon Nov 30 11:56:03 2009 +0100
@@ -3,6 +3,8 @@
 ??? ??, 20?? (1.6.2)
 ------------
 
+- Hide meta tag entry fields from Topic editor when meta tag support is
+  disabled [Dirk]
 - Fixed topic selection for the Daily Digest (bug #0001041, patch provided by
   Ben)
 - Changed the 'menu_elements' and 'notification' config options to dropdowns
diff -r 930d9df2ff7e -r 1d014c213404 public_html/layout/professional/admin/topic/topiceditor.thtml
--- a/public_html/layout/professional/admin/topic/topiceditor.thtml	Mon Nov 30 11:37:02 2009 +0100
+++ b/public_html/layout/professional/admin/topic/topiceditor.thtml	Mon Nov 30 11:56:03 2009 +0100
@@ -24,11 +24,11 @@
                                         <td class="alignright">{lang_uploadimage}:</td>
                                         <td><input type="file" name="newicon"{xhtml}> ({lang_maxsize} {icon_dimensions})</td>
                                     </tr>
-                                    <tr>
+                                    <tr{hide_meta}>
                                         <td valign="top" align="right">{lang_metadescription}:</td>
                                         <td><textarea name="meta_description" style="width:100%" rows="2">{meta_description}</textarea></td>
                                     </tr>
-                                    <tr>
+                                    <tr{hide_meta}>
                                         <td valign="top" align="right">{lang_metakeywords}:</td>
                                         <td><textarea name="meta_keywords" style="width:100%" rows="2">{meta_keywords}</textarea></td>
                                     </tr>                                     



More information about the geeklog-cvs mailing list