歡迎光臨, 訪客. 請先 登入註冊一個帳號.
五月 04, 2024, 01:11:20 上午
19595 文章 在 3865 主題 由 4580 會員
最新註冊會員: aa123aa1
  列出文章
頁: 1 2 [3] 4
31  支援 / 安裝與設定 / 請教在 DreamHost 使用簡短網址/自訂網址 於: 七月 01, 2005, 02:31:24 下午
也許你可以列出安裝時的設定,尤其是有關 session 的部分,讓大家參考一下。
32  支援 / 安裝與設定 / 請教在 DreamHost 使用簡短網址/自訂網址 於: 七月 01, 2005, 02:26:15 下午
建議發問前可以用搜尋以前的討論,說不定就有答案了。

請看看這個有沒有幫助:
http://forum.lifetype.org.tw/index.php?topic=565.0&highlight=session
33  開發 / 核心補強 / 聯結不到資料庫時如何轉向其他備份頁面 於: 六月 27, 2005, 02:49:40 下午
引用
這一個真的改的很棒。

Mark


感謝 Mark 鼓勵 微笑 其實還有很多是我需要努力的。:-P

WhiteCloud
34  開發 / 核心補強 / 聯結不到資料庫時如何轉向其他備份頁面 於: 六月 25, 2005, 11:38:33 上午
感謝 Mark 提供的資料,我使用 pLog 內建的物件來重寫備份程式。

程式變動:

改成呼叫 pLog 的 Article 類別物件

可設定網誌編號來備份不同 blog

取消顯示作者名

------------------------------------------------------------------------

<?php
    if (!defined( "PLOG_CLASS_PATH" )) {
        define( "PLOG_CLASS_PATH", dirname(__FILE__)."/");
    }

    include_once( PLOG_CLASS_PATH."config/config.properties.php" );
    include_once( PLOG_CLASS_PATH."class/dao/articles.class.php" );

// plog 的資料表字首
$strPlogPrefix = $config["db_prefix"];
// 輸出路徑,最後面要加斜線(目錄要設定為可讀寫,例如777)
$strArticleIndexPath = PLOG_CLASS_PATH;
// 輸出備份檔名
$strOutput = "article.htm";
// 網誌名稱
$strBlogName = "White Cloud's Blog";
// 網誌編號
$strBlogNumber = "1";



// 放文章的變數
$strFileContent = <<<EOT
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="zh_TW" lang="zh_TW" dir="ltr">
<head>
<title>$strBlogName</title>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
</head>

<body><center>
<font size=6 color=green>$strBlogName </font>
<br>這是備份頁面,歡迎存檔慢慢欣賞 :-)<br><br>
EOT;

//    $query = "SELECT * FROM plog_articles As a, plog_articles_text As at WHERE a.id=at.article_id AND a.blog_id = 1 ORDER BY a.date DESC";
   

$strTableArticleText = $strPlogPrefix."articles_text";
$strTableArticle = $strPlogPrefix."articles";
$strTableUsers = $strPlogPrefix."users";

$sql = "select * from $strTableArticleText,$strTableArticle where $strTableArticleText.article_id = $strTableArticle.id and $strTableArticle.blog_id = $strBlogNumber order by article_id desc";

    $articles = new Articles();
    $result = $articles->getBlogArticlesByQuery( $sql );  

foreach( $result as $article ) {

$strTopic = $article->getTopic();

$strText = $article->getText();

//$strAuthor = $article->getUser();

$strDate = $article->getDate();

// 由於改用 MySQL 4.1 的關係,取消此行
//$strDate = substr($strDate,0,4)."/".substr($strDate,4,2)."/".substr($strDate,6,2)." ".substr($strDate,8,2).":".substr($strDate,10,2).":".substr($strDate,12,2);

$strFileContent = $strFileContent.'<table width="80%" border="1"><tr><td>';
// $strFileContent = $strFileContent.$strArticleID;
// $strFileContent = $strFileContent."<br>";
$strFileContent = $strFileContent.'<font size=5><b>';
$strFileContent = $strFileContent.$strTopic;
$strFileContent = $strFileContent.'</b></font>';
$strFileContent = $strFileContent."<br>";
//$strFileContent = $strFileContent.$strAuthor;
//$strFileContent = $strFileContent." ";
$strFileContent = $strFileContent.$strDate;
$strFileContent = $strFileContent."<br><br>";
$strFileContent = $strFileContent.$strText;
$strFileContent = $strFileContent."<br><br>";
$strFileContent = $strFileContent."<td><tr><table><br><br>";

}

