| getCellIndex() | ใช้คืนค่า index ของวันที่ที่กำหนด เมื่อเทียบกับ ปฏิทินใน Object Calendar |
|---|
method:getCellIndex ( date )
return type:Number
content:ใช้คืนค่า index ของวันที่ที่กำหนด เมื่อเทียบกับ ปฏิทินใน Object Calendar โดยจะคืนค่า -1 ในกรณีที่ไม่พบวันที่ที่กำหนดในหน้าปฏิทินปัจจุบัน
example:var config = { pagedate: "1/2009", mindate: "1/5/2009", maxdate: "1/15/2009" }; var calendar = new YAHOO.widget.Calendar ( "table", "container", config ); calendar.render ( ); alert ( calendar.getCellIndex ( "12/24/2009" ) );