[pLog-svn] r4472 - in plog/trunk: class/action/admin class/view/admin locale templates/admin

oscar at devel.lifetype.net oscar at devel.lifetype.net
Wed Jan 3 14:12:05 GMT 2007


Author: oscar
Date: 2007-01-03 14:12:04 +0000 (Wed, 03 Jan 2007)
New Revision: 4472

Modified:
   plog/trunk/class/action/admin/adminaddpostaction.class.php
   plog/trunk/class/view/admin/admineditpostview.class.php
   plog/trunk/locale/locale_en_UK.php
   plog/trunk/templates/admin/editpost.template
   plog/trunk/templates/admin/newpost.template
Log:
removed one of the textareas because now the intro text and the extended text are all controlled via the button in the toolbar/link below the text area. I've also modified all necessary classes not to care about the removed field too.


Modified: plog/trunk/class/action/admin/adminaddpostaction.class.php
===================================================================
--- plog/trunk/class/action/admin/adminaddpostaction.class.php	2007-01-03 13:34:34 UTC (rev 4471)
+++ plog/trunk/class/action/admin/adminaddpostaction.class.php	2007-01-03 14:12:04 UTC (rev 4472)
@@ -34,7 +34,6 @@
         	$this->setValidationErrorView( $view );
         	
         	// these fields do not need to be validated but should be there when we show the view once again
-        	$this->registerField( "postExtendedText" );
         	$this->registerField( "postSlug" );
         	$this->registerField( "postStatus" );
         	$this->registerField( "sendNotification" );
@@ -118,7 +117,7 @@
 	        
             // we know for sure that the information is correct so we can now add
             // the post to the database
-			$postText = Textfilter::xhtmlize($this->_postText).POST_EXTENDED_TEXT_MODIFIER.Textfilter::xhtmlize($this->_postExtendedText);
+			$postText = Textfilter::xhtmlize($this->_postText);
 			
 			$article  = new Article( $this->_postTopic, 
 			                         $postText, 
@@ -246,7 +245,6 @@
 	    	setcookie( $cookieBaseName.'postNotSaved', '0', -1, '/' );
 	    	setcookie( $cookieBaseName.'postTopic', '', -1, '/' );
 	    	setcookie( $cookieBaseName.'postText', '', -1, '/' );
-	    	setcookie( $cookieBaseName.'postExtendedText', '', -1, '/' );
         }
     }
 ?>
\ No newline at end of file

Modified: plog/trunk/class/view/admin/admineditpostview.class.php
===================================================================
--- plog/trunk/class/view/admin/admineditpostview.class.php	2007-01-03 13:34:34 UTC (rev 4471)
+++ plog/trunk/class/view/admin/admineditpostview.class.php	2007-01-03 14:12:04 UTC (rev 4472)
@@ -50,8 +50,8 @@
 	            
 	            // set information about the post itself into the view
 	            $this->setValue( "postTopic", $this->_article->getTopic());
-	            $this->setValue( "postText", preg_replace('/(&|&)/', '&', $this->_article->getIntroText()));
-	            $this->setValue( "postExtendedText", preg_replace('/(&|&)/','&',$this->_article->getExtendedText()));
+	            $this->setValue( "postText", preg_replace('/(&|&)/', '&', $this->_article->getText( POST_EXTENDED_TEXT_MODIFIER )));
+			//$this->setValue( "postText", $this->_article->getText( POST_EXTENDED_TEXT_MODIFIER ));
 	            $this->setValue( "postSlug", $this->_article->getPostSlug());
 	            $this->setValue( "postId", $this->_article->getId());
 	            if( $this->_article->getCommentsEnabled())

Modified: plog/trunk/locale/locale_en_UK.php
===================================================================
--- plog/trunk/locale/locale_en_UK.php	2007-01-03 13:34:34 UTC (rev 4471)
+++ plog/trunk/locale/locale_en_UK.php	2007-01-03 14:12:04 UTC (rev 4472)
@@ -1229,4 +1229,7 @@
 $messages['register_step2_help'] = 'Please provide now the required information in order to create a blog.';
 
 $messages['create_date'] = 'Date created';
+
+$messages['insert_media'] = 'Insert media';
+$messages['insert_more'] = 'Insert "More..." link';
 ?>
\ No newline at end of file

