<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>清晨迷雾</title>
	<atom:link href="http://www.vouov.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.vouov.com</link>
	<description>个人技术Blog</description>
	<lastBuildDate>Tue, 14 Aug 2012 00:56:58 +0000</lastBuildDate>
	<language>zh-CN</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.5.1</generator>
		<item>
		<title>Phonegap 2.0.0 Android使用笔记</title>
		<link>http://www.vouov.com/2012/08/phonegap-2-0-0-used-memo/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=phonegap-2-0-0-used-memo</link>
		<comments>http://www.vouov.com/2012/08/phonegap-2-0-0-used-memo/#comments</comments>
		<pubDate>Tue, 14 Aug 2012 00:56:58 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[移动开发]]></category>

		<guid isPermaLink="false">http://www.vouov.com/?p=161</guid>
		<description><![CDATA[最近使用Phonegap 2.0.0，有些Bug，也有些国内某些Android机型Html5方位不支持问题。  [...]]]></description>
				<content:encoded><![CDATA[<p>最近使用Phonegap 2.0.0，有些Bug，也有些国内某些Android机型Html5方位不支持问题。</p>
<p>1.定位支持全部Android全部机型修复</p>
<p>现象：如果调用navigator.geolocation.watchPosition和navigator.geolocation.getLocation，在某些国内Android信号GPS不能被调用。例如：在U880E不能调用GPS定位，但是在三星Galaxy Note可以调用定位</p>
<p>解决方案：修改/assets/www/cordova-2.0.0.js 文件，修改后文件下载<a href="http://www.vouov.com/wp-content/uploads/2012/08/cordova-2.0.0.js">cordova-2.0.0.js</a></p>
<p>使用方法可以使用新的调用：cordova.geolocation.watchPosition和cordova.geolocation.getLocation</p>
<p>在行数678，添加代码如下</p>
<pre class="brush: javascript; gutter: true; first-line: 1; html-script: true">// file: lib/common/common.js
define("cordova/common", function(require, exports, module) {
module.exports = {
    objects: {
        cordova: {
            path: 'cordova',
            children: {
                exec: {
                    path: 'cordova/exec'
                },
                logger: {
                    path: 'cordova/plugin/logger'
                },
                //添加代码
                geolocation: {
                    path: 'cordova/plugin/geolocation'
                }
            }
        },
        Cordova: {
            children: {
                exec: {
                    path: 'cordova/exec'
                },
                //添加代码
                geolocation: {
                    path: 'cordova/plugin/geolocation'
                }
            }
        },
        PhoneGap:{
            children: {
                exec: {
                    path: 'cordova/exec'
                }
            }
        },
        navigator: {
            children: {
                notification: {
                    path: 'cordova/plugin/notification'
                },
                accelerometer: {
                    path: 'cordova/plugin/accelerometer'
                },
                battery: {
                    path: 'cordova/plugin/battery'
                },
                camera:{
                    path: 'cordova/plugin/Camera'
                },
                compass:{
                    path: 'cordova/plugin/compass'
                },
                contacts: {
                    path: 'cordova/plugin/contacts'
                },
                device:{
                    children:{
                        capture: {
                            path: 'cordova/plugin/capture'
                        }
                    }
                },
                geolocation: {
                    path: 'cordova/plugin/geolocation'
                },
                network: {
                    children: {
                        connection: {
                            path: 'cordova/plugin/network'
                        }
                    }
                },
                splashscreen: {
                    path: 'cordova/plugin/splashscreen'
                }
            }
        },
        Acceleration: {
            path: 'cordova/plugin/Acceleration'
        },
        Camera:{
            path: 'cordova/plugin/CameraConstants'
        },
        CameraPopoverOptions: {
            path: 'cordova/plugin/CameraPopoverOptions'
        },
        CaptureError: {
            path: 'cordova/plugin/CaptureError'
        },
        CaptureAudioOptions:{
            path: 'cordova/plugin/CaptureAudioOptions'
        },
        CaptureImageOptions: {
            path: 'cordova/plugin/CaptureImageOptions'
        },
        CaptureVideoOptions: {
            path: 'cordova/plugin/CaptureVideoOptions'
        },
        CompassHeading:{
            path: 'cordova/plugin/CompassHeading'
        },
        CompassError:{
            path: 'cordova/plugin/CompassError'
        },
        ConfigurationData: {
            path: 'cordova/plugin/ConfigurationData'
        },
        Connection: {
            path: 'cordova/plugin/Connection'
        },
        Contact: {
            path: 'cordova/plugin/Contact'
        },
        ContactAddress: {
            path: 'cordova/plugin/ContactAddress'
        },
        ContactError: {
            path: 'cordova/plugin/ContactError'
        },
        ContactField: {
            path: 'cordova/plugin/ContactField'
        },
        ContactFindOptions: {
            path: 'cordova/plugin/ContactFindOptions'
        },
        ContactName: {
            path: 'cordova/plugin/ContactName'
        },
        ContactOrganization: {
            path: 'cordova/plugin/ContactOrganization'
        },
        Coordinates: {
            path: 'cordova/plugin/Coordinates'
        },
        device: {
            path: 'cordova/plugin/device'
        },
        DirectoryEntry: {
            path: 'cordova/plugin/DirectoryEntry'
        },
        DirectoryReader: {
            path: 'cordova/plugin/DirectoryReader'
        },
        Entry: {
            path: 'cordova/plugin/Entry'
        },
        File: {
            path: 'cordova/plugin/File'
        },
        FileEntry: {
            path: 'cordova/plugin/FileEntry'
        },
        FileError: {
            path: 'cordova/plugin/FileError'
        },
        FileReader: {
            path: 'cordova/plugin/FileReader'
        },
        FileSystem: {
            path: 'cordova/plugin/FileSystem'
        },
        FileTransfer: {
            path: 'cordova/plugin/FileTransfer'
        },
        FileTransferError: {
            path: 'cordova/plugin/FileTransferError'
        },
        FileUploadOptions: {
            path: 'cordova/plugin/FileUploadOptions'
        },
        FileUploadResult: {
            path: 'cordova/plugin/FileUploadResult'
        },
        FileWriter: {
            path: 'cordova/plugin/FileWriter'
        },
        Flags: {
            path: 'cordova/plugin/Flags'
        },
        LocalFileSystem: {
            path: 'cordova/plugin/LocalFileSystem'
        },
        Media: {
            path: 'cordova/plugin/Media'
        },
        MediaError: {
            path: 'cordova/plugin/MediaError'
        },
        MediaFile: {
            path: 'cordova/plugin/MediaFile'
        },
        MediaFileData:{
            path: 'cordova/plugin/MediaFileData'
        },
        Metadata:{
            path: 'cordova/plugin/Metadata'
        },
        Position: {
            path: 'cordova/plugin/Position'
        },
        PositionError: {
            path: 'cordova/plugin/PositionError'
        },
        ProgressEvent: {
            path: 'cordova/plugin/ProgressEvent'
        },
        requestFileSystem:{
            path: 'cordova/plugin/requestFileSystem'
        },
        resolveLocalFileSystemURI:{
            path: 'cordova/plugin/resolveLocalFileSystemURI'
        }
    }
};

});</pre>
<p>2.基于1修改后定位Bug修复</p>
<p>现象：当你关闭GPS，然后在navigator.geolocation.watchPosition和navigator.geolocation.getLocation调用函数设置enableHighAccuracy:true时，程序会报错自动退出</p>
<p>解决方法：修改org.apache.cordova.GeoBroker源码73行，if ( (System.currentTimeMillis() &#8211; last.getTime()) &lt;= maximumAge) {</p>
<p>修改成：if (<span style="color: #ff0000;">last!=null &amp;&amp;</span> (System.currentTimeMillis() &#8211; last.getTime()) &lt;= maximumAge) {</p>
<p>如果类覆盖，编译打包时会报错，需要用压缩工具进入/libs/cordova-2.0.0.jar，然后删除对应包下的类class文件</p>
]]></content:encoded>
			<wfw:commentRss>http://www.vouov.com/2012/08/phonegap-2-0-0-used-memo/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>mysql经纬度坐标距离计算</title>
		<link>http://www.vouov.com/2011/04/mysql-compute-distance/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=mysql-compute-distance</link>
		<comments>http://www.vouov.com/2011/04/mysql-compute-distance/#comments</comments>
		<pubDate>Sat, 09 Apr 2011 05:57:56 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[mysql]]></category>

		<guid isPermaLink="false">http://www.vouov.com/?p=157</guid>
		<description><![CDATA[本文章主要解决数据库如果存有经纬度，获取一定距离的记录数 首先我们在mysql建立一个可重复使用的计算两个坐标 [...]]]></description>
				<content:encoded><![CDATA[<p>本文章主要解决数据库如果存有经纬度，获取一定距离的记录数</p>
<p>首先我们在mysql建立一个可重复使用的计算两个坐标经纬度的Function</p>
<pre class="brush: sql; title: ; notranslate">
DELIMITER $$

DROP FUNCTION IF EXISTS `MyDistance`$$

CREATE FUNCTION `MyDistance`(lat1 FLOAT, lng1 FLOAT, lat2 FLOAT, lng2 FLOAT)
	RETURNS  DOUBLE
BEGIN
	DECLARE  distance  DOUBLE;
     SET distance= 2 * 6378.137* ASIN(SQRT(POW(SIN(PI() * (lat1–lat2) / 360), 2) + COS(PI() * lat1 / 180)* COS(lat2* PI() / 180) * POW(SIN(PI() * (lng1–lng2) / 360), 2)));
	RETURN distance;

END$$

DELIMITER ;
</pre>
<p>接下来，就是运用这个function计算距离了。<br />
为了提高效率，在计算距离时首先通过经度和纬度过滤，然后再通过距离过滤，因为如果计算所有记录的距离毕竟不是很高效的做法。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.vouov.com/2011/04/mysql-compute-distance/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Ubuntu 10.10 server 实践–mysql安装</title>
		<link>http://www.vouov.com/2010/12/ubuntu-10-10-server%e2%80%93mysql/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=ubuntu-10-10-server%25e2%2580%2593mysql</link>
		<comments>http://www.vouov.com/2010/12/ubuntu-10-10-server%e2%80%93mysql/#comments</comments>
		<pubDate>Thu, 09 Dec 2010 17:36:00 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[其他]]></category>

		<guid isPermaLink="false">http://www.vouov.com/?p=155</guid>
		<description><![CDATA[今天开始用源码安装mysql，首先需要下载mysql的源码文件，然后解压，进入到解压后的目录 安装MySQL源 [...]]]></description>
				<content:encoded><![CDATA[<p>今天开始用源码安装mysql，首先需要下载mysql的源码文件，然后解压，进入到解压后的目录<br />
安装MySQL源码分发版的基本命令是：</p>
<pre class="brush: plain; title: ; notranslate">
shell&gt; groupadd mysql
shell&gt; useradd -g mysql mysql
shell&gt; gunzip &lt; mysql-VERSION.tar.gz | tar -xvf -
shell&gt; cd mysql-VERSION
shell&gt; ./configure --prefix=/usr/local/mysql
shell&gt; make
shell&gt; make install
shell&gt; cp support-files/my-medium.cnf /etc/my.cnf
shell&gt; cd /usr/local/mysql
shell&gt; bin/mysql_install_db --user=mysql
shell&gt; chown -R root  .
shell&gt; chown -R mysql var
shell&gt; chgrp -R mysql .
shell&gt; bin/mysqld_safe --user=mysql &amp;
</pre>
<p>mysql安装是依赖包ncurses，所以安装mysql前必须要要安装这个，否则会报错，大概信息是：<br />
<span style="color: #ff0000;">configure: error: No curses/termcap library found</span><br />
解决的办法就是到如下地址<a href="http://ftp.gnu.org/pub/gnu/ncurses/">http://ftp.gnu.org/pub/gnu/ncurses/</a>，选择最新源码，然后解压执行./configure, make , make install安装完毕，安装ncurses不要设置prefix参数，否则可能出现不能正确查找到的情况。</p>
<p><span style="color: #ff0000;">注意：在make时，需要很长的时间，我用了大概半个小时</span><br />
以下命令的工作目录都是基于/usr/local/mysql，请注意。<br />
启动命令：</p>
<pre class="brush: plain; title: ; notranslate">
sudo bin/mysqld_safe --user=mysql &amp;
</pre>
<p>停止命令：</p>
<pre class="brush: plain; title: ; notranslate">
sudo bin/mysqladmin shutdown
</pre>
<p>查看mysql版本：</p>
<pre class="brush: plain; title: ; notranslate">
sudo bin/mysqladmin version
</pre>
<p>查看mysql的状态：</p>
<pre class="brush: plain; title: ; notranslate">
sudo bin/mysqladmin pin
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.vouov.com/2010/12/ubuntu-10-10-server%e2%80%93mysql/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Ubuntu 10.10 server 实践–ftp proftp安装</title>
		<link>http://www.vouov.com/2010/12/ubuntu-10-10-server%e2%80%93ftp/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=ubuntu-10-10-server%25e2%2580%2593ftp</link>
		<comments>http://www.vouov.com/2010/12/ubuntu-10-10-server%e2%80%93ftp/#comments</comments>
		<pubDate>Wed, 08 Dec 2010 17:25:55 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[技术]]></category>
		<category><![CDATA[服务器技术]]></category>

		<guid isPermaLink="false">http://www.vouov.com/?p=148</guid>
		<description><![CDATA[今天晚上安装了ftp服务程序，我们选择proftp，首先源码下载到windows，网站http://www.p [...]]]></description>
				<content:encoded><![CDATA[<p>今天晚上安装了ftp服务程序，我们选择proftp，首先源码下载到windows，网站<a href="http://http://www.proftpd.org/">http://www.proftpd.org/</a>， 我下载的软件包为proftpd-1.3.3c.tar.gz，接下来通过昨天的方法,利用xshell把windows的源码包传到linux上，源码安装需要gcc支持，请确认系统已经安装gcc编译器，接下来具体操作步骤：</p>
<pre class="brush: plain; title: ; notranslate">
$sftp username@ip
$&gt;put local_file remote_dir  #(&gt; put D:proftpd-1.3.3c.tar.gz  /home/software/)
$&gt;quit
$ssh username@ip
$cd /home/software
$tar -xzvf /home/software/proftpd-1.3.3c.tar.gz -C /home/lib
$cd /home/lib/proftpd-1.3.3c
$sudo ./configure --prefix=/usr/local/proftp
$sudo make
$sudo make install
</pre>
<p>接下来修改/usr/local/proftp/etc/proftpd.conf</p>
<pre class="brush: plain; title: ; notranslate">
# This is a basic ProFTPD configuration file (rename it to
# 'proftpd.conf' for actual use.  It establishes a single server
# and a single anonymous login.  It assumes that you have a user/group
# &quot;nobody&quot; and &quot;ftp&quot; for normal operation and anon.

ServerName                      &quot;ProFTPD Default Installation&quot;
ServerType                      standalone
DefaultServer                   on

# Port 21 is the standard FTP port.
Port                            21

# Don't use IPv6 support by default.
UseIPv6                         off

# Umask 022 is a good standard umask to prevent new dirs and files
# from being group and world writable.
Umask                           022

# To prevent DoS attacks, set the maximum number of child processes
# to 30.  If you need to allow more than 30 concurrent connections
# at once, simply increase this value.  Note that this ONLY works
# in standalone mode, in inetd mode you should use an inetd server
# that allows you to limit maximum number of processes per service
# (such as xinetd).
MaxInstances                    30

# Set the user and group under which the server will run.
User                            nobody
Group                           nogroup

# To cause every FTP user to be &quot;jailed&quot; (chrooted) into their home
# directory, uncomment this line.
DefaultRoot ~

# Normally, we want files to be overwriteable.
AllowOverwrite          on
SystemLog   /usr/local/proftp/log/proftpd.log

# Bar use of SITE CHMOD by default
&lt;Limit SITE_CHMOD&gt;
  DenyAll
&lt;/Limit&gt;

# A basic anonymous configuration, no upload directories.  If you do not
# want anonymous users, simply delete this entire &lt;Anonymous&gt; section.
&lt;Anonymous ~ftp&gt;
  User                          ftp
  Group                         ftp

  # We want clients to be able to login with &quot;anonymous&quot; as well as &quot;ftp&quot;
  UserAlias                     anonymous ftp

  # Limit the maximum number of anonymous logins
  MaxClients                    10

  # We want 'welcome.msg' displayed at login, and '.message' displayed
  # in each newly chdired directory.
  DisplayLogin                  welcome.msg
  DisplayChdir                  .message

  # Limit WRITE everywhere in the anonymous chroot
  &lt;Limit WRITE&gt;
    DenyAll
  &lt;/Limit&gt;
&lt;/Anonymous&gt;
# user access config file path
AuthUserFile /usr/local/lib/proftp/etc/passwd
# change the auth file order
AuthOrder mod_auth_file.c mod_auth_unix.c
</pre>
<p>配置文件中我们已经配置权限验证通过文件方式。接下来我们参照<a href="http://www.proftpd.org/docs/contrib/ftpasswd.html">http://www.proftpd.org/docs/contrib/ftpasswd.html</a>来配置添加ftp用户。我们用到也就是</p>
<pre class="brush: plain; title: ; notranslate">ftpasswd --passwd --name=bob--uid=1001 --file=/usr/local/lib/proftp/etc/passwd --home=/home/bob --shell=/bin/false</pre>
<p>会提示你输入密码，输入密码后就会生成一个用户密码配置文件，路径如下： /usr/local/lib/proftp/etc/passwd，如果你不知道怎么获取uid,那么请用下面的命令查看，那个显示的数字就是了 </p>
<pre class="brush: plain; title: ; notranslate">
id nobody
</pre>
<p>现在如果你启动proftp可能出现总是登录不上的情况，解决办法就是在/etc/shells 添加一行 /bin/false</p>
<p>最后启动你的proftp，</p>
<pre class="brush: plain; title: ; notranslate">
$sudo /usr/local/lib/proftp/sbin/proftpd
</pre>
<p>那么整个ftp就成功了，如果发生错误请查看日志文件，路径我们配置文件中也配置了 /usr/local/proftp/log/proftpd.log<br />
如果是端口占用，请用下面命令查看是什么进程占用了</p>
<pre class="brush: plain; title: ; notranslate">
$sudo netstat -pant
</pre>
<p>查到占用21端口的进程，你可以kill，还可以更改配置文件的端口来解决这个问题。<br />
如果你的proftp不是系统service，怎么停掉呢，方法很简单</p>
<pre class="brush: plain; title: ; notranslate">
$ps aux|grep &quot;proftpd&quot;
$kill id
</pre>
<p>那个/usr/local/proftp/sbin/ftpshut 命令是不能完全停止进程的，会一直占用21端口，这种停止只能让ftp用户没有办法登录。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.vouov.com/2010/12/ubuntu-10-10-server%e2%80%93ftp/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Ubuntu 10.10 server 实践&#8211;简单介绍</title>
		<link>http://www.vouov.com/2010/12/ubuntu-10-10-server-practice-1/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=ubuntu-10-10-server-practice-1</link>
		<comments>http://www.vouov.com/2010/12/ubuntu-10-10-server-practice-1/#comments</comments>
		<pubDate>Tue, 07 Dec 2010 16:55:28 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[技术]]></category>
		<category><![CDATA[服务器技术]]></category>

		<guid isPermaLink="false">http://www.vouov.com/?p=139</guid>
		<description><![CDATA[以前搞过Linux server，但是因为工作开发比较忙，有很长一段时间没有练习了，很多东西开始淡忘，温故而知 [...]]]></description>
				<content:encoded><![CDATA[<p>以前搞过Linux server，但是因为工作开发比较忙，有很长一段时间没有练习了，很多东西开始淡忘，温故而知新，所以决定重新操作一边，随便做一下笔记，以便以后使用。</p>
<p>下载好iso文件，在windows下使用虚拟化软件<a href="http://www.virtualbox.org">virtualbox</a>(免费开源)安装Ubuntu Server.安装时到最后的软件选择时，因为要从头做起，不用系统做好的LAMP，Tomcat server软件包，如果用系统软件包，那就达不到练习的目的了。我只选择了OpenSSH server,因为要其他的机器传输文件到服务器上，必须有一个连接方式能够支持，那么ssh就是最好的方法。Ftp server 我们后面搭建，现在系统就只有ssh了。如果你通过网络的话也可以通过wdget来做，但是我不喜欢用server去下载东西。</p>
<p>接下来介绍一下SSH怎么传输文件，我的是从windows xp到Ubuntu server传输文件。windows下可以使用<a href="http://www.netsarang.com/products/xsh_detail.html">Xshell</a>命令终端软件，命令使用sftp.</p>
<pre class="brush: plain; title: ; notranslate">
&gt; sftp username@ip port
&gt; help
bye     finish your SFTP session
cd      change your remote working directory
clear   clear screen
exit     finish your SFTP session
explore explore your local directory
get     download a file from the server to your local machine
help    give help
lcd     change and/or print local working directory
lls      list contents of a local directory
lpwd    print your local working directory
ls      list contents of a remote directory
mkdir   create a directory on the remote server
mv      move or rename a file on the remote server
put     upload a file from your local machine to the server
pwd     print your remote working directory
quit    finish your SFTP session
rename  move or rename a file on the remote server
rm      delete a file
rmdir   remove a directory on the remote server
</pre>
<p>当然你也可以选择SCP命令作为你的传输命令：scp 命令是 SSH 中非常有用的命令，在两台服务器之间直接传送文件，仅仅用 scp 一个命令就完全解决了。 你可以在一台服务器上 以 root 身份运行 #scp servername:/home/ftp/pub/file1 . 这样就把另一台服务器上的文件 /home/ftp/pub/file1 直接传到本机器的当前目录下，当然你也可以用 #scp /tmp/file2 servername:/boot 把本机上的文件 /tmp/file2 送到另一台机器的 /boot 目录下。而且整个传送过程仍然是用 SSH 加密的。在windows下需要安装一个软件Winscp就可以了。</p>
<p>通过sftp传输文件到服务器上，是一个非常好的windows和linux通信的方法。当然你也可以用scp，如果是linux到linux推荐scp方法传输。</p>
<p>天很晚了。呵呵，困死了，睡觉了，今晚收工了。^_^</p>
]]></content:encoded>
			<wfw:commentRss>http://www.vouov.com/2010/12/ubuntu-10-10-server-practice-1/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>godaddy空间的magento安装支持</title>
		<link>http://www.vouov.com/2010/06/godaddy_hosting_support_magento/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=godaddy_hosting_support_magento</link>
		<comments>http://www.vouov.com/2010/06/godaddy_hosting_support_magento/#comments</comments>
		<pubDate>Thu, 03 Jun 2010 16:04:16 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[php]]></category>
		<category><![CDATA[电子商务]]></category>

		<guid isPermaLink="false">http://www.vouov.com/?p=114</guid>
		<description><![CDATA[今天在godaddy空间安装magento，跳转后页面空白，后来在google上搜索一了下，在国外的blog终 [...]]]></description>
				<content:encoded><![CDATA[<p>今天在godaddy空间安装magento，跳转后页面空白，后来在google上搜索一了下，在国外的blog终于找到解决方案，现在分享，希望帮助到你。</p>
<p>我的空间是linux的，php5.</p>
<p>修改你的php5.ini</p>
<div id="_mcePaste"><em><span style="color: #ff0000;">register_globals = on</span></em></div>
<div id="_mcePaste"><em><span style="color: #ff0000;">allow_url_fopen = on</span></em></div>
<div id="_mcePaste"><em><span style="color: #ff0000;">cgi.fix_pathinfo = 1</span></em></div>
<div></div>
<div>注意配置文件的这三项配置，设置完成了刷新你的页面，会有惊喜了。哈哈 ^_^</div>
]]></content:encoded>
			<wfw:commentRss>http://www.vouov.com/2010/06/godaddy_hosting_support_magento/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>magic toolbox 破解第一步之eval(function(p,a,c,k,e,d)系列解密javascript程序</title>
		<link>http://www.vouov.com/2009/12/magic-toolbox-%e7%a0%b4%e8%a7%a3%e7%ac%ac%e4%b8%80%e6%ad%a5%e4%b9%8bevalfunctionpacked%e7%b3%bb%e5%88%97%e8%a7%a3%e5%af%86javascript%e7%a8%8b%e5%ba%8f/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=magic-toolbox-%25e7%25a0%25b4%25e8%25a7%25a3%25e7%25ac%25ac%25e4%25b8%2580%25e6%25ad%25a5%25e4%25b9%258bevalfunctionpacked%25e7%25b3%25bb%25e5%2588%2597%25e8%25a7%25a3%25e5%25af%2586javascript%25e7%25a8%258b%25e5%25ba%258f</link>
		<comments>http://www.vouov.com/2009/12/magic-toolbox-%e7%a0%b4%e8%a7%a3%e7%ac%ac%e4%b8%80%e6%ad%a5%e4%b9%8bevalfunctionpacked%e7%b3%bb%e5%88%97%e8%a7%a3%e5%af%86javascript%e7%a8%8b%e5%ba%8f/#comments</comments>
		<pubDate>Thu, 24 Dec 2009 12:27:58 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[其他]]></category>

		<guid isPermaLink="false">http://www.vouov.com/?p=112</guid>
		<description><![CDATA[破解函数的代码是：]]></description>
				<content:encoded><![CDATA[<p>破解函数的代码是：</p>
<pre class="brush: jscript; title: ; notranslate">
&lt;script&gt;
a=62;
function encode() {
 var code = document.getElementById('code').value;
 code = code.replace(/[rn]+/g, '');
 code = code.replace(/'/g, &quot;\'&quot;);
 var tmp = code.match(/b(w+)b/g);
 tmp.sort();
 var dict = [];
 var i, t = '';
 for(var i=0; i&lt;tmp.length; i++) {
   if(tmp[i] != t) dict.push(t = tmp[i]);
 }
 var len = dict.length;
 var ch;
 for(i=0; i&lt;len; i++) {
   ch = num(i);
   code = code.replace(new RegExp('\b'+dict[i]+'\b','g'), ch);
   if(ch == dict[i]) dict[i] = '';
 }
 document.getElementById('code').value = &quot;eval(function(p,a,c,k,e,d){e=function(c){return(c&lt;a?'':e(parseInt(c/a)))+((c=c%a)&gt;35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--)d[e(c)]=k1||e(c);k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--)if(k1)p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k1[/c]);return p}(&quot;
   + &quot;'&quot;+code+&quot;',&quot;+a+&quot;,&quot;+len+&quot;,'&quot;+ dict.join('|')+&quot;'.split('|'),0,{}))&quot;;
}

function num(c) {
 return(c&lt;a?'':num(parseInt(c/a)))+((c=c%a)&gt;35?String.fromCharCode(c+29):c.toString(36));
}

function run() {
 eval(document.getElementById('code').value);
}

function decode() {
 var code = document.getElementById('code').value;
 code = code.replace(/^eval/, '');
 document.getElementById('code').value = eval(code);
}
&lt;/script&gt;
</pre>
<pre class="brush: xml; title: ; notranslate">
&lt;textarea id=code cols=80 rows=20&gt;

&lt;/textarea&gt;
 
&lt;input type=button onclick=encode() value=编码&gt;
&lt;input type=button onclick=run() value=执行&gt;
&lt;input type=button onclick=decode() value=解码&gt;
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.vouov.com/2009/12/magic-toolbox-%e7%a0%b4%e8%a7%a3%e7%ac%ac%e4%b8%80%e6%ad%a5%e4%b9%8bevalfunctionpacked%e7%b3%bb%e5%88%97%e8%a7%a3%e5%af%86javascript%e7%a8%8b%e5%ba%8f/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>godaddy主机升级zend到最新版本</title>
		<link>http://www.vouov.com/2009/12/godaddy%e4%b8%bb%e6%9c%ba%e5%8d%87%e7%ba%a7zend%e5%88%b0%e6%9c%80%e6%96%b0%e7%89%88%e6%9c%ac/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=godaddy%25e4%25b8%25bb%25e6%259c%25ba%25e5%258d%2587%25e7%25ba%25a7zend%25e5%2588%25b0%25e6%259c%2580%25e6%2596%25b0%25e7%2589%2588%25e6%259c%25ac</link>
		<comments>http://www.vouov.com/2009/12/godaddy%e4%b8%bb%e6%9c%ba%e5%8d%87%e7%ba%a7zend%e5%88%b0%e6%9c%80%e6%96%b0%e7%89%88%e6%9c%ac/#comments</comments>
		<pubDate>Tue, 22 Dec 2009 05:24:17 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://www.vouov.com/?p=104</guid>
		<description><![CDATA[今天，因为一个电子商务程序需要zend 3.3，所以把godaddy主机的zend升级一下，搞了好几个小时才搞 [...]]]></description>
				<content:encoded><![CDATA[<p>今天，因为一个电子商务程序需要zend 3.3，所以把godaddy主机的zend升级一下，搞了好几个小时才搞定，做个笔记</p>
<ol>
<li>下载ZendOptimizer 我的主机是linux的所以下载了最新的ZendOptimizer-3.3.9-linux-glibc23-i386</li>
<li>解压，我的php是5.2.6，拷贝ZendOptimizer-3.3.9-linux-glibc23-i386data5_2_x_compZendOptimizer.so，ftp上传至根目录下的zend目录</li>
<li>ftp打开空间，找到根目录下的php.ini，下载到本地备份，删除服务器上的php.ini，把本地php.ini重命名为php5.ini</li>
<li>编辑php5.ini,找到</li>
</ol>
<p>[Zend]<br />
zend_extension=/usr/local/zo/ZendExtensionManager.so<br />
zend_extension=/usr/local/zo/4_3/ZendOptimizer.so</p>
<p>修改为：</p>
<p>[Zend]<br />
zend_optimizer.optimization_level=15<br />
zend_extension=/home/content/XX/XXXXXXX/html/zend/ZendOptimizer.so</p>
<p>6.上传php5.ini至根目录,用&lt;?php phpinfo();?&gt;查看zend版本升级成功</p>
<p><span style="color: #ff0000;">注意：</span></p>
<p>zend_optimizer.optimization_level=15一定要设置，否则phpinfo的版本变成了3.3.9. 但是程序检测时还是不能使用</p>
]]></content:encoded>
			<wfw:commentRss>http://www.vouov.com/2009/12/godaddy%e4%b8%bb%e6%9c%ba%e5%8d%87%e7%ba%a7zend%e5%88%b0%e6%9c%80%e6%96%b0%e7%89%88%e6%9c%ac/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>php模板显示浏览器眉头有空行解决方法</title>
		<link>http://www.vouov.com/2009/11/php%e6%a8%a1%e6%9d%bf%e6%98%be%e7%a4%ba%e6%b5%8f%e8%a7%88%e5%99%a8%e7%9c%89%e5%a4%b4%e6%9c%89%e7%a9%ba%e8%a1%8c%e8%a7%a3%e5%86%b3%e6%96%b9%e6%b3%95/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=php%25e6%25a8%25a1%25e6%259d%25bf%25e6%2598%25be%25e7%25a4%25ba%25e6%25b5%258f%25e8%25a7%2588%25e5%2599%25a8%25e7%259c%2589%25e5%25a4%25b4%25e6%259c%2589%25e7%25a9%25ba%25e8%25a1%258c%25e8%25a7%25a3%25e5%2586%25b3%25e6%2596%25b9%25e6%25b3%2595</link>
		<comments>http://www.vouov.com/2009/11/php%e6%a8%a1%e6%9d%bf%e6%98%be%e7%a4%ba%e6%b5%8f%e8%a7%88%e5%99%a8%e7%9c%89%e5%a4%b4%e6%9c%89%e7%a9%ba%e8%a1%8c%e8%a7%a3%e5%86%b3%e6%96%b9%e6%b3%95/#comments</comments>
		<pubDate>Wed, 04 Nov 2009 03:38:26 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[php]]></category>
		<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://www.vouov.com/?p=100</guid>
		<description><![CDATA[最近在写php时，莫名其妙的浏览器头多出一行空行，在网上搜索一下，大致都是把文件保存为非BOM的UTF-8格式 [...]]]></description>
				<content:encoded><![CDATA[<p>最近在写php时，莫名其妙的浏览器头多出一行空行，在网上搜索一下，大致都是把文件保存为非BOM的UTF-8格式，在本地也解决了，但是上传到服务器依然有空行，搞了一个上午，都快崩溃了，最后决定自己想办法解决，经过几个小时的摸索终于有了完美解决方法了。</p>
<p>运用php显示缓冲区显示原理，成功去掉</p>
<p>在php的头上加一行<span style="color: #ff6600;">ob_start(); <span style="color: #000000;">然后再模板显示前加个<span style="color: #ff6600;">ob_end_clean(); </span>在模板显示后加个<span style="color: #ff6600;">ob_end_flush();</span></span></span></p>
<p><span style="color: #ff6600;"><span style="color: #000000;">这样问题就解决了，现在给出整体结构实例代码：</span></span></p>
<pre class="brush: php; title: ; notranslate">
&lt;?php

ob_start();

//此处为php逻辑操作

ob_end_clean();

//此处为php模板显示

ob_end_flush();

?&gt;
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.vouov.com/2009/11/php%e6%a8%a1%e6%9d%bf%e6%98%be%e7%a4%ba%e6%b5%8f%e8%a7%88%e5%99%a8%e7%9c%89%e5%a4%b4%e6%9c%89%e7%a9%ba%e8%a1%8c%e8%a7%a3%e5%86%b3%e6%96%b9%e6%b3%95/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Notice: Use of undefined constant</title>
		<link>http://www.vouov.com/2009/10/notice-use-of-undefined-constant/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=notice-use-of-undefined-constant</link>
		<comments>http://www.vouov.com/2009/10/notice-use-of-undefined-constant/#comments</comments>
		<pubDate>Fri, 16 Oct 2009 02:02:39 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[其他]]></category>

		<guid isPermaLink="false">http://www.vouov.com/?p=98</guid>
		<description><![CDATA[Notice: Use of undefined constant,一般是由于php的数组非数字索引没有加单引 [...]]]></description>
				<content:encoded><![CDATA[<p>Notice: Use of undefined constant,一般是由于php的数组非数字索引没有加单引号,解决的方法:修改php.ini的error_reporting，默认的报错级别是all，在配置文件中有个error_reporting = E_ALL &amp; ~E_NOTICE，其中~的意思就是排除，即报除了notice级别的所有错.另外也可以在页面顶部写error_reporting(E_All);可以在上线的程序中设置为error_reporting(E_ERROR | E_WARNING | E_PARSE);现在很多国产论坛里会出现此类错误.主要原因,他们之前在php4中开发,php 4 是支持不加引号的.php 5 不支持.所以出现了这种情况.那到底需不需要加引号呢.虽然php 5 也支持,但是我们建议加上单引号,不加单引号的效率是加上单引号的1/3,所以损失的是效率.那么不加单引号是怎么能工作的呢?过程大致如下,php解析变量,由于没有加引号又不是关键字,所以就认为是常量,而我们有没有定义常量,所以就抛出了notice提示.没有常量值,php自动输出此常量名为常量值.这样就和单引号有一样的功效了.但是在这期间进行多次转换和查找.所以性能损耗了.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.vouov.com/2009/10/notice-use-of-undefined-constant/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
