Caker, Web developer,Beijing,China.

My projects

jfalternative plugin of joomfish

syntax : {jfalternative}5|content|FRONTPAGE_NO_TRANSLATION_AVAILABLE{/jfalternative}

5 - content id
content  - table name
FRONTPAGE…. text

function :  display another translation of this content if you translate yet with current language …

Tags:

Filed under:default

Perl中正则表达式的特性

在Perl语言中,当正则式为空的时候,指的是前一次成功匹配的正则式。

Tags: ,

Filed under:default

How to remove ‘Welcome to the Frontpage’ title in Joomla! 1.5

If you install new Joomla! 1.5 on your server, you get the ‘Welcome to the Frontpage’ title on your Frontpage. Sometimes, it is difficult to find, where you can change this title.

Go to your Joomla! 1.5 Administration site and login. In your administration site go to:

  • Menus - Main Menu (now you are in: Menu Item Manager: mainmenu).
  • Click on ‘Home’ link to edit this link (you are now in: Menu Item: Edit).
  • Click on Parameters System and change or delete the Page title.
    • If you change the Page title, changed title will be displayed on your Frontpage as a title.
    • If you delete the Page title, Menu link will be displayed on your Frontpage as a title (in the present case ‘Home’ will be displayed as title, because ‘Home’ is the name of the link to the Frontpage).
    • If you don’t want to display any title, set Show Page Title below Page title parameter to ‘No’.
  • Don’t forget to save changes.

Tags:

Filed under:default

自动启动Oracle

http://www.oracle-base.com/articles/linux/AutomatingDatabaseStartupAndShutdownOnLinux.php

Tags: , , ,

Filed under:default

最近研究证实,成人每天睡眠5-7小时就能保证身体的健康。


Filed under:default

source,.命令

source, . 命令
在bash笔记第一部分中已经提到了source命令或.命令对脚本的执行方式与其他执行方式的不同指出: 在当前shell中运行, 影响当前shell的环境变量. 可以把”.”命令想象成C中的#include命令, 虽然它不直接将语句包含到脚本中, 但它会在当前shell中执行那些命令. 使用.命令可以将多个脚本合并起来, 整合进一些变量和函数.

Tags: ,

Filed under:default

Apache htpasswd命令的使用

htpasswd 命令是用来维护Apache HTTP Server基本验证口令文件的命令。可以用来完成如下功能:

1. 创建口令文件并增加用户: htpasswd -c passwordfile  username

2. 修改已存在的口令文件: htpasswd -b passwordfile username password

3. 显示结果(不带口令):htpasswd -n username

4. 显示结果(带口令): htpasswd -nb username

Tags:

Filed under:default

Apache基本验证用户认证的配置

           AuthType Basic
           AuthName “By Invitation Only” # 可选
           AuthBasicProvider file # 可选
           AuthUserFile /home/zzz/www/netmanager/passwdfile
           AuthGroupFile /home/zzz/www/netmanager/groupfile
           Require valid-user

Tags:

Filed under:default

解决ssh连接速度慢的问题

Debian默认设置下是开反向域名解析的。我们连接ssh/ftp的时候就会有一个比较明显的延时,大概要等30秒后才能输入账号密码。解决方法有两个:


1. 将客户机IP和域名对应关系加入到 /etc/hosts上

2. 编辑 /etc/nsswitch.conf
找到 hosts 那行,将其改成下面这样:
hosts: files dns [NOTFOUND=return]

Tags: , ,

Filed under:default

Linux中的波浪号替换

1. 单独的~ 或 /之前的~,用HOME环境变量的路径取代这个波浪号。

2. ~+, 用PWD变量的值取代这个波浪号。

3. ~-, 用OLDPWD变量的值取代这个波浪号。

4. ~一个单词, 如果这个单词是一个有效的用户名,则HOME变量的值取代’~一个单词’。

Tags: ,

Filed under:default