$strFileContent = $strFileContent = $strFileContent."All content copyright (c) 2004 $strBlogName";

$strFileContent = $strFileContent = $strFileContent."</center></body></html>";


// 輸出成為 HTML
//echo $strFileContent;
$fp = fopen($strArticleIndexPath.$strOutput, "w");
fputs($fp, $strFileContent);
fclose($fp);

header("Location: $strOutput");
//echo "OK";
?>
35  開發 / 核心補強 / Server 位在國外時修正日曆顯示問題 於: 六月 10, 2005, 11:52:33 上午
引用
這個問題已經在 1.0.2 的 branch 中修正了。還剩下一些小問題,相信 1.0.2 出來時應可全部修正。

Mark


非常感謝 Mark 和所有開發團隊的成員 微笑
36  支援 / 虛擬主機討論 / DreamHost 可裝 pLog,而且一年才 $9.24 美金 於: 六月 10, 2005, 11:47:14 上午
引用
evenrain :
引用
你看到的是什麼顏色呢?
我看到的字是白色的,底圖是藍色的。
理論上這跟瀏覽器的版本沒什麼關係,
會不會是你把背景圖片隱藏了?


謝謝你的提醒 微笑
我去看設定,把火狐的『工具->選項->網頁』裡面的『載入圖片』勾選,『只對原始網站』取消勾選就可以顯示背景圖了。

我看不清楚的原因就是底圖沒顯示。
37  開發 / 核心補強 / 聯結不到資料庫時如何轉向其他備份頁面 於: 六月 10, 2005, 11:29:21 上午
引用
WhiteCloud,你可以試用 pLog 的 API 來做 export 喔,我保證會更麻煩,但是你會學到不少喔。

你可以參考一下:
http://forums.lifetype.net/viewtopic.php?t=2421&highlight=articles
http://forums.lifetype.net/viewtopic.php?t=2264&highlight=articles

加油!

Mark


多謝 Mark 微笑
API 我還不熟,所以才會用最簡單的方法完成我要的東西。有範例可循太棒了,我就找個時間來練習 API 的使用,做出同樣功能 微笑
38  開發 / 核心補強 / Server 位在國外時修正日曆顯示問題 於: 六月 09, 2005, 03:15:37 下午
(重貼回來)
-----------------------------------------------------------------------------------
我記得改好月曆顯示問題的時候,看到月曆都沒變,還以為自己改錯地方了,後來發現應該是 cache 的關係。

今天上來看自己的網誌,發現日期竟然停留在前天,這回我決定把 cache 都關掉,就恢復正常了。

進入『全域站台控管->全域設定->模板設定』設定以下兩項:

template_cache_enabled 這個項目選『否』

template_http_cache_enabled 也選『否』

繼續再觀察一陣子看看。
------------------------------------------------------------------------------------

※ 因為關掉了 cache,Mark 之前有說明,對個人用的網誌影響較小。使用者多這樣做可能就不太合適了。
※ 依這方法改程式和設定 cache 後,大致可以正常顯示,但我發現還剩下一個問題,剛跨日時,日曆上的前一天,沒有顯示出連結,例如我在 6/7 23:59 貼了一篇文章,過幾分鐘後跨日,接著我去看日曆,照理說 6/7 應該出現連結,但是沒有,要過了一段時間才會出現連結,這可能系統有某個部分還需要修改。
39  支援 / 虛擬主機討論 / DreamHost 可裝 pLog,而且一年才 $9.24 美金 於: 六月 09, 2005, 03:03:11 下午
引用
呵呵
終於架好Plog囉!
不過....有哪位輩可以告訴我.....
我已將伺服器時間調整到跟本地時間同步了.. (+15Hr)
為何日曆的日期還是一樣未改變呢??


