web(cslai)

Findings and Notes in Web Development

Symlinking two Blogs

I am currently doing some organization to my blogs. Few weeks ago, after spending months struggling to work in Ubuntu 7.10, I learned about symbolic links. Then I thought this would be good for my project file management. Therefore I started to re-organize my project file structure to utilize symbolic links. One of the projects that uses symbolic link is the current wordpress theme.

Because I am writing two blogs in different languages, to reduce my work in maintaining to identical themes but in different languages, I have to make sure these two themes are in sync so that the appearance would not greatly differ (because most of the changes are done in the stylesheet files). But having to copy and paste the styles whenever I make changes to make sure both themes with identical appearance but different language is very tedious. Hence I added a symbolic link so that I do not have to copy and paste the stylesheets time. (however, I made some stupid mistakes while I was editing the theme files through openkomodo hence both themes are now in the same language, fixing)

Then I thought why don’t I use symbolic links so that I do not have to upload wordpress installation twice whenever there is an update to wordpress. Some may suggest switching to WPMU but I don’t think my problem needs to be solved using a WPMU installation. I have some experience in maintaining a WPMU and I know how troublesome it can be for a small blog like mine.

So now I am having two folders pointing to a single folder and a problem arises. How do I make them share a single wp-config.php file? My solution is to add a switch-case statement in the wp-config.php file to decide what configuration options to load depending on the host name. Another minor problem is with the permalink structure, currently i display post-id instead of post-title in my chinese blog, I have still no idea how to solve it, the worse case would be changing the permalink for this blog into the format used in my chinese blog.

No Comments

No comments so far.

Leave Message

Personal Details

Toggle Extra

© 如无特别著名,本站的所有著作权归作者Jeffrey04以署名-非商业性使用-相同方式共享许可证发布。

本网志是由Wordpress荣誉呈现,站点界面SimKite设计归设计者Jeffrey04所有。

由于本站采用即时刊登留言者的留言,所以无法也不能完全监察所有的留言,站长Jeffrey04保留删除和不删除留言之权力。欢迎网友发表具建设性,负责任兼且合法之言论,否则已经发现立即删除而不另行通知。倘若网友发现留言出现问题请留言提出,本站保留一切法律权力。