<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    隨筆-75  評論-193  文章-5  trackbacks-0
      2012年4月4日
    var fixgeometry = function() {
        /* Some orientation changes leave the scroll position at something
         * that isn't 0,0. This is annoying for user experience. */
        scroll(0, 0);
        /* Calculate the geometry that our content area should take */
        var header = $(".header:visible");
        var footer = $(".footer:visible");
        var content = $(".content:visible");
        var viewport_height = $(window).height();
        
        var content_height = viewport_height - header.outerHeight() - footer.outerHeight();
        
        /* Trim margin/border/padding height */
        content_height -= (content.outerHeight() - content.height());
        content.height(content_height);
      }; /* fixgeometry */
      $(document).ready(function() {
        $(window).bind("orientationchange resize pageshow", fixgeometry);
      });
    posted @ 2013-01-28 10:59 The Matrix 閱讀(5209) | 評論 (1)編輯 收藏
    http://java.dzone.com/articles/hibernate-tuning-queries-using?page=0,0 
    posted @ 2012-05-14 14:28 The Matrix 閱讀(1226) | 評論 (0)編輯 收藏
    環境:
        
        Centos6.2(安裝在Vmware7.0中)
        Magento1.6.2
        Apache Httpd Server 2.2.15
        MySql 5.1.61
        PHP5.3.3

    安裝過程:

        apache http、mysql、php及相關擴展安裝:
        其中apache http、Mysql、php都是利用centos的添加/刪除軟件功能進行安裝。同時使用該功能安裝"php-xml"、"php-gd"、"php-pdo"、"php-mbstring"、"php-mysql"擴展。
        使用chkconfig配置httpd和mysql為系統服務。命令如下:
        chkconfig httpd on
        chkconfig -add mysqld
        chkconfig mysqld on
        使用chkconfig --list 可以查看所有的服務配置狀態
        使用service httpd start、service mysqld start啟動httpd和mysqld服務。可以通過service httpd restart重啟相關服務。
        此時訪問本機的http://localhost可以看到apache的歡迎界面,同時編輯index.php文件,其內容如下:
        <?php
            phpinfo();
        ?>
        并將該文件置于/var/www/html目錄下,訪問http://localhost/index.php,此時應該不能看到php版本信息,僅能看到index.php的靜態文本內容。
        修改/etc/httpd/conf/httpd.conf文件,修改如下:
        DirectoryIndex index.html index.html.var ->  DirectoryIndex index.html index.htm index.php
        增加:
        AddType application/x-httpd-php .php
        AddDefaultCharset -> AddDefaultCharset off  (解決中文亂碼問題)
        增加一段VirtualHost描述,如下(在配置文件的最后):
        <VirtualHost *:80>
            DocumentRoot /var/www/smallfive
            ServerName smallfive
            ServerAlias smallfive.com *.smallfive.com
        </VirtualHost>
        此時訪問http://localhost/index.php,應該一切正常

        設置數據庫:
        使用mysqladmin -u root password 'newpassword'設置mysql數據庫的默認密碼
        讓數據庫更安全:
        mysql -u root -p    進入mysql
        mysql> DROP DATABASE test;                刪除test數據庫
        mysql> DELETE FROM mysql.user WHERE user = '';       刪除匿名帳戶
        mysql> FLUSH PRIVILEGES;                 重載權限
        創建magento數據庫
        mysql> CR   訪問magento數據庫,確保一切正常

        配置Magento:
        解壓縮magento1.6.2版本至/var/www/smallfive/magento目錄
        解壓命令:
       EATE DATABASE magento;
        mysql> GRANT ALL PRIVILEGES ON magento.* TO 'root'@'localhost' IDENTIFIED BY 'newpassword'; 
      tar zxvf magento1.6.2.tar.gz
        此時訪問http://localhost/magento,可根據magento的設置進行配置
       
        注意如下問題:
        1、確保當前用戶擁有對/var/www/smallfive/magento可讀可寫權限
        2、還需安裝mcrypt庫,安裝這個庫比較繁瑣,mcrypt依賴于Libmcrypt庫和mhash庫,我們需要下載Libmcrypt庫和mhash庫安裝它們,然后再編譯Mcrypt。
        在編譯之前,先做好如下準備工作:
            a、安裝phpize:yum -y install php-devel
            b、安裝C++腳本編譯模塊:
                yum -y install gcc gcc-g++
                yum -y install gcc gcc-c++
        安裝mcrypt庫過程,如下:
            a、下載libmcrypt和mhash庫
                Libmcrypt:http://sourceforge.net/project/showfiles.php?group_id=87941&package_id=91774&release_id=487459
                mhash:http://sourceforge.net/project/showfiles.php?group_id=4286&package_id=4300&release_id=645636
            b、將上述兩個下載后,分別解壓,并執行如下命令編譯:
                ./configure
                make && make install
            c、下載php對應的源代碼,解壓,
                進入php源代碼的 /ext/mcrypt目錄
                執行phpize命令
                ./configure –with-php-config=/usr/bin/php-config
                make && make install
            d、在php.ini文件中增加如下內容:
                extension=/usr/lib/php/modules/mcrypt.so
                mcrypt.so文件路徑在php-config文件中可以找到
            e、service httpd restart
       
        end!
         
        參考文章:
        http://www.eexu.com/article.asp?id=1730
        http://www.ruiwant.com/centos-6-0%E4%B8%8Bmagento%E7%8E%AF%E5%A2%83%E9%85%8D%E7%BD%AE%E6%80%BB%E7%BB%93.html
        http://zixun.www.net.cn/qita/2344.html
        http://os.qudong.com/Linux/2010/0210/64441.html
    posted @ 2012-04-04 17:09 The Matrix 閱讀(3141) | 評論 (1)編輯 收藏
    主站蜘蛛池模板: 中文亚洲成a人片在线观看| 免费看国产曰批40分钟| 9420免费高清在线视频| 亚洲AV无码一区二区三区在线观看| 亚洲人成网国产最新在线| 美女又黄又免费的视频| 在线观看视频免费国语| 亚洲色www永久网站| CAOPORN国产精品免费视频| 亚洲国产成人久久综合碰| 免费一区二区三区在线视频 | 日本亚洲精品色婷婷在线影院| 国产亚洲精品影视在线| 日韩精品成人无码专区免费| 国产精品亚洲四区在线观看| 欧洲美熟女乱又伦免费视频| 美女18毛片免费视频| 国产精品1024永久免费视频| 亚洲人6666成人观看| 成人毛片视频免费网站观看| 亚洲爆乳精品无码一区二区三区| 亚洲国产精品一区第二页| 国产激情免费视频在线观看| 天天摸天天操免费播放小视频| 亚洲国产精品美女久久久久| 亚洲国产精品激情在线观看| 免费无码一区二区三区蜜桃| 免费国产高清视频| 亚洲高清视频在线| 免费在线观看理论片| 国产午夜不卡AV免费| 亚洲欧洲国产综合| 国产免费观看黄AV片| 四虎影视无码永久免费| 亚洲欧洲校园自拍都市| 免费看国产一级片| 国内精品免费视频精选在线观看 | 久久亚洲熟女cc98cm| 日本牲交大片免费观看| 亚洲精品人成网线在线播放va| 一本久到久久亚洲综合|