盧姵穎學習Bro Code製作計算機

盧姵穎學習Bro code製作計算機

https://www.youtube.com/watch?v=I5kj-YsmWjM

Build this JS calculator in 15 minutes!

心得與考試重點

  1. LIST條列, UL=UNORDERED LIST, OL=ORDERED LIST, BUTTON按鈕, CLICK按下, ONCLICK事件
  2. 網頁的命令,大小寫都可以
  3. <button onvlick="cleardisplay()">刪</button>
  4. SCRIPT區段有三個自訂的函數
    1. function appendToDisplay(input) { const display = document.getElementById("display"); display.value += input;}
    2. function clearDisplay() { const display = document.getElementById("display"); display.value = "";}
    3. function calculate() { const display = document.getElementById("display"); try{ display.value = eval(display.value); } catch(error){display.value = "Error";} }
  5. 在style區段定義.my{background-color: blue;}可以用在網頁的class='my'元件 徘徊
  6. css上製造滑鼠在上面就會改變樣式hover同義字excurse,hesitate,hover,linger,potter,roam
  7. button:hover滑鼠在上面, button:active按下滑鼠

留言

這個網誌中的熱門文章

甲班盧姵穎PYTHON繪製三角函數與powerpoint製作影片

盧姵穎二分法求內部報酬率