Google Adsense申请成功

May 19th, 2010 Bali No comments

终于,终于Google Ad sense申请获批,历时大约两年。并非要指望这个发家致富,是想看看这个东西到底怎么运作的,怎么防作弊。现在广告加在右侧边栏Tag Cloud下。

沈向洋同学的一次谈话中,非常推崇Google AdSense,确实是很精美的广告系统。不过号称现在点击率越来越低,而且作弊比较严重(尤其国内)。这让我想起今天看到的一则新闻,网购30天后悔权催生蹭买族 专家称时间不宜过长,广大人民群众的聪明才智啊,很大部分用到钻空子上去了。

商家怎么办?CPC越来越不行了。来用零风险的就是CPA吧。

Categories: Chinese - 中文 Tags: ,

关于网页的色彩

May 10th, 2010 Bali No comments

(代友贴文。由伊壁鸠鲁花园整理)

一个人拥有自己独特的风格,是一般人所没有的,就会让人注意到那个人的特别,若那个人的风格是正面的,甚至就会引起别人的羡慕与注意,或是赞赏。就如同一个网站,拥有别的网站所没有的风格,就会让浏览者愿意多停留些时间,细细品尝该站的内容,甚至该站会得到多人的鼓励与注目,粗略的说,网站风格可以从以下几个方向来探讨,而每一项都是有关联性的:

1. 色系:网页的底色、文字字型、图片的色系、颜色等等。

2. 排版:表格、框架的应用、文字缩排、段落等等。

3. 窗口:窗口效果,例如:全屏幕窗口、特效窗口等。

4. 程序:网页互动程序,例如:ASP . PHP . XML . CGI等等。

5. 特效:让网页看起来生动活泼的各种应用,如:Flash . Java script . Java applets . DHTML等等。

6. 架构:目录规划、层次浅显易懂、选单应用等等。

7. 内容:网站主题、整体实用性、文件关联性、内容切合度、是否有不必要的档案等等。

8. 走向:对于网站的未来规划、网站整体内容走向等。

以上这些项目都与网页风格有密切的关系,网页的风格不是某一项相同,网站就是有整体感,而是要各项目的配合应用,才能达到完美的网站风格设计。接下来的段落,将会为每个项目做简单的介绍。

一、色系

网站的色系是浏览者整体的视觉观感,若一个网站色系能有一致性,不仅会使网站看起来美观,更能让浏览者对内容不易混淆,增加了浏览的简洁与方便。而网站的色系更能衬托出网站的主题,若色系能与主题合理搭配,将会增加浏览者的易读性。

网站的色系包含了网页的底色、文字字型、图片的色系、颜色等等,这不单只是将颜色搭配得当就算完美,还要配合每个内容,及网站主题。对于网站的色系,应该要在网站开始制作前,做好规划及设计,才不会到着手制作网站时,难以搭配,甚至造成混乱的设计。

网页的底色是整个网站风格的重要指针。举例来说,以黑色作为背景颜色的网页,因黑色本对人的视觉上会造成黯淡的感觉,若是拿来用作活泼的儿童网站,就是不适合了。因为小孩子是天真无邪的、活泼的、有朝气的,与黑色的沉稳、黯淡,很难联想在一起。

再举个例子,若是写一个有关于环保的网站,若用暗红色作为网页底色,决计不会有人联想到网页的内容是与环保有关。当然,每个人的审美观不同,可能也会对颜色的代表性看法不同,但既然网站不是只写给自己看的,就应该要注意到大部分人可能会有的观点,然后以众人居多的观点出发,来设计网页。

文字字型上的设计,最好的网站是以所有浏览者都能看到的字型为主。常会看到有需多网站要求浏览者须自行下载某种字型,才能达到最佳浏览效果,这是种非常奇怪的行为。毕竟浏览者只是来找资料或是来看网站的内容,不可能会因为这种「为达最佳浏览效果」,而自行下载所需要的字型。

当所要求的字型若不下载,并不会影响到网站内容上的浏览与不便,那么对浏览者的要求就微乎其微的不可能发生任何作用。这么一来,对于网页设计者来说,无非是非常可惜的,因为当初的设计风格却未能让浏览者一窥全貌,岂不是白费心思的吗?

