修正 WhereDidTheyGo plugin 在 WP 2.6 的錯誤訊息

更新到 Wordpress 2.6 之後, Where did they go from here 這個 plugin 就會跳 warning 出來.

warning: unserialize() expects parameter 1 to be string, array given in /home/xxxxxxxx/public_html/wp-content/plugins/wheredidtheygov1.php on line 97

參考其他 plugin 的解法是先用 is_serialized() 判斷, 如下修改即可

64,66c64
< if (is_serialized($linkpostids)) {
< $linkpostids = unserialize($linkpostids);
< }
---
> $linkpostids = unserialize($linkpostids);
99,101c97
< if (is_serialized($lpids)) {
< $lpids = unserialize($lpids);
< }
---
> $lpids = unserialize($lpids);

Posted in wordpress | Tagged , | Leave a comment

[筆記] VirtualBox 網路設定

記下我的 VirtualBox 網路設定

安裝

sudo apt-get install uml-utilities bridge-utils

/etc/network/interfaces

auto lo
iface lo inet loopback
name Loop interface
auto br0
iface br0 inet static
pre-up ifconfig eth0 down
post-up ifup eth0
address 192.168.22.2
network 192.168.22.0
netmask 255.255.255.0
broadcast 192.168.22.255
gateway 192.168.22.1
bridge_ports eth0
auto eth0
iface eth0 inet manual
name Ethernet LAN card

/etc/vbox/interfaces

#sudo VBoxAddIF vbox0 $USERNAME br0
vbox0 pctao br0

reboot, vbox0 is ready for you.

Posted in hardy, ubuntu | Tagged , , | Leave a comment

Ubuntu Hardy今天超大的地雷 - libc6更新失敗

使用發展中版本, 有可能遇到超大的問題, 今天的 ubuntu hardy 版本就是一例…

今天的 libc6 更新會導致無法執行程式, 無法執行更新/安裝套件的 dpkg 或 apt-get, 連 sudo / bash 也無法執行, 根本就是等死狀態 T_T

ubuntuforums 的討論, 有人貼出大概的暫時解法:
用 live cd 開機
掛載 disk
cp --parents `dpkg -L libc6-i686 | xargs` /path/to/mounted/disk/
cp --parents `dpkg -L libc6 | xargs` /path/to/mounted/disk/

相關資料

WARNING: BREAKAGE ALERT: Do Not Upgrade Libc6 (March 12, 2008)

Posted in hardy, ubuntu | Tagged , , | Leave a comment

JDK 6 update 4 無法下載

* 有可能看到這篇時, 已經可以下載了?

晚上在重灌電腦的 JDK , 到官網下載新版的 JDK 6 update 4 (之後簡稱JDK 6u4), 發現 windows 版本無法下載, 訊息一直是

Your download transaction cannot be approved. Contact Customer Service.

而 linux 或 solaris 版本則正常, 退而求其次, 找 JRE 6 update 4 , JDK 6u4 + NetBeans 也無法下載. 當下的疑問是, 政大或學網甚至台灣被擋住, 不能下載嗎?
老實說, 我想到了以前美國的密碼軟體和硬體的出口管制, 找了在美國的學長測試, 也是不行… 那我就放心了, 應該是sun官方的問題吧..
剛剛填了回報單, 看什麼時候會回覆正常..

Posted in java | Tagged , | Leave a comment

xorg glx module is missing in nvidia-glx-new 169.09

*update: 官方已解決此問題
更新 nvidia-glx-new 169.09+2.6.24.9-8.22 之後, xorg 的 glx extention 就載入失敗.

(II) LoadModule: “glx”
(II) Loading /usr/lib/xorg/modules//libglx.so
dlopen: /usr/lib/xorg/modules//libglx.so: cannot open shared object file: No such file or directory
(EE) Failed to load /usr/lib/xorg/modules//libglx.so
(II) UnloadModule: “glx”
(EE) Failed to load module “glx” (loader failed, 7)

主因是 libglx.so 連結錯誤, 因為 ubuntu hardy 還在 feature freeze , 暫時沒有更新, 所以先自行解決吧. Read More »

Posted in hardy, ubuntu | Tagged , , , , | Leave a comment

Ubuntu Hardy 進入 Feature Freeze 階段

* update: feature freeze 已結束

Ubuntu Hardy 有幾天沒有更新, 感覺奇怪就上 Ubuntu Forums 查. 原來是進入 feature freeze 的階段.

At this point we stop introducing new features, packages, and APIs, and concentrate on fixing bugs in the development release.

停止新功能,套件和API的更新, 而專注在解決問題.
Read More »

Posted in hardy, ubuntu | Tagged , | 1 Comment

[test] 再測試 WP2.4 svn 的發文功能

剛再更新 wp svn , 看到幾個 tinymce 的更新, 再來測試看看.

update: 在編輯器使用 HTML 模式, 會被吃文. 儲存前換成 Visual “應該“就沒事.
詳細更新紀錄如下 Read More »

Posted in test, wordpress | Tagged , | Leave a comment

[test] 測試 WP2.4 svn 的發文功能

上幾個禮拜看到大神在抱怨Wordpress 2.4 svn 版本有發文吃文的問題. 我手賤不小心也更新到有問題的板本… 大神downgrade到 2.3.2 就正常, 我 downgrade 則會無法登入, 只好繼續踩地雷…

如果是寫新文章, 那存檔的時候, 文字會被吃光光. 但如果用離線編輯器(像是 ScribeFire)先寫好, 送上wordpress當作草稿, 再到後台發佈, 文字就不會被吃光光..

剛剛又發現, 如果在後台寫了空白文章, 再用離線編輯器寫也是會被吃文, 所以這是第三次寫這篇文張了..

Posted in test, wordpress | Tagged , | 2 Comments

[ubuntu hardy] JAVA xcb_xlib error

升級到 hardy 之後, firefox 開有 java applet 的網頁, xcb_xlib 的舊問題又出現了

java_vm: xcb_xlib.c:82: xcb_xlib_unlock: Assertion `c->xlib.lock’ failed.
Could not read ack from child process
Plugin: Java VM process has died.
plugin: java process died due to signal 6

我是用 LIBXCB_ALLOW_SLOPPY_LOCK=1 的方法, 先暫時解決吧
在 ~/.xprofile 裡加上

export LIBXCB_ALLOW_SLOPPY_LOCK=1

下次登入 x window 時即可.

還一個方法不知道行不行的通, 修改libmawt.so s/XINERAMA/FAKEEXTN/ ,請參閱 HOWTO_Java_and_Firefox .

Posted in hardy, java, ubuntu | Tagged , , , , | Leave a comment

Aptana 安裝 Subclipse 後的錯誤訊息

安裝 Aptana 1.0.2 提供的 Subclipse 後, 使用 svn 功能會出現錯誤訊息

java.lang.ClassCastException: org.eclipse.team.internal.ui.wizards.ConfigureProjectWizard cannot be cast to org.tigris.subversion.subclipse.ui.wizards.sharing.SharingWizard

官方提供的是 1.2.2 , 去 Subclipse 官方安裝 1.2.4 就解決問題. 安裝方法請參考[這篇] .

Posted in eclipse, web design | Tagged , | Leave a comment