Loading...

如何用javascript接收radio button被選取後的值

Temperature: 0 °C

ChungChung
author_tools

剛剛竟然犯了最簡單的錯誤~

而且還是在趕著時間的時候⊙_⊙

竟然蠢到用接收input 的方式去接收 checked radio value~

搞得一直鬼擋牆一樣,浪費了不少時間。

總之,正確的寫法如下

var radio_value = $("input[name='radio_name'][type='radio']:checked").val();

以上紀錄~
 

台北市內湖區江南街71巷75弄 Go

https://innstory.com/story-如何用javascript接收radio_button被選取後的值-1263
寫程式筆記

Prev
 兒子選得好但這得等你長大啊 ̄∇ ̄

Next
如何用javascript判斷字串中必須包含中英文 

Nearby Attractions

台北市內湖區江南街71巷75弄-Nearby Attractions

  • 臺灣廣播電臺放送亭 Go
  • 臺灣總督府鐵道部(臺北工場)... Go
  • 總督府山林課宿舍 Go
  • 延平基督教會 Go
  • 空軍總司令部(原台灣總督府工... Go
  • 清代機器局遺構 Go

About the Author

Chung

我是chung
網路工作者
主業是網站系統開發建置
副業是做夢,寫故事
作品請參考/teme.biz
做夢請參考/innstory.com
聯絡/chung.teme@gmail.com

#有人用筆寫日記,有人用歲月寫日記,有人用照片寫日記,而我,用innstory寫日記。

Visitor message

Leave some footprints to prove that you visited me

Recommended reading

Author's other related stories

Apache無法執行.htaccess?

Apache無法執行.hta...

pexelsphoto5 首先.htaccess是在Apache HTTP Server服務器架設下...

使FCKeditor所上傳的圖檔檔名亂數化

使FCKeditor所上傳的...

編輯"../fckor/or/filemanager/connectors/php/com...

分享到各社群的方式

分享到各社群的方式

每次在寫網站系統時..客戶總會要求希望他們的網站可以有分享到社群網站的功能... 所以把一些常用的方...

Recommended reading

Other stories happened at this address

結婚4週年快樂

結婚4週年快樂

四年囉~明天月日是我們結婚整年...... 這一切感覺是那麼的奇妙,在網路上認識.... 第一次,妳...

為了與你相遇

為了與你相遇

image 為了與你相遇,溫馨感人的電影。 主要內容是在說一隻狗(貝利),歷經四次的狗輪迴,經歷過每...

消失的雞蛋...

消失的雞蛋...

為了煮飯給U,印象中我拿了一顆雞蛋~ 可我現在遍尋不到這顆雞蛋到底身在何處? 該不會哪天突然家裡多了...

這是~菠蘿麵包.....

這是~菠蘿麵包.....

我記得我買的是菠蘿麵包..... 怎麼被U吃過後,突然覺得這麵包很可憐啊~~~ 這傢伙只給我拔下那金...

想念太陽的溫度

想念太陽的溫度

做我這個行業的最怕沒有想法、沒有靈感。 我這幾天反覆地在修改一個要給客戶DEMO的版型~ 光是顏色就...

青椒炒肉絲佐高粱

青椒炒肉絲佐高粱

很簡單,卻也很下飯。 家裡買的沙茶也放了一陣子了,這晚就決定來盤沙茶口味的青椒炒肉絲。 其實我也不清...

Please select an option

error

Hi, thank you for your participation, but you cannot vote repeatedly~

Join innstory now and start recording your story.

"Innstory" is a place to store stories. We are committed to becoming a warm platform. Deepening the bonds between people is our direction.
We are convinced that the blockchain between people is not just a cold calculation. Join us now.

Wrong format