歡迎光臨, 訪客. 請先 登入註冊一個帳號.
四月 27, 2024, 11:42:20 上午
19595 文章 在 3865 主題 由 4580 會員
最新註冊會員: aa123aa1
  列出文章
頁: 1 [2] 3
16  建議 / 要求與建議 / 有 lifetype 1.2 的展示網站嗎 於: 三月 07, 2007, 04:20:25 下午
有 lifetype 1.2 的展示網站嗎

英文官網有 1.2 beta 的新聞
17  開發 / 模版設計 / Re: 該如何在顯示文章列表? 於: 十一月 11, 2006, 09:36:48 下午
sorry, 我好像來亂的, 我那個說法是錯的  嚎啕大哭

上面提到的 !$OnMainPage 那個只能適用

main.template 嵌入 post.template 和 postandcomments.template 嵌入 post.template
二者不同的判斷..

如果要做到分類目錄下只列文章標題
請參考 1.1 的 standard 樣版中 main.template
程式碼:
{if $category}<h2>{$locale->tr("category")}: {$category->getName()}</h2>{/if} 
 
{foreach from=$posts item=post}
{if $showAll | 1 && $category}
  <!-- showing only the topic of the post, in case we have too many! -->
<h3><a href="{$url->postPermalink($post)}">{$post->getTopic()}</a></h3>
<div>
{$post->getText()|strip_tags|truncate:300:"...":false}
</div>

<p class="footer">
{foreach name=categories from=$post->getCategories() item=postCategory}
  <a href="{$url->categoryLink($postCategory)}">{$postCategory->getName()}</a>{if !$smarty.foreach.categories.last}, {/if}
{/foreach}
</p>
{else}
藉由判斷有沒有 $category 變數...
18  開發 / 模版設計 / Re: 該如何在顯示文章列表? 於: 十一月 11, 2006, 02:03:46 上午
呃, 我似乎沒說清楚

main.template 的第一行

{assign var="OnMainPage" value=1}

這是關鍵, 因為 $OnMainPage 的宣告和初值 ...

所以你的 main.template 也要有這行, post.template的判斷才有意義
19  支援 / 安裝與設定 / Re: 安裝新的網誌模板重新登入時出現問題 於: 十一月 09, 2006, 03:53:22 下午
你的 liftetype 是 1.0.6 版吧

你使用的 Fastrack 應該是適用 1.1 版的
1.1版的才有 pager 這個東西

所以你要找 Fastrack 適用 1.0.6 的
或是將你的 lifetype 升級到 1.1
20  開發 / 模版設計 / Re: 該如何在顯示文章列表? 於: 十一月 09, 2006, 01:51:30 下午
我今天從 1.0.6 升級到 1.1 之後, 原有文章分類的顯示方式也都改變了
原本是文章列表的, 但現在則連內文都出現了
找「 $showAll 」也沒看到相關的文章,有人可以指點一下嗎?
謝謝
參考一下 1.1版 standard 模版的
main.template 和 post.template
有個 $OnMainPage 變數
21  支援 / 安裝與設定 / Re: lifetype1.1文章分頁問題 於: 十一月 08, 2006, 01:09:21 下午
要不要更新 1.1.1 再看看??
22  支援 / 安裝與設定 / Re: 時間差調整問題 於: 十一月 08, 2006, 01:07:26 下午
可以做以下修改囉
http://forum.lifetype.org.tw/index.php?topic=2838.msg15856#msg15856

我也是有發現這個情況, 1.1.1 問題還是存在
可能比較少人注意到迴響的時間吧!!
23  建議 / 要求與建議 / Re: 討論區搜尋問題 於: 十一月 08, 2006, 12:42:39 下午
smf 有更新到 1.0.9 了
24  支援 / 使用與操作 / Re: tinymce,edit html souce問題.................. 於: 十月 24, 2006, 12:46:53 下午
印象中, tinymce 不支援 <embed> , 或許只留下 object 的語法看看吧
25  測試 / LifeType 1.1 測試 / 1.1 搜尋結果翻頁的連結有誤 ( pager ) 於: 十月 14, 2006, 12:25:12 上午
搜尋結果如果超多一頁的話, 其他頁數的連結是錯的,
如果點其他頁數, 會導致搜尋 blogid 是 1的那個 blog

如下列
index.php?op=Search&searchTerms=xxxxxx&page=2

解決方法就是 pager 產成的連結加上 blogid

class/action/searchaction.class.php
orig:
程式碼:
$basePageUrl = $url->getIndexUrl()."?op=Search&amp;searchTerms=".$this->_searchTerms."&amp;page=";

改成
程式碼:
$basePageUrl = $url->getIndexUrl()."?op=Search&amp;blogId=".$this->_blogInfo->getId()."&amp;searchTerms=".$this->_searchTerms."&amp;page=";

