lifetype 對使用者的帳號採取較嚴格的限制,僅允許 A-Z a-z 0-9 的字元做為帳號,如要增加字元範圍可修改:
class/data/validator/usernamevalidator.class.php
define( "ONLY_ALPHANUMERIC_REGEXP","^([A-Za-z0-9]*)$" );
利用 Web Editor 寫網誌
利用 Web Editor 寫網誌,參考網址
http://plog.yejh.tc.edu.tw/index.php?op=ViewArticle&articleId=426&blogId=1
修改 pLog 認證方式記事
plog 檔案中心的縮圖,如果無法正確產生,須修改 php.ini 的設定
php 預設的 memory limit 為 8M,
如果圖檔太大, 當 plog 呼叫 ImageCreateFromJPEG 時,會超過 8M ,造成錯誤
plog 在 class/gallery/resizers/gallerygdresizer.class.php 的縮圖處理, 將錯誤訊息隱藏 ,造成除錯的不易
$this->img["src"] = @ImageCreateFromJPEG ($imgfile);
修正方法: 將 /etc/php.ini 的 memory_limit = 8M 改大一些 如 memory_limit = 20M ,重新啟動 apache 即可解決!
讓 plog 也可以收big5 的rss
1. 自己動手加入一個函式
vi class/xml/rssitem.class.php
加入
|
2.將 下列的語法加入你的樣版中(以 free.tnc.edu.tw 為例)
| <div id="sectionHeader">free.tnc.edu.tw </div> <div id="sectionContent"> {if $rss->parse("http://free.tnc.edu.tw/backend.php")} {foreach from=$rss->getItems() item=rssItem} <a href="{$rssItem->getLink()}">{$rssItem->getBig5Title()}</a><br/> {/foreach} {else} <b>There was an error parsign the feed!</b> {/if} </div> |
plog 修正檔 templateview.class.php
plog 使用者上傳自己的模版後,無法以 op=Template 的方式使用自己的樣板
trace 了一下程式,找到 class/view/templateview.class.php 中少傳了一個值
修正檔下載 5-templateview.class.txt
|
/** * Renders the template */ function render() { $blogSettings = $this->_blogInfo->getSettings(); //少傳了$this->_blogInfo $template = $this->_templateService->Template( $this->_templateFile, $blogSettings->getValue( "template" ),$this->_blogInfo); $template->assign( $this->_params->getAsArray()); print( $template->fetch()); } } |