台灣深藍vBulletin技術論壇  

返回   台灣深藍vBulletin技術論壇 > 深藍官方整理發表區 > vBulletin 外掛深藍統整資源區 > 入口網頁 (Portal Software)

回覆
 
主題工具
舊 2007-07-20, 12:28 AM   #11
浩瀚星空站長
 
註冊日期: 2005-04-04
住址: http://www.hstar.idv.tw
文章: 504
發送 MSN 訊息給 yoching
預設

引用:
作者: Lilyandy 查看文章
啊@.@""
不知發生了什麼事.....
不過晚輩的確有與Nova前輩談論過某些事(不過倒忘了談啥了),
若晚輩有冒犯之處…還請a6859前輩見諒......@.@|||


不過~~有件事想請教一下.....
vBPortal 與 CMPS 是類似的東西嗎?
是否能夠共存?還是只能安裝其中一個?@.@?
算是類同的東西。
不過我比較喜歡用cmps就是了。開發簡單。
新的vBPortal還沒試過。之前他都會去修改核心資料庫的東西。讓我很頭痛。
__________________
請按這裡進入-->
你有vbb的問題嗎??
可在此尋求協助。
浩翰星空站長 yoching
yoching 目前離線   回覆時引用此篇文章
舊 2007-07-21, 05:52 AM   #12
Senior Member
 
註冊日期: 2005-05-13
住址: 無
文章: 156
預設

一下子已使用vbPortal 3年到期了.
剛好在到期前一天去挖到最新vbPortal Version 3.6.4
3.6.4 是用來對應 vBulletin 3.6.7 若是 3.6.7前面的版本就用vbPortal 3.6.3 版本

這回vbPortal 3.6.4 大幅度修改語言檔.
2個language文件夾內的語言檔全由一個vbportal-phrases.xml取代
vbPortal 已變成 vBulletin 的影子...

雖然我已將vbPortal 3.6.4 中文化約97%但有些用語很不順.
所以我先提供原文檔案給大家研究...
幫朋友架的論壇入口軟體就是用vbPortal 3.6.4
http://www.a8car.com/
上傳的附件
檔案類型: zip 3.6.4.zip (1.23 MB, 36 次查看)
a6859 目前離線   回覆時引用此篇文章
舊 2007-07-21, 03:41 PM   #13
Member
 
註冊日期: 2005-04-29
住址: 虛空論壇
文章: 36
預設

引用:
作者: a6859 查看文章
一下子已使用vbPortal 3年到期了.
剛好在到期前一天去挖到最新vbPortal Version 3.6.4
3.6.4 是用來對應 vBulletin 3.6.7 若是 3.6.7前面的版本就用vbPortal 3.6.3 版本

這回vbPortal 3.6.4 大幅度修改語言檔.
2個language文件夾內的語言檔全由一個vbportal-phrases.xml取代
vbPortal 已變成 vBulletin 的影子...

雖然我已將vbPortal 3.6.4 中文化約97%但有些用語很不順.
所以我先提供原文檔案給大家研究...
幫朋友架的論壇入口軟體就是用vbPortal 3.6.4
http://www.a8car.com/
我就是想知道photopost與VBPortal是怎麼整合的,或者說區塊部分是如何去增加的。
__________________
不知道為什麼,我很喜歡黑夜,
我總是喜歡在夜裡想事情......
喜歡喝著酒,或許感慨,或許無奈.......
可能拿著吉他,彈著我們喜歡的歌,
唱給那個曾經甜蜜現在卻已遙不可及的人.........
-- By 台北 -- 阿修羅
阿修羅 目前離線   回覆時引用此篇文章
舊 2007-07-21, 05:15 PM   #14
Senior Member
 
註冊日期: 2005-05-13
住址: 無
文章: 156
預設

引用:
作者: 阿修羅 查看文章
我就是想知道photopost與VBPortal是怎麼整合的,或者說區塊部分是如何去增加的。
哈..老弟我也是隨著你的VBPortal中文化一直演變至今.你算是我的老師啦...


photopost 與 VBPortal 整合方式


區塊管理 >> 預設中央區塊 >> 增加新的區塊
增加新的區塊 (設置內文)
區塊類型 php
標題 虛空像簿
顯示順序 0
模板
限制結果 0

自訂碼 (如下)


//$link = mysql_connect ("localhost", "$dbuserid", "$dbuserpassword") or die('I cannot connect to the database.');
//mysql_select_db ("pp_database")or die("Could not select photopost database");
$forumpath = "/主機姐對路徑/forums"; (如 /home/aeigcarc/public_html/forums)
$photopath = "/主機姐對路徑/photopost"; (如 /home/aeigcarc/public_html/photopost)
$photourl = "http://虛空網址/photopost";
$forumurl = "http://虛空網址/forums";
$datapath = "http://虛空網址/photopost/data";
$ppprefix = "pp_"; (vb的前綴)