不知道是沒人發現??還是其實沒錯誤???
26  支援 / 安裝與設定 / Re: [求助]UPLOAD问题 於: 九月 19, 2006, 01:42:03 上午
在问个问题,如果我把程序装在  1.com 然后数据库用 2.com 的可以吗,就是程序和数据库在不同主机上,这样应该可以解决这个问题了.
如果你的資料庫能夠外連的就可以唄
27  測試 / LifeType 1.1 測試 / Re: 縮圖的比例問題 ... 1.1版 於: 九月 19, 2006, 01:20:53 上午
lss 你好阿,

可是我覺得這不是 bug ...
只是縮圖強制變成方形的
(雖然是等比例, 不過長邊的會被剪裁, 現在的似乎相簿很流行這樣, 據說是美觀)
我剛好不需要這功能 ...

如果後台多個選項應該是不錯的方法..

不過我的英文書寫有問題 XD
28  測試 / LifeType 1.1 測試 / Re: 縮圖的比例問題 ... 1.1版 於: 九月 18, 2006, 06:26:01 下午
比對過 1.0.6 和 1.1 ...

如果有跟我相同困擾的人可以以照下面修改

class/gallery/resizers/gallerygdresizer.class.php

只註解掉某段
程式碼:
        function ImageResize($dst_img, &$src_img, $dst_x, $dst_y, $src_x, 
                                   $src_y, $dst_w, $dst_h, $src_w, $src_h,
                                   $resample = GD_RESIZER_NO_SMOOTHING_MODE ) {
           $pxls = intval($src_w / $dst_w)-1;
/*     
           if( $dst_w == $dst_h ) {
    $length = min($src_w, $src_h);
    $src_x = intval( $src_w / 2 ) - intval( $length / 2 );
    $src_y = intval( $src_h / 2 ) - intval( $length / 2 );
    $src_w = $length;
    $src_h = $length;
   }*/

加上 1.0.6的寫法, 註解掉 1.1的
程式碼:
        function calcThumbFormat($width, $height){
            $ratioimg = (float) $this->img["lebar"] / (float) $this->img["tinggi"];
            $ratiothumb=(float) $width / (float) $height;
           //hsuzy. 1.0.6版
            if ($ratioimg == $ratiothumb){
                $this->img["lebar_thumb"]=$width;
                $this->img["tinggi_thumb"]=$height;
            } elseif ($ratioimg > $ratiothumb){
                $this->img["lebar_thumb"]=$width;
                $this->img["tinggi_thumb"]=$width*((float)1/$ratioimg);
            } elseif ($ratioimg < $ratiothumb){
                $this->img["tinggi_thumb"]=$height;
                $this->img["lebar_thumb"]=$height*$ratioimg;
            }
/*
            if ($ratioimg == $ratiothumb || $ratiothumb == (float) 1){
                $this->img["lebar_thumb"]=$width;
                $this->img["tinggi_thumb"]=$height;
            } elseif ($ratioimg > $ratiothumb){
            $length = max($width, $height);
                $this->img["lebar_thumb"]=$length;
                $this->img["tinggi_thumb"]=$length*((float)1/$ratioimg);
            } elseif ($ratioimg < $ratiothumb){
            $length = max($width, $height);
                $this->img["tinggi_thumb"]=$length;
                $this->img["lebar_thumb"]=$length*$ratioimg;
            }
*/
        }
29  測試 / LifeType 1.1 測試 / 縮圖的比例問題 ... 1.1版 於: 九月 17, 2006, 03:29:02 上午
以下是我的設定
--
您用來產生縮圖的後端系統。如果使用PHP,GD的支援是必須的。PHP's GD library
在產生預覽縮圖時所使用的預設格式。如果您選擇「與原始影像相同」,那麼預覽縮圖就會儲存成與原始影像相同的格式。與原始影像相同
thumbnail_height: 200
thumbnail_width: 200
medium_size_thumbnail_width: 500
medium_size_thumbnail_height: 500
縮圖是否保持原始比例。:
是否使用演算法來使縮圖畫面更平順。只有當縮圖產生工具是GD時才適用。
PHP ImageCopyResampled
--
結果產生的中圖, 不管是傳 800x600或 600x800 的圖, 都被縮成 500x500
而長的那邊被裁剪, 我的需求是等比例, 不知道我哪裡設定有問題

謝謝
30  測試 / LifeType 1.1 測試 / 升級成 1.1 版 迴響時間有誤差 於: 九月 12, 2006, 01:01:14 下午
因為我的主機放在國外, 時差是 +13小時

我在發表文章時候時間是正確的
不過迴響時跟文章的時間又差+13

不知道有沒有人有相同情形??

後來我在
class/dao/commentscommn.class.php
程式碼:
                function getPostComments( $artid,
                                          $order = COMMENT_ORDER_NEWEST_FIRST,
                                          $status = COMMENT_STATUS_ALL,
                                          $type = COMMENT_TYPE_ANY,
                                          $page = -1,
                                          $itemsPerPage = DEFAULT_ITEMS_PER_PAGE )
..................
.................
..................
$date = Timestamp::getDateWithOffset( $comment->getDate(), $timeDiff );
改成
程式碼:
$date = Timestamp::getDateWithOffset( $comment->getDate(), 0 );

反而就正常了, 不知道這部份有沒有問題??
頁: 1 [2] 3