[pLog-svn] r4538 - in plog/trunk: class/action class/dao class/misc
class/test/helpers class/test/tests/dao js/tinymce
js/tinymce/plugins js/tinymce/plugins/inlinepopups
js/tinymce/plugins/inlinepopups/langs js/tinymce/plugins/insertvideo
js/tinymce/plugins/insertvideo/css
js/tinymce/plugins/insertvideo/images
js/tinymce/plugins/insertvideo/langs templates/LifeType
templates/admin templates/default templates/standard
templates/summary
oscar at devel.lifetype.net
oscar at devel.lifetype.net
Thu Jan 11 21:49:38 GMT 2007
Author: oscar
Date: 2007-01-11 21:49:37 +0000 (Thu, 11 Jan 2007)
New Revision: 4538
Added:
plog/trunk/js/tinymce/plugins/inlinepopups/langs/
plog/trunk/js/tinymce/plugins/inlinepopups/langs/en.js
plog/trunk/js/tinymce/plugins/insertvideo/images/bolt.png
plog/trunk/js/tinymce/plugins/insertvideo/images/dalealplay.png
plog/trunk/js/tinymce/plugins/insertvideo/images/goear.png
plog/trunk/js/tinymce/plugins/insertvideo/images/ifilm.png
plog/trunk/js/tinymce/plugins/insertvideo/images/metacafe.png
plog/trunk/js/tinymce/plugins/insertvideo/images/zippyvideos.png
plog/trunk/js/tinymce/plugins/insertvideo/langs/
plog/trunk/js/tinymce/plugins/insertvideo/langs/en.js
Removed:
plog/trunk/js/tinymce/plugins/inlinepopups/langs/en.js
plog/trunk/js/tinymce/plugins/insertvideo/langs/en.js
plog/trunk/js/tinymce/plugins/more/
Modified:
plog/trunk/class/action/viewarticleaction.class.php
plog/trunk/class/dao/commentscommon.class.php
plog/trunk/class/dao/usercomment.class.php
plog/trunk/class/misc/info.class.php
plog/trunk/class/test/helpers/testtools.class.php
plog/trunk/class/test/tests/dao/commentscommon_test.class.php
plog/trunk/js/tinymce/plugins/insertvideo/css/content.css
plog/trunk/js/tinymce/plugins/insertvideo/editor_plugin.js
plog/trunk/js/tinymce/plugins/insertvideo/functions.js
plog/trunk/js/tinymce/plugins/insertvideo/videoinput.html
plog/trunk/js/tinymce/tiny_mce-plog.js
plog/trunk/templates/LifeType/error.template
plog/trunk/templates/admin/editpost.template
plog/trunk/templates/admin/header.template
plog/trunk/templates/default/commentform.template
plog/trunk/templates/standard/footer.template
plog/trunk/templates/standard/postandcomments.template
plog/trunk/templates/standard/style.css
plog/trunk/templates/summary/index.template
Log:
LT 1.1.4 merge to the main trunk
Modified: plog/trunk/class/action/viewarticleaction.class.php
===================================================================
--- plog/trunk/class/action/viewarticleaction.class.php 2007-01-11 21:40:25 UTC (rev 4537)
+++ plog/trunk/class/action/viewarticleaction.class.php 2007-01-11 21:49:37 UTC (rev 4538)
@@ -109,10 +109,11 @@
{
lt_include( PLOG_CLASS_PATH."class/dao/articles.class.php" );
$articles = new Articles();
- $id = $articles->getBlogArticleByTitle( $slug, $this->_blogInfo->getId());
+ $article = $articles->getBlogArticleByTitle( $slug, $this->_blogInfo->getId());
+ $article ? $id = $article->getId() : $id = 0;
// if the article isn't found, we will save a referrer to
// the main page, since $id will be 0.
- $this->_updateArticleReferrersById($id);
+ $this->_updateArticleReferrersById( $id );
}
/**
Modified: plog/trunk/class/dao/commentscommon.class.php
===================================================================
--- plog/trunk/class/dao/commentscommon.class.php 2007-01-11 21:40:25 UTC (rev 4537)
+++ plog/trunk/class/dao/commentscommon.class.php 2007-01-11 21:49:37 UTC (rev 4538)
@@ -137,8 +137,11 @@
lt_include( PLOG_CLASS_PATH."class/data/timestamp.class.php" );
foreach( $comments as $comment ) {
if( $this->check( $comment, $type, $status )) {
- $date = Timestamp::getDateWithOffset( $comment->getDate(), $timeDiff );
- $comment->setDate( $date );
+ // WARNING (oscar 20070101)
+ // This isn't necessary as CommentsCommon::mapRow() is already applying the offset...
+ // otherwise what we're getting here is the same offset applied twice!
+ //$date = Timestamp::getDateWithOffset( $comment->getDate(), $timeDiff );
+ //$comment->setDate( $date );
$result[] = $comment;
}
}
@@ -335,7 +338,17 @@
* @return true if update successful or false otherwise.
*/
function updateComment( $comment )
- {
+ {
+ // we need to undo the time offset before updating the comment, or else the comment will be saved
+ // with the time offset applied
+ $blogInfo = $comment->getBlogInfo();
+ $blogOffset = $blogInfo->getValue( "time_offset" );
+ if( $blogOffset != 0 ) {
+ // if there's an offset...
+ $newDate = Timestamp::getDateWithOffset( $comment->getDate(), -$blogOffset );
+ $comment->setDate( $newDate );
+ }
+
if(($result = $this->update( $comment ))) {
// reset the cache
$this->_cache->removeData( $comment->getArticleId(), CACHE_ARTICLE_COMMENTS_BYARTICLE_NEWEST_TO_OLDEST );
@@ -362,6 +375,12 @@
}
$articles->updateArticle( $article );
}
+
+ // this is not the cleanest solution but it will do the trick for now...
+ if( $blogOffset != 0 ) {
+ $newDate = Timestamp::getDateWithOffset( $comment->getDate(), $blogOffset );
+ $comment->setDate( $newDate );
+ }
return( $result );
}
@@ -540,6 +559,7 @@
$blogInfo = $blogs->getBlogInfo( $blogId );
$blogSettings = $blogInfo->getSettings();
$timeDiff = $blogSettings->getValue( "time_offset" );
+
$date = Timestamp::getDateWithOffset( $date, $timeDiff );
$comment = new UserComment( $row["article_id"],
Modified: plog/trunk/class/dao/usercomment.class.php
===================================================================
--- plog/trunk/class/dao/usercomment.class.php 2007-01-11 21:40:25 UTC (rev 4537)
+++ plog/trunk/class/dao/usercomment.class.php 2007-01-11 21:49:37 UTC (rev 4538)
@@ -35,6 +35,7 @@
var $_article;
var $_userId;
var $_user;
+ var $_blogInfo;
/**
* Creates a new user comment.
@@ -80,6 +81,8 @@
$this->setProperties( $properties );
+ $this->_blogInfo = null;
+
$this->_fields = Array(
"article_id" => "getArticleId",
"blog_id" => "getBlogId",
@@ -275,7 +278,7 @@
{
return $this->_timeStamp;
}
-
+
/**
* Returns the identifier of the comment to which this one was replying.
*
@@ -489,6 +492,22 @@
{
return( $this->getUserName());
}
+
+ /**
+ * Returns the BlogInfo object to which this comment/trackback is linked
+ *
+ * @param return A BlogInfo object
+ */
+ function getBlogInfo()
+ {
+ if( $this->_blogInfo === null ) {
+ include_once( PLOG_CLASS_PATH."class/dao/bloginfo.class.php" );
+ $blogs = new Blogs();
+ $this->_blogInfo = $blogs->getBlogInfo( $this->getBlogId());
+ }
+
+ return( $this->_blogInfo );
+ }
/**
* sets the normalized text
Modified: plog/trunk/class/misc/info.class.php
===================================================================
--- plog/trunk/class/misc/info.class.php 2007-01-11 21:40:25 UTC (rev 4537)
+++ plog/trunk/class/misc/info.class.php 2007-01-11 21:49:37 UTC (rev 4538)
@@ -13,14 +13,20 @@
class Info
{
/**
- * @return Returns the current memory usage, or nothing if it cannot be determined.
+ * @return Returns the peak memory usage (probably more useful, though only exists on php5)
+ or current memory usage (on PHP4),
+ or -1 if it cannot be determined.
* @static
*/
function getMemoryUsage()
{
- if( function_exists( "memory_get_usage" )) {
+ if( function_exists( "memory_get_peak_usage" )) {
+ return( memory_get_peak_usage());
+ }
+ else if( function_exists( "memory_get_usage" )) {
return( memory_get_usage());
}
+ return "";
}
/**
Modified: plog/trunk/class/test/helpers/testtools.class.php
===================================================================
--- plog/trunk/class/test/helpers/testtools.class.php 2007-01-11 21:40:25 UTC (rev 4537)
+++ plog/trunk/class/test/helpers/testtools.class.php 2007-01-11 21:49:37 UTC (rev 4538)
@@ -223,6 +223,10 @@
$users = new Users();
$users->deleteUser( $item->getId());
}
+ elseif( $className == "usercomment" ) {
+ $comments = new ArticleComments();
+ $comments->deleteComment( $item->getId());
+ }
else {
print("Unrecognized object of class $className" );
print_r( $item );
Modified: plog/trunk/class/test/tests/dao/commentscommon_test.class.php
===================================================================
--- plog/trunk/class/test/tests/dao/commentscommon_test.class.php 2007-01-11 21:40:25 UTC (rev 4537)
+++ plog/trunk/class/test/tests/dao/commentscommon_test.class.php 2007-01-11 21:49:37 UTC (rev 4538)
@@ -1,6 +1,7 @@
<?php
include_once( PLOG_CLASS_PATH."class/test/helpers/lifetypetestcase.class.php" );
+ include_once( PLOG_CLASS_PATH."class/test/helpers/testtools.class.php" );
include_once( PLOG_CLASS_PATH."class/dao/bloginfo.class.php" );
include_once( PLOG_CLASS_PATH."class/dao/blogs.class.php" );
include_once( PLOG_CLASS_PATH."class/dao/article.class.php" );
@@ -25,19 +26,19 @@
function testGetNumPostComments()
{
- // create a user
+ // create a user
$users = new Users();
$randomName = md5(time());
$user = new UserInfo($randomName, "blah", "test at not-a-real-address.net", "", "Full Name");
$this->assertTrue($users->addUser($user), "Couldn't add test user");
- // create a blog
+ // create a blog
$blogs = new Blogs();
$randomName = md5(time());
$blog = new BlogInfo( $randomName, $user->getId(), "About blog random blog", new BlogSettings());
$this->assertTrue($blogs->addBlog( $blog ), "Couldn't add test blog");
- // add an article
+ // add an article
$articles = new Articles();
$article = new Article(
"dummy topic",
@@ -50,7 +51,7 @@
);
$this->assertTrue($articles->addArticle($article), "Couldn't add test article");
- // Add comments
+ // Add comments
$timestamp = new Timestamp();
$comment1 = new UserComment($article->getId(),
$article->getBlogId(),
@@ -163,6 +164,43 @@
$users->deleteUser($user->getId());
}
+ /**
+ * Test case for mantis bug http://bugs.lifetype.net/view.php?id=1144
+ *
+ * Dates with time offset being saved to the database
+ */
+ function testUpdateCommentWithTimeOffsets()
+ {
+ // create the scenario
+ $user = TestTools::createUser();
+ $blog = TestTools::createBlog( $user->getId());
+ $cat = TestTools::createArticleCategory( $blog->getId());
+ $article = TestTools::createArticle( $blog->getId(), $user->getId(), Array( $cat->getId()));
+
+ // update the time offset settings for the blog
+ $blog->setValue( "time_offset", "+3" );
+ $blogs = new Blogs();
+ $blogs->updateBlog( $blog );
+
+ // create the comment and save it to the database
+ $comment = new UserComment( $article->getId(), $blog->getId(), 0, "test comment", "test comment body" );
+ $comments = new ArticleComments();
+ $comments->addComment( $comment );
+
+ // now get the time
+ $origTime = $comment->getTimestamp();
+
+ // update the comment and reload the comment
+ $comments->updateComment( $comment );
+ $comment2 = $comments->getComment( $comment->getId());
+ $newTime = $comment2->getTimestamp();
+
+ // check that dates are the same
+ $this->assertEquals( $origTime->getTimestamp(), $newTime->getTimestamp(), "Comment times are not the same!" );
+
+ // destroy the test data
+ TestTools::deleteDaoTestData( Array( $user, $blog, $cat, $article, $comment, $comment2 ));
+ }
}
?>
Copied: plog/trunk/js/tinymce/plugins/inlinepopups/langs (from rev 4537, plog/branches/lifetype-1.1.4/js/tinymce/plugins/inlinepopups/langs)
Deleted: plog/trunk/js/tinymce/plugins/inlinepopups/langs/en.js
===================================================================
--- plog/branches/lifetype-1.1.4/js/tinymce/plugins/inlinepopups/langs/en.js 2007-01-11 21:40:25 UTC (rev 4537)
+++ plog/trunk/js/tinymce/plugins/inlinepopups/langs/en.js 2007-01-11 21:49:37 UTC (rev 4538)
@@ -1 +0,0 @@
-
Copied: plog/trunk/js/tinymce/plugins/inlinepopups/langs/en.js (from rev 4537, plog/branches/lifetype-1.1.4/js/tinymce/plugins/inlinepopups/langs/en.js)
Modified: plog/trunk/js/tinymce/plugins/insertvideo/css/content.css
===================================================================
--- plog/trunk/js/tinymce/plugins/insertvideo/css/content.css 2007-01-11 21:40:25 UTC (rev 4537)
+++ plog/trunk/js/tinymce/plugins/insertvideo/css/content.css 2007-01-11 21:49:37 UTC (rev 4538)
@@ -5,7 +5,6 @@
background-repeat: no-repeat;
background-color: #ffffcc;
}
-
.ltVideoGoogleVideo {
border: 1px dotted #cc0000;
background-image: url('../images/gvideo.png');
@@ -13,3 +12,24 @@
background-repeat: no-repeat;
background-color: #ffffcc;
}
+.ltVideoMetacafe {
+ border: 1px dotted #cc0000;
+ background-image: url('../images/metacafe.png');
+ background-position: center;
+ background-repeat: no-repeat;
+ background-color: #ffffcc;
+ }
+.ltVideoIfilm {
+ border: 1px dotted #cc0000;
+ background-image: url('../images/ifilm.png');
+ background-position: center;
+ background-repeat: no-repeat;
+ background-color: #ffffcc;
+ }
+.ltVideoGoear {
+ border: 1px dotted #cc0000;
+ background-image: url('../images/goear.png');
+ background-position: center;
+ background-repeat: no-repeat;
+ background-color: #ffffcc;
+ }
\ No newline at end of file
Modified: plog/trunk/js/tinymce/plugins/insertvideo/editor_plugin.js
===================================================================
--- plog/trunk/js/tinymce/plugins/insertvideo/editor_plugin.js 2007-01-11 21:40:25 UTC (rev 4537)
+++ plog/trunk/js/tinymce/plugins/insertvideo/editor_plugin.js 2007-01-11 21:49:37 UTC (rev 4538)
@@ -49,7 +49,7 @@
insertvideo['file'] = '../../plugins/insertvideo/videoinput.html'; // Relative to theme
insertvideo['width'] = 500;
- insertvideo['height'] = 160;
+ insertvideo['height'] = 260;
tinyMCE.openWindow(insertvideo, {editor_id : editor_id, resizable : "no", scrollbars : "no", inline : "yes"});
}
@@ -63,7 +63,6 @@
cleanup : function(type, content) {
switch (type) {
case "insert_to_editor_dom":
-
// Force relative/absolute
if (tinyMCE.getParam('convert_urls')) {
var imgs = content.getElementsByTagName("img");
@@ -80,7 +79,6 @@
}
}
}
-
break;
case "get_from_editor_dom":
@@ -130,6 +128,15 @@
else if( videoType == 2 ) {
cssClass = "ltVideoYouTube";
}
+ else if( videoType == 3 ) {
+ cssClass = "ltVideoMetacafe";
+ }
+ else if( videoType == 4 ) {
+ cssClass = "ltVideoIfilm";
+ }
+ else if( videoType == 5 ) {
+ cssClass = "ltVideoGoear";
+ }
else {
// ignore it, it's not a youtube or googlevideo video
startPos++;
@@ -161,7 +168,7 @@
var attribs = TinyMCE_insertvideoPlugin._parseAttributes(content.substring(startPos + 4, endPos));
// Is not flash, skip it
- if (attribs['class'] != "ltVideoYouTube" && attribs['class'] != "ltVideoGoogleVideo")
+ if (attribs['class'] != "ltVideoYouTube" && attribs['class'] != "ltVideoGoogleVideo" && attribs['class'] != "ltVideoMetacafe" && attribs['class'] != "ltVideoIfilm" && attribs['class'] != "ltVideoGoear" )
continue;
type = attribs['class'];
@@ -173,7 +180,7 @@
var quality = tinyMCE.getParam("flash_quality", "high");
var menu = tinyMCE.getParam("flash_menu", "false");
- embedHTML = getVideoFlashHTML( attribs["title"], attribs["width"], attribs["height"] );
+ embedHTML = getVideoFlashHTML( attribs["title"], attribs["width"], attribs["height"] , type );
// Insert embed/object chunk
chunkBefore = content.substring(0, startPos);
@@ -251,19 +258,23 @@
}
};
-function getVideoFlashHTML( url, width, height )
+function getVideoFlashHTML( url, width, height , type )
{
- html = "<object type=\"application/x-shockwave-flash\" width=\""+width+"\" height=\""+height+"\" data=\""+url+"\">"+
+ html = "<object type=\"application/x-shockwave-flash\" width=\""+width+"\" height=\""+height+"\" data=\""+url+"\" id=\""+type+"\">"+
"<param name=\"movie\" value=\""+url+"\" />"+
"<param name=\"wmode\" value=\"transparent\" />"+
"<param name=\"allowScriptAcess\" value=\"sameDomain\" />"+
"<param name=\"quality\" value=\"best\" />"+
- "<param name=\"bgcolor\" value=\"#FFFFFF\" />"+
- "<param name=\"scale\" value=\"noScale\" />"+
- "<param name=\"salign\" value=\"TL\" />"+
- "<param name=\"FlashVars\" value=\"playerMode=embedded\" />"+
- "</object>";
+ "<param name=\"bgcolor\" value=\"#FFFFFF\" />";
+// "<param name=\"scale\" value=\"noScale\" />";
+ if (type=='ltVideoGoear') {
+ html= html + "<param name=\"FlashVars\" value=\""+url.substring( 43, url.length ) + "\" />";
+ } else {
+ html = html + "<param name=\"FlashVars\" value=\"playerMode=embedded\" />";
+ }
+ html = html + "</object>";
+
return( html );
}
@@ -274,6 +285,12 @@
return 1;
else if( url.substring( 0, 23 ) == "http://www.youtube.com/" )
return 2;
+ else if( url.substring( 0, 24 ) == "http://www.metacafe.com/" )
+ return 3;
+ else if( url.substring( 0, 21 ) == "http://www.ifilm.com/" )
+ return 4;
+ else if( url.substring( 0, 21 ) == "http://www.goear.com/" )
+ return 5;
else
return 0;
}
Modified: plog/trunk/js/tinymce/plugins/insertvideo/functions.js
===================================================================
--- plog/trunk/js/tinymce/plugins/insertvideo/functions.js 2007-01-11 21:40:25 UTC (rev 4537)
+++ plog/trunk/js/tinymce/plugins/insertvideo/functions.js 2007-01-11 21:49:37 UTC (rev 4538)
@@ -48,6 +48,65 @@
return( url );
}
+function getMetacafeVideoLink( url )
+{
+ // check if it's a link to a video page or a link to the video player
+ if( url.substring( 0, 30 ) == "http://www.metacafe.com/watch/" ) {
+ // if it's a link to a video page, generate the right one
+ var regexp = /http:\/\/www.metacafe.com\/watch\/.*?docid=([\-0-9a-zA-z_]*).*/i;
+ result = regexp.exec( url );
+ if( result ) {
+ videoId = result[1];
+ }
+ else {
+ videoId = url.substring( 30, url.length - 1 );
+ }
+
+ url = "http://www.metacafe.com/fplayer/" + videoId + ".swf";
+ }
+
+ return( url );
+}
+
+function getiFilmVideoLink( url )
+{
+ // check if it's a link to a video page or a link to the video player
+ if( url.substring( 0, 27 ) == "http://www.ifilm.com/video/" ) {
+ // if it's a link to a video page, generate the right one
+ var regexp = /http:\/\/www.ifilm.com\/video\/.*?docid=([\-0-9a-zA-z_]*).*/i;
+ result = regexp.exec( url );
+ if( result ) {
+ videoId = result[1];
+ }
+ else {
+ videoId = url.substring( 27, url.length );
+ }
+
+ url = "http://www.ifilm.com/efp?flvbaseclip=" + videoId ;
+ }
+
+ return( url );
+}
+
+function getGoearVideoLink( url )
+{
+ // check if it's a link to a video page or a link to the video player
+ if( url.substring( 0, 34 ) == "http://www.goear.com/listen.php?v=" ) {
+ // if it's a link to a video page, generate the right one
+ var regexp = /http:\/\/www.goear.com\/.*?v=([\-0-9a-zA-z_]*).*/i;
+ result = regexp.exec( url );
+ if( result ) {
+ videoId = result[1];
+ }
+ else {
+ videoId = url.substring( 34, url.length );
+ }
+ url = "http://www.goear.com/files/localplayer.swf?file=" + videoId ;
+ }
+
+ return( url );
+}
+
function insertVideoCode()
{
// get and check the URL
@@ -61,8 +120,14 @@
// check if a destination system was selected
youtube = document.getElementById("youtube");
gvideo = document.getElementById("gvideo");
- if( youtube.checked==false && gvideo.checked==false) {
- window.alert( "You must select one of the video services" );
+// dalealplay = document.getElementById("dalealplay");
+ metacafe = document.getElementById("metacafe");
+ ifilm = document.getElementById("ifilm");
+ goear = document.getElementById("goear");
+// bolt = document.getElementById("bolt");
+
+ if( youtube.checked==false && gvideo.checked==false && metacafe.checked==false && ifilm.checked==false && goear.checked==false ) {
+ window.alert( "Debes seleccionar el tipo de video." );
return( false );
}
@@ -72,12 +137,30 @@
width=450;
height=350;
}
- else {
+ if( gvideo.checked == true ) {
link = getGoogleVideoLink( url );
css="ltVideoGoogleVideo";
width=400;
height=326;
}
+ if( metacafe.checked == true ) {
+ link = getMetacafeVideoLink( url );
+ css="ltVideoMetacafe";
+ width=400;
+ height=345;
+ }
+ if( ifilm.checked == true ) {
+ link = getiFilmVideoLink( url );
+ css="ltVideoIfilm";
+ width=448;
+ height=365;
+ }
+ if( goear.checked == true ) {
+ link = getGoearVideoLink( url );
+ css="ltVideoGoear";
+ width=366;
+ height=75;
+ }
insertFlash( link, css, width, height );
}
Copied: plog/trunk/js/tinymce/plugins/insertvideo/images/bolt.png (from rev 4537, plog/branches/lifetype-1.1.4/js/tinymce/plugins/insertvideo/images/bolt.png)
Copied: plog/trunk/js/tinymce/plugins/insertvideo/images/dalealplay.png (from rev 4537, plog/branches/lifetype-1.1.4/js/tinymce/plugins/insertvideo/images/dalealplay.png)
Copied: plog/trunk/js/tinymce/plugins/insertvideo/images/goear.png (from rev 4537, plog/branches/lifetype-1.1.4/js/tinymce/plugins/insertvideo/images/goear.png)
Copied: plog/trunk/js/tinymce/plugins/insertvideo/images/ifilm.png (from rev 4537, plog/branches/lifetype-1.1.4/js/tinymce/plugins/insertvideo/images/ifilm.png)
Copied: plog/trunk/js/tinymce/plugins/insertvideo/images/metacafe.png (from rev 4537, plog/branches/lifetype-1.1.4/js/tinymce/plugins/insertvideo/images/metacafe.png)
Copied: plog/trunk/js/tinymce/plugins/insertvideo/images/zippyvideos.png (from rev 4537, plog/branches/lifetype-1.1.4/js/tinymce/plugins/insertvideo/images/zippyvideos.png)
Copied: plog/trunk/js/tinymce/plugins/insertvideo/langs (from rev 4537, plog/branches/lifetype-1.1.4/js/tinymce/plugins/insertvideo/langs)
Deleted: plog/trunk/js/tinymce/plugins/insertvideo/langs/en.js
===================================================================
Copied: plog/trunk/js/tinymce/plugins/insertvideo/langs/en.js (from rev 4537, plog/branches/lifetype-1.1.4/js/tinymce/plugins/insertvideo/langs/en.js)
Modified: plog/trunk/js/tinymce/plugins/insertvideo/videoinput.html
===================================================================
--- plog/trunk/js/tinymce/plugins/insertvideo/videoinput.html 2007-01-11 21:40:25 UTC (rev 4537)
+++ plog/trunk/js/tinymce/plugins/insertvideo/videoinput.html 2007-01-11 21:49:37 UTC (rev 4538)
@@ -23,8 +23,11 @@
<tr>
<td nowrap="nowrap">Source:</td>
<td>
- <input type="radio" id="youtube" style="border:0px" name="type" value="1"><img src="images/youtube.png" alt="YouTube" /> YouTube
- <input type="radio" id="gvideo" style="border:0px"name="type" value="2"><img src="images/gvideo.png" alt="Google Video" /> Google Video
+ <input type="radio" id="youtube" style="border:0px" name="type" value="1"><img src="images/youtube.png" alt="YouTube" /> YouTube<br />
+ <input type="radio" id="gvideo" style="border:0px"name="type" value="2"><img src="images/gvideo.png" alt="Google Video" /> Google Video<br />
+ <input type="radio" id="metacafe" style="border:0px"name="type" value="3"><img src="images/metacafe.png" alt="Metacafe" /> Metacafe<br />
+ <input type="radio" id="ifilm" style="border:0px"name="type" value="4"><img src="images/ifilm.png" alt="iFilm" /> iFilm<br />
+ <input type="radio" id="goear" style="border:0px"name="type" value="5"><img src="images/goear.png" alt="Goear" /> Goear<br />
</td>
</tr>
</table>
Modified: plog/trunk/js/tinymce/tiny_mce-plog.js
===================================================================
--- plog/trunk/js/tinymce/tiny_mce-plog.js 2007-01-11 21:40:25 UTC (rev 4537)
+++ plog/trunk/js/tinymce/tiny_mce-plog.js 2007-01-11 21:49:37 UTC (rev 4538)
@@ -2,14 +2,14 @@
mode : "exact",
elements : "postText,postExtendedText",
theme : "advanced",
- plugins : "fullscreen,table,inlinepopups,insertdatetime,emotions,insertresource,insertvideo,more",
+ plugins : "fullscreen,table,inlinepopups,insertdatetime,emotions,insertresource,insertvideo",
relative_urls : false,
fix_list_elements : true,
remove_script_host : false,
force_p_newlines : true,
cleanup_on_startup : true,
theme_advanced_buttons1 : "fontsizeselect,fontselect,forecolor,backcolor,bold,italic,underline,strikethrough,separator,justifyleft,justifycenter,justifyright,justifyfull",
- theme_advanced_buttons2 : "bullist,numlist,indent,outdent,separator,link,unlink,image,insertresource,insertvideo,emotions,separator,hr,insertdate,inserttime,separator,fullscreen,separator,code,more",
+ theme_advanced_buttons2 : "bullist,numlist,indent,outdent,separator,link,unlink,image,insertresource,insertvideo,emotions,separator,hr,insertdate,inserttime,separator,fullscreen,separator,code",
theme_advanced_buttons3 : "",
fullscreen_settings : {
theme_advanced_buttons3 : "tablecontrols"
Modified: plog/trunk/templates/LifeType/error.template
===================================================================
--- plog/trunk/templates/LifeType/error.template 2007-01-11 21:40:25 UTC (rev 4537)
+++ plog/trunk/templates/LifeType/error.template 2007-01-11 21:49:37 UTC (rev 4538)
@@ -1,15 +1,15 @@
{include file="$blogtemplate/header.template"}
<div id="content" class="narrowcolumn">
- <div class="post">
- <h2 class="title">{$locale->tr("error")}</h2>
- <div class="entry">
- <br/>
- {$locale->tr($message)}
- <br/><br/>
- <a href="javascript:history.go(-1)">{$locale->tr("back")}</a>
- </div>
- </div>
+<div class="post">
+<h2 class="title">{$locale->tr("error")}</h2>
+<div class="entry">
+<br/>
+{$locale->tr($message)}
+<br/><br/>
+<a href="javascript:history.go(-1)">{$locale->tr("back")}</a>
</div>
+</div>
+</div>
{include file="$blogtemplate/panel.template"}
-{include file="$blogtemplate/footer.template"}
+{include file="$blogtemplate/footer.template"}
\ No newline at end of file
Modified: plog/trunk/templates/admin/editpost.template
===================================================================
--- plog/trunk/templates/admin/editpost.template 2007-01-11 21:40:25 UTC (rev 4537)
+++ plog/trunk/templates/admin/editpost.template 2007-01-11 21:49:37 UTC (rev 4538)
@@ -31,20 +31,20 @@
function selectOperation( t )
{
if( preview ) {
- document.editPost.op.value="previewPost";
+ document.newPost.op.value="previewPost";
window.open("", t, "scrollbars=yes,resizable=yes,toolbar=no" );
return true;
}
else {
- document.editPost.op.value="updatePost";
- document.editPost.target="";
- document.editPost.action="admin.php";
+ document.newPost.op.value="updatePost";
+ document.newPost.target="";
+ document.newPost.action="admin.php";
return true;
}
}
{/literal}
</script>
- <form name="editPost" id="editPost" method="post" onSubmit="return selectOperation(this.target);" target="admin">
+ <form name="newPost" id="newPost" method="post" onSubmit="return selectOperation(this.target);" target="admin">
<fieldset class="inputField">
<legend>{$locale->tr("editPost")}</legend>
Modified: plog/trunk/templates/admin/header.template
===================================================================
--- plog/trunk/templates/admin/header.template 2007-01-11 21:40:25 UTC (rev 4537)
+++ plog/trunk/templates/admin/header.template 2007-01-11 21:49:37 UTC (rev 4538)
@@ -1,4 +1,3 @@
-{assign var=blogEnablePullDownMenu value=$blogsettings->getValue("pull_down_menu_enabled")}
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en" >
@@ -7,6 +6,7 @@
<meta http-equiv="Content-Style-Type" content="text/css" />
<meta name="generator" content="{$version}" />
<title>LifeType Admin</title>
+{assign var=blogEnablePullDownMenu value=$blogsettings->getValue("pull_down_menu_enabled")}
{if $locale->getDirection()=="rtl"}
<link rel="stylesheet" href="styles/admin-rtl.css" type="text/css" media="screen" />
{else}
Modified: plog/trunk/templates/default/commentform.template
===================================================================
--- plog/trunk/templates/default/commentform.template 2007-01-11 21:40:25 UTC (rev 4537)
+++ plog/trunk/templates/default/commentform.template 2007-01-11 21:49:37 UTC (rev 4538)
@@ -1,3 +1,4 @@
+<h1>DEFAULT</h1>
{if $allowComments}
<div id="CommentForm">
<form id="NewComment" action="{$url->getIndexUrl()}" method="post">
@@ -28,4 +29,4 @@
</fieldset>
</form>
</div>
-{/if}
\ No newline at end of file
+{/if}
Modified: plog/trunk/templates/standard/footer.template
===================================================================
--- plog/trunk/templates/standard/footer.template 2007-01-11 21:40:25 UTC (rev 4537)
+++ plog/trunk/templates/standard/footer.template 2007-01-11 21:49:37 UTC (rev 4538)
@@ -3,7 +3,14 @@
</div>
<div id="Menu">
+
+<h1>Random picture</h1>
+{assign var=latestImage value=$galleryimages->randomImage(4)}
+<a href="{$url->resourceLink($latestImage)}">
+<img style="border:0px;" src="{$url->resourcePreviewLink($latestImage)}" alt="{$latestImage->getDescription()}" />
+</a>
+
{assign var=blogOwner value=$blog->getOwnerInfo()}
{assign var=AboutMyself value=$blogOwner->getAboutMyself()}
{if $blogOwner->hasPicture() && $AboutMyself}
Modified: plog/trunk/templates/standard/postandcomments.template
===================================================================
--- plog/trunk/templates/standard/postandcomments.template 2007-01-11 21:40:25 UTC (rev 4537)
+++ plog/trunk/templates/standard/postandcomments.template 2007-01-11 21:49:37 UTC (rev 4538)
@@ -11,11 +11,13 @@
{if $blogsettings->getValue("comments_enabled") && $post->getCommentsEnabled()==1 || $comments }<h2 id="comments">{$locale->tr("comments")|capitalize}</h2>
{/if}
{pager style="links"}
- {foreach from=$comments item=comment}
-<div class="comment">
+{assign var=comments value=$nestedcomments->getNestedComments($post)}
+ {foreach from=$comments item=comment}
+<div class="comment_{$comment->getValue("depth")}">
<h3 class="commentheader">{if $comment->getTopic() != null} {$comment->getTopic()|strip_tags}{else}Re: <em>{$post->getTopic()|strip_tags}</em>{/if}</h3>
<p class="commentposterinfo">
+<img src="{$gravatar->gravatar($comment)}" width="{$gravatar->getSize()}" height="{$gravatar->getSize()}" align="left" />
{assign var="postDate" value=$comment->getTimestamp()}
{if $comment->getUserUrl() != ""}<a href="{$comment->getUserUrl()}">{$comment->getUsername()}</a>
{else}
Modified: plog/trunk/templates/standard/style.css
===================================================================
--- plog/trunk/templates/standard/style.css 2007-01-11 21:40:25 UTC (rev 4537)
+++ plog/trunk/templates/standard/style.css 2007-01-11 21:49:37 UTC (rev 4538)
@@ -94,7 +94,7 @@
float: left;
margin-right:3%;
margin-left:2%;
- background-color:#fff;
+ background-color:#fff;
overflow: hidden;
line-height:1.5em;
text-align:justify;
@@ -256,8 +256,8 @@
text-align:center
}
-.calMonthToday {
- background-color: #d4d0cd;
+.calMonthToday {
+ background-color: #d4d0cd;
}
#Menu h2 {
@@ -357,7 +357,7 @@
text-align: center;
padding: 0;
margin:0;
- width:150px;
+ width:150px;
overflow: hidden;
}
@@ -389,7 +389,7 @@
}
-blockquote {background:url('imgs/blockquote.gif') no-repeat; padding:10px 10px 2px 41px;border: dotted #d4d0cd 1px;
+blockquote {background:url('imgs/blockquote.gif') no-repeat; padding:10px 10px 2px 41px;border: dotted #d4d0cd 1px;
}
/* ****************** to align elements *************** */
@@ -408,4 +408,14 @@
/* ****************** aboutmyself *************** */
#UserPicture {float:left;margin:10px 10px 10px 6px;border:solid #D4D0CD 1px;padding:3px;background-color:#fff}
-#AboutMyself p {padding:10px 0;margin:0}
\ No newline at end of file
+#AboutMyself p {padding:10px 0;margin:0}
+
+.comment_1 {
+ margin-left: 10px;
+ }
+ .comment_2 {
+ margin-left: 20px;
+ }
+ .comment_3 {
+ margin-left: 30px;
+ }
\ No newline at end of file
Modified: plog/trunk/templates/summary/index.template
===================================================================
--- plog/trunk/templates/summary/index.template 2007-01-11 21:40:25 UTC (rev 4537)
+++ plog/trunk/templates/summary/index.template 2007-01-11 21:49:37 UTC (rev 4538)
@@ -30,7 +30,7 @@
<h2>{$locale->tr("login")}</h2>
<form id="loginForm" method="post" action="admin.php">
<fieldset class="inputField">
- {dynamic}
+ {dynamic}
{if $authuser}
{assign var=userName value=$authuser->getUsername()}
{$locale->pr("summary_welcome_msg", $userName)}<br/>
More information about the pLog-svn
mailing list