// 顯示相片數
$num_display = 8;
// 列數 (每一列顯示相片幾張)
$columns = 4;
// which type of images do you want to show (random, most_view, latest)
$q_switch = "random";
// == END CONFIGURATION ==
////////////////////////////////////////////////////////////////////////////
if ( !isset($ViewPerm) ) {
$mygroups = $bbuserinfo['usergroupid'];
if ( $bbuserinfo['membergroupids'] != "" ) $mygroups .= ",".$bbuserinfo['membergroupids'];
$grouparr = explode( ",", $mygroups );

$query = "SELECT id,ugnoview FROM {$ppprefix}categories";
$resultb = mysql_query($query);

$ViewPerm = array();
while ( list( $catugid, $ugnoview ) = mysql_fetch_row($resultb) ) {
$noview=0; $ViewPerm[$catugid] = 1;

$allnoview = explode( ",", $ugnoview );
foreach ($allnoview as $key) {
if (in_array($key, $grouparr) ) {
$noview=1;
}
}

if ( $noview == 0 ) {
$ViewPerm[$catugid]=0;
}
}
mysql_free_result( $resultb );
}
function pp_get_ext( $filename ) {
return substr($filename, strrpos($filename,"."));
}
function pp_is_image( $filename ) {
$retval = 0;
$mediatypes = array( ".jpg", ".gif", ".png", ".bmp" );
$ext = pp_get_ext( $filename );
if ( in_array(strtolower($ext), $mediatypes) )
$retval = 1;
return( $retval );
}
//
// Featured Photos Code
// Follow down to End Feature Photos Code
//
switch ($q_switch) {
case "most_view":
$query = "SELECT p.id,p.user,p.userid,p.cat,p.bigimage,p.height,p.width,c.catname,c.photos,c.posts
FROM {$ppprefix}photos p
LEFT JOIN {$ppprefix}categories c ON c.id = p.cat
WHERE c.cattype = 'c' AND p.storecat = 0 OR c.private = 'no'
ORDER BY views DESC";
break;

case "latest":
$query = "SELECT p.id,p.user,p.userid,p.cat,p.bigimage,p.height,p.width,c.catname,c.photos,c.posts
FROM {$ppprefix}photos p
LEFT JOIN {$ppprefix}categories c ON c.id = p.cat
WHERE c.cattype = 'c' AND p.storecat = 0 OR c.private = 'no'
ORDER BY date DESC";
break;

default:
$query = "SELECT p.id,p.user,p.userid,p.cat,p.bigimage,p.height,p.width,c.catname,c.photos,c.posts
FROM {$ppprefix}photos p
LEFT JOIN {$ppprefix}categories c ON c.id = p.cat
WHERE c.cattype = 'c' AND p.storecat = 0 OR c.private = 'no'
ORDER BY RAND()";
}
$result = mysql_query($query);
$counted = 0; $countcol = 0; $featured = "";
while (list($pid,$puser,$puserid,$pcat,$photo,$height,$width,$catname,$cphotos,$cposts) = mysql_fetch_row($result)) {

if ( pp_is_image($photo) ) {
$temp_user = $puserid;
$catname = stripslashes($catname);

if ( $height > $width )
$mthumb = "<img src=\"{$photourl}/images/overlay-roundp.gif\" height=\"96\" width=\"76\" border=\"0\" alt=\"\" />";
else
$mthumb = "<img src=\"{$photourl}/images/overlay-round.gif\" height=\"76\" width=\"96\" border=\"0\" alt=\"\" />";
// One box for each feature
$featured .= <<<PPPRINT
<td align="center" valign="top" class="alt2">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td style="background-repeat: no-repeat; background-position: center;" bgcolor="#222222" background="{$datapath}/{$pcat}/thumbs/$photo"><a href="{$photourl}/showphoto.php?photo={$pid}">$mthumb</a></td>
</tr>
</table>
<table border="0" style="border-collapse: collapse" width="100%">
<tr>
<td></td>
<td align="center" width="120">
<font size="1" face="verdana,arial">由 {$puser} 發表<br /></font>
</td>
</td>
<td></td>
</tr>
</table>
</td>
PPPRINT;
$counted++;
$countcol++;
}

// If we've reached our limit, quit
if ( $counted == $num_display ) break;

// If we need to end the column, do so.
if ( $countcol == $columns ) {
$featured .= <<<PPPRINT
</tr>
<tr>
PPPRINT;
$countcol = 0;
}
}
@mysql_free_result($result);
// Add on the ending tag
$featured .= "</tr>";
// First part is for the featured photos
// $photopostfeature not holds the Featured Photos box and $photopostcats (set below) holds the
// gallery list
$photopostfeature = <<<PPPRINT
<table cellpadding="0" cellspacing="0" border="0" width="100%" align="center">
<tr>
<td>
<table cellpadding="$stylevar[cellpadding]" cellspacing="1" border="0" width="100%">


