[修正] 有關 BBcodeBox 貼圖按鈕 [IMG] 等的一些狀況
發表於 : 2006-11-25 10:14
這是用來修正在發表文章時, 使用 BBCODE 語法的 img 貼圖按鈕按下去,並且打上圖片網址,按下確定後, 照理來說應該是游標在哪一行的哪一個位置時就應該是把語法貼在那邊, 但它卻不管三七二十一只會把貼圖的語法直接放到最後一行,也就是 貼到文章最後面, 這樣一來對打長篇報告的發文者就會產生困擾, 所以我們就來動手修正這個問題!!
參考來源: http://phpbb-tw.net/phpbb/viewtopic.php?t=44530
我整理出來 PLUS 1.5.3 有以下的部份要修正
#
#-----[ OPEN ]------------------------------------------
#
bbcode_box/add_bbcode.js
#
#-----[ FIND ]------------------------------------------
#
var ToAdd = "";
document.post.message.value+=ToAdd;
document.post.message.focus();
#
#-----[ REPLACE WITH ]------------------------------------------
#
var ToAdd = "";
PostWrite(ToAdd);
#
#-----[ OPEN ]------------------------------------------
#
bbcode_box/add_bbcode.js
#
#-----[ FIND ]------------------------------------------
#
var ToAdd = "[video width="+enterW+" height="+enterH+"]"+enterFURL+"[/video]";
document.post.message.value+=ToAdd;
document.post.message.focus();
#
#-----[ REPLACE WITH ]------------------------------------------
#
var ToAdd = "[video width="+enterW+" height="+enterH+"]"+enterFURL+"[/video]";
PostWrite(ToAdd);
#
#-----[ FIND ]------------------------------------------
#
var ToAdd = "[stream]"+enterURL+"[/stream]";
document.post.message.value+=ToAdd;
document.post.message.focus();
#
#-----[ REPLACE WITH ]------------------------------------------
#
var ToAdd = "[stream]"+enterURL+"[/stream]";
PostWrite(ToAdd);
#
#-----[ FIND ]------------------------------------------
#
var ToAdd = "[left]"+enterURL+"[/left]";
document.post.message.value+=ToAdd;
document.post.message.focus();
#
#-----[ REPLACE WITH ]------------------------------------------
#
var ToAdd = "[stream]"+enterURL+"[/stream]";
PostWrite(ToAdd);
#
#-----[ FIND ]------------------------------------------
#
var ToAdd = "[right]"+enterURL+"[/right]";
document.post.message.value+=ToAdd;
document.post.message.focus();
#
#-----[ REPLACE WITH ]------------------------------------------
#
var ToAdd = "[right]"+enterURL+"[/right]";
PostWrite(ToAdd);
#
#-----[ FIND ]------------------------------------------
#
var ToAdd = "[ram]"+enterURL+"[/ram]";
document.post.message.value+=ToAdd;
document.post.message.focus();
#
#-----[ REPLACE WITH ]------------------------------------------
#
var ToAdd = "[ram]"+enterURL+"[/ram]";
PostWrite(ToAdd);
存檔收工
參考來源: http://phpbb-tw.net/phpbb/viewtopic.php?t=44530
我整理出來 PLUS 1.5.3 有以下的部份要修正
#
#-----[ OPEN ]------------------------------------------
#
bbcode_box/add_bbcode.js
#
#-----[ FIND ]------------------------------------------
#
var ToAdd = "";
document.post.message.value+=ToAdd;
document.post.message.focus();
#
#-----[ REPLACE WITH ]------------------------------------------
#
var ToAdd = "";
PostWrite(ToAdd);
#
#-----[ OPEN ]------------------------------------------
#
bbcode_box/add_bbcode.js
#
#-----[ FIND ]------------------------------------------
#
var ToAdd = "[video width="+enterW+" height="+enterH+"]"+enterFURL+"[/video]";
document.post.message.value+=ToAdd;
document.post.message.focus();
#
#-----[ REPLACE WITH ]------------------------------------------
#
var ToAdd = "[video width="+enterW+" height="+enterH+"]"+enterFURL+"[/video]";
PostWrite(ToAdd);
#
#-----[ FIND ]------------------------------------------
#
var ToAdd = "[stream]"+enterURL+"[/stream]";
document.post.message.value+=ToAdd;
document.post.message.focus();
#
#-----[ REPLACE WITH ]------------------------------------------
#
var ToAdd = "[stream]"+enterURL+"[/stream]";
PostWrite(ToAdd);
#
#-----[ FIND ]------------------------------------------
#
var ToAdd = "[left]"+enterURL+"[/left]";
document.post.message.value+=ToAdd;
document.post.message.focus();
#
#-----[ REPLACE WITH ]------------------------------------------
#
var ToAdd = "[stream]"+enterURL+"[/stream]";
PostWrite(ToAdd);
#
#-----[ FIND ]------------------------------------------
#
var ToAdd = "[right]"+enterURL+"[/right]";
document.post.message.value+=ToAdd;
document.post.message.focus();
#
#-----[ REPLACE WITH ]------------------------------------------
#
var ToAdd = "[right]"+enterURL+"[/right]";
PostWrite(ToAdd);
#
#-----[ FIND ]------------------------------------------
#
var ToAdd = "[ram]"+enterURL+"[/ram]";
document.post.message.value+=ToAdd;
document.post.message.focus();
#
#-----[ REPLACE WITH ]------------------------------------------
#
var ToAdd = "[ram]"+enterURL+"[/ram]";
PostWrite(ToAdd);
存檔收工