摘要:
let say we have a scene that after registered, we show a message to the web user, and then redirect the page to home page.usually, we use js to set as following:<scripttype="text/javascript">setTimeout('redirectPage',3);functionredirectPage(){window.location.href=''ht 阅读全文
摘要:
magento version: 1.5.1OS: CentOS 5.2Server: Apache 2.XMySQL: 5.XAfter i uploaded the code and installed magento, it seems that it is running well. But when i visit http://www.mywebsite.com/index.php/admin/catalog_product/index/key/cbe2b4d77f0b3b97de24c4a43443458e/ , i get this error:Couldnotdetermin 阅读全文
摘要:
When we using CGridView in Yii, we may want to a link as a column. So in common sense, we will use CLinkColumn to do that, as these code:<?php$this->widget('zii.widgets.grid.CGridView',array('dataProvider'=>$dataProvider,'columns'=>array(array('name'=>& 阅读全文
摘要:
As we know, Drupal7 has changed a lot, and we have to be familiar with it.Here is an example to theme a table with pager.$output='';$header=array(array('data'=>t('Title'),'field'=>'n.title',),array('data'=>'',),);$query=db_select(' 阅读全文
摘要:
look in the source of the d.o theme: <!DOCTYPEhtml><htmlxmlns="http://www.w3.org/1999/xhtml"xml:lang="en"lang="en"dir="ltr"><head><metahttp-equiv="Content-Type"content="text/html;charset=utf-8"/><metahttp-equiv=&q 阅读全文
摘要:
Yes, in fact that you can download the source package, and uninstall the firefox 3.6 in Ubuntu and then install the 4.0 version, but how about when you want to own 3.6 and 4.0 at the same time?Here is a way to do it.Add the source.sudoadd-apt-repositoryppa:ubuntu-mozilla-daily/ppaUpdate the sources. 阅读全文
摘要:
That is just an example, but do not use it to send the spam email la! :P#!/bin/bashcleari=1while(($i<10))do/usr/sbin/sendmail-v-t-oi-ftestla@testla.com<<EOFFrom:testla@testla.comTo:testla@testla.comSubject:AutomatedDeviceVerificationtest.EOFi=$(($i+1))done 阅读全文
摘要:
For example, i have there projects folders in/var/www/project_1/var/www/project_2/var/www/project_3In a common method, I have to set the virtualhost of the three projects as:<VirtualHost*:80><Directory"/var/www/project_1"></Directory>DocumentRoot"/var/www/project_1&q 阅读全文