$featured

</table>
</td>
</tr>
<tr><td colspan="3"><div class="blockfooter"><a href="/photopost/index.php" title="More Photos From The Gallery">更多像片...</a></div></td></tr>
</table>
PPPRINT;
echo "$photopostfeature";
mysql_select_db ("Data_base_name_");
a6859 目前離線   回覆時引用此篇文章
舊 2007-07-21, 07:15 PM   #15
Member
 
註冊日期: 2005-04-29
住址: 虛空論壇
文章: 36
預設

引用:
作者: a6859 查看文章
哈..老弟我也是隨著你的VBPortal中文化一直演變至今.你算是我的老師啦...
嘿嘿..........a6859老哥我成功咧~

不過照您的方式在我網站無法正常使用,所以我有稍微改了一下,因為我Photopost使用的資料庫是跟VBB是分離的,所以要另外抓Mysql連結~

在這邊順便說一下修改法,其實很簡單啦,把頭兩行的:
PHP 代碼:
//$link = mysql_connect ("localhost", "$dbuserid", "$dbuserpassword") or die('I cannot connect to the database.');
//mysql_select_db ("pp_database")or die("Could not select photopost database"); 
最前面的註解拿掉,應該就可以了,如果不行,那就把這兩個東東:
PHP 代碼:
$dbuserid
$dbuserpassword 
直接改成你的資料庫帳號與密碼就可以了(第一個帳號,第二個是密碼)。

什麼??還不行??

那麼把這一行:
PHP 代碼:
mysql_select_db ("pp_database")or die("Could not select photopost database"); 
其中的pp_database直接改成你Photopost使用的資料庫名稱就好啦。

※P.S:這個修改法我可以轉貼到虛空裡面嗎...............
__________________
不知道為什麼,我很喜歡黑夜,
我總是喜歡在夜裡想事情......
喜歡喝著酒,或許感慨,或許無奈.......
可能拿著吉他,彈著我們喜歡的歌,
唱給那個曾經甜蜜現在卻已遙不可及的人.........
-- By 台北 -- 阿修羅
阿修羅 目前離線   回覆時引用此篇文章
舊 2007-07-21, 07:40 PM   #16
Senior Member
 
註冊日期: 2005-05-13
住址: 無
文章: 156
預設

引用:
作者: 阿修羅 查看文章
嘿嘿..........a6859老哥我成功咧~

※P.S:這個修改法我可以轉貼到虛空裡面嗎...............
高手一出手便知有沒有..還是你行啦...
Photopost的資料庫原本就是獨立作業的
轉貼不敢當..最好由你出手做個整理再以阿修羅之名稱發表..
a6859 目前離線   回覆時引用此篇文章
舊 2007-07-22, 03:55 AM   #17
Member
 
註冊日期: 2005-04-29
住址: 虛空論壇
文章: 36
預設

引用:
作者: a6859 查看文章
高手一出手便知有沒有..還是你行啦...
Photopost的資料庫原本就是獨立作業的
轉貼不敢當..最好由你出手做個整理再以阿修羅之名稱發表..
感恩喔.........我已經貼過去了,還望您可以將您這一陣子以來所之對VBPortal的外掛改法全都分享出來~~~XXDD

有沒有將photopost區塊顯示在論壇首頁的修改法呢...............^^
__________________
不知道為什麼,我很喜歡黑夜,
我總是喜歡在夜裡想事情......
喜歡喝著酒,或許感慨,或許無奈.......
可能拿著吉他,彈著我們喜歡的歌,
唱給那個曾經甜蜜現在卻已遙不可及的人.........
-- By 台北 -- 阿修羅

此篇文章於 2007-07-22 03:59 AM 被 阿修羅 編輯.
阿修羅 目前離線   回覆時引用此篇文章
回覆

書籤

主題工具

發文規則
不可以發表新主題
不可以發表回覆
不可以上傳附件
不可以編輯自己的文章

啟用 BB 代碼
論壇啟用 表情符號
論壇啟用 [IMG] 代碼
論壇禁用 HTML 代碼
Trackbacks are 禁用
Pingbacks are 禁用
Refbacks are 禁用


所有時間均為北京時間。現在的時間是 07:04 AM


Powered by vBulletin® 版本 3.7.3
版權所有 ©2000 - 2008,Jelsoft Enterprises Ltd.
Ad Management by RedTyger