目前分類:NetYea (126)

瀏覽方式: 標題列表 簡短摘要
在利用CSS的時辰,用某些殊效能讓網站更有活力,假如應用JQUERY又太甚複雜

不外今天作者看到某網站的運用不錯,於是就行使CSS也做了

可以看到下圖,滑鼠未移置圖片典範

利用CSS完成 游標移至圖片殊效
利用CSS完成 游標移至圖片殊效



用CSS寫下列代碼
 
  1. .chimga{
  2.     margin:10px;
  3.     width:100%;
  4.     height:100%;
  5.     box-sizing:border-box;
  6.     overflow:hidden;
  7.     display:block;
  8. }
  9. .chimga:hover img{
  10.     -moz-transform:scale(1.3) rotate(2deg);
  11.     -webkit-transform:scale(1.3) rotate(2deg);
  12.     -o-transform:scale(1.3) rotate(2deg);
  13.     -ms-transform:scale(1.3) rotate(2deg);
  14.     transform:scale(1.3) rotate(2deg);
  15. }
複製代碼
文章標籤

hallk6k22ej 發表在 痞客邦 留言(0) 人氣()

 

  1. int INA = 26;
  2. int INB = 27;
  3.  
  4. void setup()
  5. {
  6.   Serial.begin(9600);
  7.   pinMode(INA,OUTPUT);
  8.   pinMode(INB,OUTPUT);
  9.   //digital output test
  10.   Serial.println("INA=LOW,INB=HIGH");
  11.   digitalWrite(INA,LOW);
  12.   digitalWrite(INB,HIGH);
  13.   delay(3000);
  14.   Serial.println("INA=HIGH,INB=LOW");
  15.   digitalWrite(INA,HIGH);
  16.   digitalWrite(INB,LOW);
  17.   delay(3000);
  18.   Serial.println("INA=LOW,INB=LOW");
  19.   digitalWrite(INA,LOW);
  20.   digitalWrite(INB,LOW);
  21.   delay(3000);
  22.   Serial.println("INA=HIGH,INB=HIGH");
  23.   digitalWrite(INA,HIGH);
  24.   digitalWrite(INB,HIGH);
  25.   delay(3000);
  26.   //analog output(PWM) test  
  27.   ledcSetup(0, 5000, 8);
  28.   ledcSetup(1, 5000, 8);
  29.   ledcAttachPin(INA, 0);
  30.   ledcAttachPin(INB, 1);  
  31.   //prepare forward
  32.   Serial.println("INA=i++,INB=LOW");
  33.   ledcWrite(1, 0);
  34.   ledcWrite(0, 255);//避免電流太低沒法啟動
  35.   delay(300);
  36.   for (int i=80;i<=255;i++)
  37.   {
  38.     ledcWrite(0, i);
  39.     ledcWrite(1, 0);
  40.     Serial.println(i);
  41.     delay(100);
  42.   }
  43.   ledcWrite(0, 0);
  44.   ledcWrite(1, 0);
  45.   delay(3000);
  46.   //prepare reverse
  47.   Serial.println("INA=LOW,INB=i++");
  48.   ledcWrite(0, 0);
  49.   ledcWrite(1, 255);//避免電流太低沒法啟動
  50.   delay(300);
  51.   for (int i=80;i<=255;i++)
  52.   {
  53.     ledcWrite(1, i);
  54.     ledcWrite(0, 0);
  55.     Serial.println(i);
  56.     delay(100);
  57.   }
  58.   ledcWrite(0, 0);
  59.   ledcWrite(1, 0);
  60.     delay(3000);
  61. }
  62.  
  63. void loop()
  64. {
  65.  
  66.  
  67. }
文章標籤

hallk6k22ej 發表在 痞客邦 留言(0) 人氣()


文章出ˋ處: 網站架設NetYea 網頁設計

pip install pytube3 也能夠
升級模組

文章標籤

hallk6k22ej 發表在 痞客邦 留言(0) 人氣()



但是微軟正黑體有一個問題網站架設
safari瀏覽器有些次會錯位或無法顯示
所以在CSS BODY改成



在CSS內BODY插足

文章標籤

hallk6k22ej 發表在 痞客邦 留言(0) 人氣()

  1. baseurl = 'https://'+window.location.hostname;
複製代碼
文章標籤

hallk6k22ej 發表在 痞客邦 留言(0) 人氣()

網站架設比來因為CENTOS 7 辦事會莫名的封閉,查了發現是KENERL問題,所以決議升到CENTOS 8-9,

我的INTEL雙網網卡 來當作家裡的firewall, 於是安裝了CENTOS 8 - 9, 並用pppoe 來毗連中華電信的Router, 並且寫了一些iptables 的rules 來看成firewall 及NAT router.
然則覺得有問題, 有時連不出去. 現象是如許的:


但是在NAT 後面的電腦,GOOGLE PTT網站 連線都很ok, , 只要碰上yahoo跟遊戲 的連線, 就連不上, ftp 也ok.


這問題擺了很久都沒去理睬. 今天終於有空好好的來追問題的泉源. 發現彷佛是跟pppoe 有關.
問了小洲大大才發現

MTU
MTU (Maximum Transmission Unit) 是指網路介面卡上最大傳輸單位, 其單元為bytes. 在大大都的Ehternet 上, 這個值通常是1500. 因為如此, 在PPPoE 中, 因為還有header問題, 所以這個值就得設的比較小, 通常為1492 (= 1500 – 2(PPP)- 6(PPPoE))

MSS
MSS (Maximum segment size) 是TCP protocol 中的一個參數, 是指TCP 每次資料傳輸分段的最大值. 當TCP 在handshake 時, 雙方host 會查看MSS 這個欄位, 來決定兩邊資料傳輸分段的巨細. 在Ethernet 中MSS 值最大為1460 bytes.
緣由是在Ethernet 中 MTU = IP Header + TCP Header + MSS + FCS.
(FCS 是指Frame check sequence, 每每採用CRC演算法, 在Ethernet 中, 它佔4 bytes.)
可是在PPPoE 中MTU 為1492, 所以其MSS 只能設為1452.

問題所在
當CENTOS 8 在開機後, 啟動了ppp0, 其內定將MTU 設為1492, 而且會主動設定一條iptable rule,



因為在NAT 後面的電腦, 並不知道前真個router 是用什麼介面連到internet, 所以它和遠真個電腦創設TCP 連線時, 有可能會將MSS 設為1460. 可是由於firewall 或router 端利用PPPoE連線, 若MSS 大於1452會造成資料爆掉, 所以上述的iptable rule 強迫偷改其MSS值(在IPV4下 = PMTU – 40, 在IPV6下 = PMTU – 60). 是以MSS 就會被改成1452, 這樣子就不會爆掉了.

然則我本身寫的iptable rule script 中, 一入手下手就用了以下設定, 排除了本來的所有設定

 

  1. # 斷根所有規則
  2. iptables -F -t filter
  3. iptables -X -t filter
  4. iptables -Z -t filter
  5. iptables -F -t mangle
  6. iptables -X -t mangle
  7. iptables -Z -t mangle
  8. iptables -F -t nat
  9. iptables -X -t nat
  10. iptables -Z -t nat
文章標籤

hallk6k22ej 發表在 痞客邦 留言(0) 人氣()