何谓图片的色系?以色彩学简单的区分,可分为冷色系与暖色系,再详细一点的区分,又可分出各种颜色的色系,而色系的区分,就在于主观浏览意识上的差异了。如何将图片的色系与网站整体色系相对应,就是比较困难的地方了。对于网页初学者来说,要绘制一张图并非易事,要绘制一张符合自己网页风格的图,更是困难重重。大部分的网页制作者,并不大可能驾轻就熟的使用影像处理软件或绘图软件,于是乎,网页素材的网站就开始盛行了。当然,不会使用绘图软件并不代表网页就不能设计的很出色,若是能将网络上的素材资源妥善利用,网站也是可以走出自己的风格的。而该怎么选择适合自己网站的图片,就是门很大的学问了。

选择图片该以何作为标准呢?举例来说,若网站内容为科学探讨,当然不能以卡通图片来作为插图,试想,当您正在浏览一个有关天文学的网站,却满是皮卡丘的可爱图片,不是很不协调吗?再举个例子,如果一个教学网站,里头却尽是明星图片,看上去根本就不像是教学网站,而是大杂汇的明星相片网。很多人喜欢将自己欣赏的明星照放上自己的网页中,如果仅是个人网站倒也还好,因为个人网站本就无主题居多,也就没有所谓的符不符合主题的顾虑,但若是有主题的网站,岂不糟糕?

以图片内容来说,能切合网站主题最好,若不能,也别差异太多。以颜色来说,若一个网页是蓝色的底色,但整个网页的图档却乱七八糟,各种颜色纷纷出笼,更糟的是,蓝色是属于冷色系的颜色,若以蓝色为底的网页,却尽都是大红色、橘色的图片,那将会使整张网页看起来就像垃圾堆,杂乱无章。所以,可以简单的归纳出,网页与图档的颜色,色系一致或是视觉效果一致,将会使网页看起来更为美观且有自己的风格。

Categories: Chinese - 中文 Tags: ,

少即是多

April 26th, 2010 Bali No comments

最近看到两则新闻。

一个是ThredUp:

“Where parents swap gently worn, second hand & used kids clothing online.” 简单来说就是,在线交换小孩子穿过的衣服的网站。因为,“Clothes Don’t Grow. Kids Do.”

ThredUp(Ex-ThredUp)本来也为成人交换体恤衫的:

You don’t wear 25% of the clothes in your closet. Join thredUp and start exchanging them for that you will.

另外一个是Groupon

Groupon features a daily deal on the best stuff to do, see, eat, and buy in a variety of cities across the United States.

让我们看看groupon的前身ThePoint是干嘛的:

The Point is a website for organizing group actions. Its goal is to help people congregate around the issues they care about and combine forces to make things happen.

他们的共同点:

1)都简单到用一句话可以描述。

2)都曾复杂过。

3)复杂时不愠不火,简单后反而迅速走红。

所以,少就是多。等少做到极致,再多也不迟。(而不是反过来,除非……)

Categories: Chinese - 中文 Tags:

给交大同学的讲座 – 2010年4月24日

April 25th, 2010 Bali No comments

有同学问我要讲义,在这里可以拿到:
http://libaocun.com/my-pm-talk-in-sjtu

这篇blog也作为一个交流平台吧。

另外:我们这个班级还有艺术类的学生,正好有这方面问题需要请教。请和我联系一下。

Categories: Chinese - 中文 Tags:

Fedora12 下配置 SVN 服务器

April 9th, 2010 lennydou No comments

assume the following dummy IP addresses and port of the server for the rest of the article: (replace these with your own IP, and port values)

  external IP: 55.444.444.55
  internal lan IP: 192.168.1.200
  svn port: 8080

Most of the operations here will require that you have access to the root account, as always.

I like to use the yum extender and an http gui to manipulate apache’s settings, so those need to be installed:

  > yum -y install yumex

This installs a gui for yum, which can be found, after a successful install on the desktop at:

  Applications > Yum Extender

Using the yum extender, we can see what has already been installed or not, on the linux machine. So, we should make sure that the Apache server is installed, and also install the Apache configuration tool (the http gui):

  httpd
  system-config-httpd

We also need to install the Apache server module for the subversion server:

  mod_dav_svn

Next, to install SVN subversion we can go back to the command line, and install it using yum:

  > yum install subversion

With these installations complete we can begin to create the necessary directories and modifying the various configuration files.

As root, create the following directory:

  > mkdir -p /var/www/svn/repository

change to that directory,

  > cd /var/www/svn/repository

and create a test repository,

  > svnadmin create test_svn

