CentOS 6 最小安裝之後,沒有 scp 可以使用,
所以當用 pietty (putty) 傳檔案時,
會出現 scp not connection 的錯誤。
# yum install openssh-clients
CentOS 6 最小安裝之後,沒有 scp 可以使用,
所以當用 pietty (putty) 傳檔案時,
會出現 scp not connection 的錯誤。
# yum install openssh-clients
張貼於CentOS6 | 已加上的標籤 CentOS, linux | Leave a Comment »
“C:\Documents and Settings\Administrator\Local Settings\Application Data\Google\Chrome\Application\chrome.exe" –incognito
張貼於Uncategorized | 已加上的標籤 Chrome, 無痕模式 | Leave a Comment »
Fedora 想要在開機之後會自動用某個帳號登入,
# vi /etc/slim.conf
default_user username
auto_login yes
張貼於Fedora, Linux系統 | 已加上的標籤 Auto login, Fedora, LXDE | Leave a Comment »
當使用者端連進來時,
由 index.php 負責判斷時間,
當上一個連線與這一個連線時間小於 600 秒,
就讀取 index2.htm ,
如果上一個連線與這一個連線時間已超過 600 秒,
就會乎叫 get.php ,
重新將 RSS 的網頁讀取進來,
並寫到 index2.htm 裡面去,
供下一次 600 秒內的使用者閱讀。
目的:避免在短時間有大量的 PHP 處理程序將資源吃光。
index.php
<?php
$t=time();
$fp = fopen(‘timestamp.txt’, ‘r’);
$datatime=fgets($fp,12);
$t2=$t-$datatime;if ($t2<600){include(“index2.htm");
} else {
include(“get.php");
}
?>
get.php
<?php
$siteurl = “http://samba.tw/rss.php";
$content = file_get_contents($siteurl);
echo $content;$fp2 = fopen(‘index2.htm’, ‘w’);
fwrite($fp2,$content);
fclose($fp2);$t=time();
$fp = fopen(‘timestamp.txt’, ‘w’);
fwrite($fp,$t);
fclose($fp);
?>
index2.htm (空白檔案即可,注意要有寫入的權限)
timestamp.txt(空白檔案即可,注意要有寫入的權限)
張貼於php | Leave a Comment »
如果無法用 telnet 連進 ptt.cc 進行 BBS 的操作~
可以選用網頁方式進行瀏覽
http://www.ptt.cc/bbs/index.html
雖然沒有 BBS 那麼多功能,
但是簡易的閱讀也可以止一下渴啦!
http://www.linuxplanet.com/linuxplanet/reports/7153/1
張貼於Linux系統, NAS | 已加上的標籤 Free, linux, NAS | Leave a Comment »
早期有些舊電腦的 BIOS 不支援從 USB 開機,
Plop 可以實現了!
下載 Plop 之後,
將 ISO 檔燒進光碟,
再將這片光碟放到主機光碟中,
主機會從光碟開機,
進入光碟開機之後,
就會有 USB 開機的選項了。
PS:另有 plpcfgbtGUI.exe 可以編輯 .bin 檔,修改開機選項設定。修改完記得用 UltraISO 之類的軟體,將 .bin 檔燒回 .ISO 檔內喔!
張貼於軟體介紹, Linux系統, 免費資源 | 已加上的標籤 CDrom, 開機, plop, usb | Leave a Comment »
在撰寫 PHP 程式時,
通常都是
<?php source_code; ?>
在 <? 後面要有 php 來宣告這是一段 PHP 語言,
但是人是懶惰的,
修改一下 /etc/php.ini 的
short_open_tag = On
就可以使用
<? source_code; ?>
不用再多打 php 了。
張貼於php | 已加上的標籤 短標籤, php, tag | Leave a Comment »
將以下文字,
存成 proxy.reg 的文字檔,
然後連續點兩下執行,
就可以直接啟用 proxy 了。
(PS: IP:port 請置換成您的資料)
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings]
"ProxyEnable"=dword:00000001
"ProxyServer"="IP:port"
"ProxyOverride"="<local>"[HKEY_USER\DEFAULT\Software\Microsoft\Windows\CurrentVersion\Internet Settings]
"ProxyEnable"=dword:00000001
"ProxyServer"="IP:port"
"ProxyOverride"="<local>"
如果要停用,
就換成以下內容:
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings]
"ProxyEnable"=dword:00000000
"ProxyOverride"="<local>"[HKEY_USER\DEFAULT\Software\Microsoft\Windows\CurrentVersion\Internet Settings]
"ProxyEnable"=dword:00000000
"ProxyOverride"="<local>"
張貼於proxy, Windows XP 相關 | 已加上的標籤 proxy, reg, registry | Leave a Comment »