請先參考之前的討論串:
http://forum.lifetype.org.tw/index.php?topic=665.0

因為論壇有回溯過一次,我去把一篇設定 cache 的補上去...
40  支援 / 虛擬主機討論 / DreamHost 可裝 pLog,而且一年才 $9.24 美金 於: 六月 09, 2005, 02:54:11 下午
引用
引用
WhiteCloud 寫到:
DreamHost 的控制台用 FireFox 看會有問題,左邊的選單不清楚,我要找 MySQL 相關的地方找了半天都找不到,後來發現左邊選單字與背景顏色太接近了。

建議用 IE 來操作。


我也是用 Firefox 來操作 DreamHost 的後端,
沒有發生你說的問題耶 @_@a


我再去嘗試,結果真的不清楚,該不會是我的火狐沒更新? (1.0.2)
左邊這個部分的選單文字和選單底色很接近:
   Domains  
   Users  
   Mail  
   Goodies  
   Status  
   Support
41  支援 / 虛擬主機討論 / DreamHost 可裝 pLog,而且一年才 $9.24 美金 於: 六月 09, 2005, 03:24:59 上午
DreamHost 的控制台用 FireFox 看會有問題,左邊的選單不清楚,我要找 MySQL 相關的地方找了半天都找不到,後來發現左邊選單字與背景顏色太接近了。

建議用 IE 來操作。
42  開發 / 核心補強 / 聯結不到資料庫時如何轉向其他備份頁面 於: 六月 09, 2005, 01:31:07 上午
可以用這個做出『本站文章全部打包』的功能,讓網友可以存檔回去慢慢看。

此時,程式最後一行
header("Location: $strOutput");
如果改為
echo "OK";
這樣輸出後就不會轉向靜態頁面(這支程式由站長執行即可,其他網友只需要靜態頁面)。

然後在適當的模板中加入靜態 HTML 的超連結即可。
43  開發 / 外掛程式 / 使用 pLog 內建的 Calendar 顯示一年的月曆 於: 六月 07, 2005, 10:36:12 上午
這不是個外掛,但是使用 pLog 內建的功能就可以做出簡單的年曆了,這可以拿來做些簡單應用。

※ 貼在這裡不知道有無離開外掛主題 :P

程式如下(要放在安裝 pLog 的目錄下):

<?php

    if (!defined( "PLOG_CLASS_PATH" )) {
        define( "PLOG_CLASS_PATH", dirname(__FILE__)."/");
    }

    include_once( PLOG_CLASS_PATH."class/data/htmlcalendar.class.php" );
    $myCalendar = new Calendar;
    echo $myCalendar->getCurrentYearView();
?>
44  支援 / 虛擬主機討論 / DreamHost 可裝 pLog,而且一年才 $9.24 美金 於: 六月 06, 2005, 05:07:24 下午
太棒了,我也跑去訂了一個,感謝 neo 提供的訊息。你的網站提供了很多技術資訊,很值得看哦 微笑

我今天清晨就看到了這個消息,但是一直刷卡不成功,打電話去問信用卡公司,說根本沒有交易紀錄,要我去問那家公司。

不過下午我又試了一次就 OK 了。
45  開發 / 核心補強 / 聯結不到資料庫時如何轉向其他備份頁面 於: 六月 03, 2005, 12:17:23 下午
連不上 MySQL 找到原因了,還是 Google 大神幫的忙 吐舌頭

這是 Linux 的 glibc 需要升級!!

資料來源:
http://penguin.im.cyut.edu.tw/mysql/manual_Installing.html#Linux-RedHat51
頁: 1 2 [3] 4