Time of Update: 2016-07-28
再安裝之前大家可以先看一下lamp的安裝過程http://blog.csdn.net/zph1234/article/details/512481241.安裝nginxyum install yum-priorities -y wget http://nginx.org/packages/centos/7/noarch/RPMS/nginx-release-centos-7-0.el7.ngx.noarch.rpm rpm -ivh nginx-release-centos-7-0.el7.
Time of Update: 2016-07-28
1.概述Cache-control用於控制HTTP緩衝(在HTTP/1.0中可能部分沒實現,僅僅實現了Pragma: no-cache)2.例子Cache-Control: cache-directivecache-directive可以為以下:request時用到:no-cacheno-storemax-age = delta-secondsmax-stale = delta-secondsmin-fresh =
Time of Update: 2016-07-28
1.概述IE使用Windows default locale 來決定Accept-Language 屬性。Windows default locale 可以通過Win32 API函數 GetUserDefaultLCID 來取得。另外,shell API 提供 GetAcceptLanguages 函數來取得IE的Accept-Language 。2.執行個體Accept-Language: zh-CN,fr-FR;q=0.5zh-CN 中文fr-FR 法語
Time of Update: 2016-07-28
php官方文檔 yield http://php.net/manual/zh/language.generators.overview.php參考:http://laravelacademy.org/post/4317.html產生器提供了一種更容易的方法來實現簡單的對象迭代,相比較定義類實現 Iterator 介面的方式,效能開銷和複雜性大大降低。產生器允許你在 foreach 代碼塊中寫代碼來迭代一組資料而不需要在記憶體中建立一個數組,
Time of Update: 2016-07-28
一、
Time of Update: 2016-07-28
phpMyAdmin訪問遠端資料庫編輯config.inc.php找到config.inc.php,編輯在後面添加A.訪問網址$cfg['PmaAbsoluteUri'] = '';這裡填寫phpmyadmin的訪問網址 B.mysql主機資訊$cfg['Servers'][$i]['host'] = 'localhost'; // MySQL hostname or IP address
Time of Update: 2016-07-28
1.安裝好linux,安裝好git(192.168.1.239)2.建立一個使用者zph(讓此使用者提供git on server),密碼設定為12345678# useradd zph# passwd zph3.切換到zph使用者 # su zph$ cd 4.建立一個遠程倉庫$ git init --bare sample.git5.在windows下(192.168.1.5),開啟git bash$ git clone zph@192.168.1.239:/home/zph/sample.
Time of Update: 2016-07-28
opti $this->options = array_filter($options) + $this->options; $this->ffmpeg=$ffmpeg;//ffmpeg路徑 $this->backup=$backup; } //擷取視頻資訊 function video_info($file) { ob_start(); passthru(sprintf($this->ffmpeg .
Time of Update: 2016-07-28
1.概述有的網站會在伺服器運行一段時間後down掉,有很多原因可能造成這種現象:比如tomcat堆和非堆記憶體設定不足,程式沒能釋放記憶體空間造成記憶體溢出,或者某些進程一直運行沒能釋放,造成cup資源大量消耗。但除了程式本身的原因,還有可能是客服端訪問造成(當然這個用戶端也包含如蜘蛛軟體等搜尋引擎),如果伺服器和用戶端建立的是長連結(可以用"netstat
Time of Update: 2016-07-28
一、資料庫簡介(1)資料庫是存放資料的倉庫,資料不是直接放到資料庫中,資料庫中放的是表,表中存放的才是資料;(2)資料庫的發展史萌芽階段——檔案系統:使用磁碟檔案來儲存資料;初級階段——第一代資料庫:出現了網狀模型、層次模型的資料庫;中級階段——第二代資料庫:關係型資料庫和結構化查詢語言
Time of Update: 2016-07-28
一、PHP簡介(1)PHP:中文名,超文本前置處理器,是一種通用開源指令碼語言;(2)Dreamweaver介紹(3)四種定界符標準風格:;短標記風格:;預設情況下,不支援短標記風格,要在PHP的設定檔中(php.ini)中開啟支援短標記;在設定檔中,搜尋
Time of Update: 2016-07-28
在Apache的設定檔httpd.conf中尋找LoadModule rewrite_module modules/mod_rewrite.soLoadModule vhost_alias_module modules/mod_vhost_alias.so去掉前面## Virtual hosts#Include conf/extra/httpd-vhosts.conf去掉第二行前面的#然後找到apache\conf\extra裡面的httpd-vhosts.conf檔案添加如下代碼
Time of Update: 2016-07-28
做為一名IT界摸爬滾打10餘年的老碼農,計劃啟動一個新聞訂閱類開源項目,目的有三:1.綜合運用近些年所學各種開發知識,提升自己;2.分享近些年所學各種開發知識,協助各位有所需要的程式員;3.做出一個實用項目,供普通使用者使用。--------------------------------------------------------------------------該項目將使用以下編程技術:c#(採集程式CrazeSpider)php(web前台,管理後台,app web
Time of Update: 2016-07-28
linter-php簡介linter-php是自動檢查php語法錯誤的外掛程式,使用起來非常方便。 linter-php配置進入linter-php的配置頁面,需要指定php執行檔案路徑: 因為ATOM提供的php外掛程式大多數都要配置php執行檔案路徑,因此建議可以將php執行檔案寫入系統內容變數: 或直接在配置項填寫php執行檔案路徑(不建議): ').addClass('pre-numbering').hide(); $(this).addClass(
Time of Update: 2016-07-28
主要思路實現ArrayAccess介面和__get,__set魔術方法classArrObjectimplementsArrayAccess {private$_data; publicfunction__construct($data){$this->_data = $data; } publicfunctionoffsetGet($offset){return ($this->offsetExists($offset) ? $this->_data[$offset] :
Time of Update: 2016-07-28
public function get_lt_rounder_corner($radius){ $img = imagecreatetruecolor($radius * 2, $radius * 2); // 建立一個正方形的映像$bgcolor = imagecolorallocate($img, 255, 255, 255); // 映像的背景$fgcolor = imagecolorallocate($img, 0, 0, 0); imagefill($img, 0,
Time of Update: 2016-07-28
雖然自己也是PHP的學習者,但之前還真沒怎麼瞭解PHP內部的記憶體回收流程,只是在我們的代碼中用了unset,null,mysql_close,__destruct等等一些函數去釋放對象防止記憶體溢出而已,所以上網GG下,找到了以下一些說明,作下記錄“PHP可以自動進行記憶體管理,清除不再需要的對象。PHP使用了引用計數(reference counting)這種單純的記憶體回收(garbage
Time of Update: 2016-07-28
1.在控制器介面載入use yii\web\UploadedFile;2.接收圖片並儲存在本地 $file = UploadedFile::getInstanceByName('photo'); //儲存路徑 $path = 'images/'; //判斷檔案是否存在 if(!file_exists($path)){ mkdir($path);
Time of Update: 2016-07-28
一 背景公眾號的開發介面,通常採用http請求,選用http/https協議,支援curl命令來get或者post資料;二 php函數cURL功能01 初始化cURL會話,返回控制代碼; resource curl_init ([ string $url = NULL ] ) 02 設定一個cURL傳輸選項; bool curl_setopt ( resource $ch , int $option , mixed $value )ex: curl_setopt($ch,CURLOPT_
Time of Update: 2016-07-28
composer簡介composer 是 PHP