Notice: use svnadmin command maybe get an error: SQLite编译为3.6.20,但是运行于3.6.17。然后会发现repository目录下面并没有生成任何东西。此时需要在Yum Extender里面找到两个sqlite开头的包,然后升级这两个包就可以了。

Actually, these SVN directories can be placed anywhere, as long as you keep track of the correct path for the modifications that will need to be added later to the configuration files.

Next, change directory, and set the ownership so that Apache can access the SVN directories.

  > cd /var/www
  > chown -R apache.apache svn

Next, we modify Apache’s settings.

Before modifying Apache’s settings it would be a good idea to make a backup of the configuration file, in case the Apache server won’t restart, we can always restore the configuration file and try again.

  > cd   /etc/httpd/conf.d
  > cp  system-config-httpd.conf   system-config-httpd.conf.backup

Start the httpd configuration gui:

  > /usr/bin/system-config-httpd &

In this window set the server name to:
  192.168.1.200
Add to Available Addresses :

  listen to all addresses
  port: 8080

Then to save these settings, hit OK. These changes will modify the file:

  /etc/httpd/conf.d/system-config-httpd.conf

Restart the Apache server. There are operating system line commands for restarting the http daemon, but a GUI is just as easy, and we can keep the GUI open since we will need to restart Apache a few more times.

  /usr/bin/system-config-services &

Scroll down, select the daemon labeled httpd, and hit restart. Hopefully Apache restarts successfully, if not, then you may need to reload the original configuration file and try again.

Next, we will need to modify subversion’s configuration files.

To modify subversion’s configuration files we need to edit the following:

  /etc/httpd/conf.d/subversion.conf

This file was created with the installation of subversion.

The first two lines of the file should contain:

  LoadModule dav_svn_module modules/mod_dav_svn.so
  LoadModule authz_svn_module modules/mod_authz_svn.so

… if not, then those modules need to be installed.

First create a backup of the configuration file:

  > cp subversion.conf subversion.conf.backup

Modify the Location section of the file to the following:

  n  

Notice here how the directory for the repository we created earlier using the svnadmin command is not listed above. The above settings only point to the root location of the repository, or rather its parent path.

Save these settings, and restart the Apache server.

At this point we can test the SVN server from another PC on the private LAN. We can use our favorite web browser on a windows, linux, or mac PC, and enter the following URL:

  http://192.168.1.200:8080/svn/test_svn/

We should get a response page that looks like the following:

  Revision 0: /

  ————————————————————–
  Powered by Subversion version 1.4.4 (r25188).

If you can see this, then the SVN server is running.
Next, we need to add some password protection.

Here we add some password protection to the new SVN server.
For this, lets assume a username of trill, and a password of towel42.
Make the password directory:

  > mkdir /etc/httpd/passwd

To create the initial password file, and add a user called “trill”:

  > htpasswd -c /etc/httpd/passwd/svnpasswords trill

When the program asks, enter the password:

  towel42

Other command line options to htpasswd will allow you to add or delete more users.

For example, to add another user, called “asmith”:

  > htpasswd /etc/httpd/passwd/svnpasswords asmith

When the program asks, enter the password:

  neo22

This will append the user “asmith” to the passwords file, with the above password.

Edit the subversion configuration file to turn on the SVN authorization. We found that commenting out the <LimitExcept lines allowed the SVN password authorization to work. So the final subversion configuration file:

 /etc/httpd/conf.d/subversion.conf

… can look like this:
LoadModule dav_svn_module modules/mod_dav_svn.so
LoadModule authz_svn_module modules/mod_authz_svn.so

<Location /svn>
   DAV svn
   SVNParentPath /var/www/svn/repository
</Location>

<Location /svn>
   DAV svn
   SVNParentPath /var/www/svn/repository

   # Limit write permission to list of valid users.
   #<LimitExcept GET PROPFIND OPTIONS REPORT>
      # Require SSL connection for password protection.
      # SSLRequireSSL

      AuthType Basic
      AuthName “Authorization Realm”
      AuthUserFile /etc/httpd/passwd/svnpasswords
      Require valid-user
   #</LimitExcept>
</Location>

After having made these changes, restart the Apache server as above. Now, if we go back to the PC with the web browser, we can test the password authentication. Restart the web browser and enter into the URL:

  http://192.168.1.200:8080/svn/test_svn/

We should see a window pop up, prompting for a user’s name and a corresponding password.

Enter trill for the user name, and towel42 for the password. This should let us see the svn server’s response page as before.

Categories: English - 英文 Tags: ,