วันศุกร์ที่ 11 มกราคม พ.ศ. 2551
Begin with JavaScript
Now I'm return to Web Applications again and this JavaScript for beginner (I'm already forget them).
Window.Open function ::
Exam.1 Block Code
script type="text/javascript" // Format in XHTML 1.0
funciton newWindow(id)
{
myWidow=window.open('myPage.aspx?id='+id, 'TitleName',
'height=100,width=400, toolbar=no, menubar=no, scrollbars=no, resizable=no,
location=no, directories=no, status=no');
myWindow.moveTo(0,0) // X, Y Postions
}
// Use JavaScript above :
a href="#" onclick="javascript: newWindow(Parameter)"
Exam 2. Inline Code
a href="#" onclick="window.open('ShowWallPaper.aspx?id=(Parameter)',
'WallPaper',
'top=0,resizable=yes,directories=no,scrollbars=yes,width=600,height=400')"
Try to understand about some features of Window.Open Method.
- yes,no = 1,0 (same meaning)
location : Address Bar.
resizable : Deny or allow user to resize new window.
status : Show the status bar on the bottom of window.
directories : The standard browser directory buttons, such as What's New and What's Cool ( I don't know that it shows where ?? )
And also it can support keyword "top=0" for hide menubar and menubar such as ::
myWidow=window.open('myPage.aspx?id='+id, 'TitleName','top=0');
I try to train English language. I think English language so hard for me :-\
สมัครสมาชิก:
ส่งความคิดเห็น (Atom)
ไม่มีความคิดเห็น:
แสดงความคิดเห็น