Modified: plog/trunk/templates/admin/editpost.template
===================================================================
--- plog/trunk/templates/admin/editpost.template	2007-01-03 13:34:34 UTC (rev 4471)
+++ plog/trunk/templates/admin/editpost.template	2007-01-03 14:12:04 UTC (rev 4472)
@@ -73,22 +73,11 @@
 		 <div class="formHelp">{$locale->tr("text_help")}</div>
 	     {if !$htmlarea}<script type="text/javascript">var ed1 = new pLogEditor('postText','ed1');</script>{/if}
 	     <textarea {if $htmlarea==1}rows="20"{else}rows="15"{/if} id="postText" name="postText" style="width:100%">{$postText}</textarea>
+	     <a href="{if $htmlarea}javascript:tinyMCE.execInstanceCommand('mce_editor_0','mceinsertresource',true);{else}tbd{/if}">{$locale->tr("insert_media")}</a> |
+             <a href="{if $htmlarea}javascript:tinyMCE.execInstanceCommand('mce_editor_0','mcemoremore');{else}tbd{/if}">{$locale->tr("insert_more")}</a>
 	     {include file="$admintemplatepath/validate.template" field=postText message=$locale->tr("error_missing_post_text")}   
 	   </div>
 	   
-	   <div class="field">
-	     <label for="postExtendedText">{$locale->tr("extended_text")}</label>
-		 <div class="formHelp">{$locale->tr("extended_text_help")}</div>
-	     {if !$htmlarea}<script type="text/javascript">var ed2 = new pLogEditor('postExtendedText','ed2');</script>{/if}
-	     <textarea {if $htmlarea}rows="25"{else}rows="20"{/if} id="postExtendedText" name="postExtendedText" style="width:100%">{$postExtendedText}</textarea>
-	   </div>
-
-	   <div class="field">
-	     <label for="trackbackUrls">{$locale->tr("trackback_urls")}</label>
-		 <div class="formHelp">{$locale->tr("trackback_urls_help")}</div>
-	     <textarea rows="5" id="trackbackUrls" name="trackbackUrls" style="width:100%">{$trackbackUrls}</textarea>
-	   </div>
-	   
 	   <!-- text area custom fields -->
       {include file="$admintemplatepath/newpost_customfields.template" type=2 fields=$customfields}
    </div>	   

Modified: plog/trunk/templates/admin/newpost.template
===================================================================
--- plog/trunk/templates/admin/newpost.template	2007-01-03 13:34:34 UTC (rev 4471)
+++ plog/trunk/templates/admin/newpost.template	2007-01-03 14:12:04 UTC (rev 4472)
@@ -87,21 +87,16 @@
 		 <div class="formHelp">{$locale->tr("text_help")}</div>
 	     {if !$htmlarea}<script type="text/javascript">var ed1 = new pLogEditor('postText','ed1');</script>{/if}
 	     <textarea {if $htmlarea==1}rows="20"{else}rows="15"{/if} id="postText" name="postText" style="width:100%">{$postText}</textarea>
+	     <a href="{if $htmlarea}javascript:tinyMCE.execInstanceCommand('mce_editor_0','mceinsertresource',true);{else}tbd{/if}">{$locale->tr("insert_media")}</a> |
+             <a href="{if $htmlarea}javascript:tinyMCE.execInstanceCommand('mce_editor_0','mcemoremore');{else}tbd{/if}">{$locale->tr("insert_more")}</a>
 	     {include file="$admintemplatepath/validate.template" field=postText message=$locale->tr("error_missing_post_text")}   
 	   </div>
-	   
-	   <div class="field">
-	     <label for="postExtendedText">{$locale->tr("extended_text")}</label>
-		 <div class="formHelp">{$locale->tr("extended_text_help")}</div>
-	     {if !$htmlarea}<script type="text/javascript">var ed2 = new pLogEditor('postExtendedText','ed2');</script>{/if}
-	     <textarea {if $htmlarea}rows="25"{else}rows="20"{/if} id="postExtendedText" name="postExtendedText" style="width:100%">{$postExtendedText}</textarea>
-	   </div>
 
-	   <div class="field">
-	     <label for="trackbackUrls">{$locale->tr("trackback_urls")}</label>
-		 <div class="formHelp">{$locale->tr("trackback_urls_help")}</div>
-	     <textarea rows="5" id="trackbackUrls" name="trackbackUrls" style="width:100%">{$trackbackUrls}</textarea>
-	   </div>
+          <div class="field">
+            <label for="trackbackUrls">{$locale->tr("trackback_urls")}</label>
+                <div class="formHelp">{$locale->tr("trackback_urls_help")}</div>
+            <textarea rows="5" id="trackbackUrls" name="trackbackUrls" style="width:100%">{$trackbackUrls}</textarea>
+          </div>
 	   
 	   <!-- text area custom fields -->
       {include file="$admintemplatepath/newpost_customfields.template" type=2 fields=$customfields}



More information about the pLog-svn mailing list