tailieunhanh - javascript bible 4th edition jsb gold chapters phần 4

không gây đau đầu cho các tác giả trang có các kịch bản đã chạy trên nhiều trình duyệt càng tốt. Một tia hy vọng xuất hiện từ quá trình tiêu chuẩn của World Wide Web Consortium (W3C) trong các hình thức giới thiệu một mô hình đối tượng tài liệu (DOM). | Chapter 20 HTML Directive Objects CD-77 About this object The BASE element enables the page author to specify a default server directory and or link target for the entire page. If you omit the BASE element from the HTML browsers use the current page s path as the base URL and the current window or frame as the default target. Occasionally a page generated entirely by way of has difficulty establishing the same BASE URL as the document that generates the content particularly if the primary page is written out by a server script in Perl or in another language . Including a BASE tag in the dynamically written new page solves the problem the new page can fetch images or other external elements via relative URLs within the page. The two distinctive properties of the BASE element object are rarely scripted if ever. Properties href Value URL String Read Write NN2 NN3 NN4 NN6 IE3 J1 IE3 J2 IE4 IE5 Compatibility The href property is generally an absolute URL to the directory you wish to declare as the default directory for the page. Even though browsers automatically set the BASE HREF to the document s own directory this object and property do not have any values unless you explicitly set them in a BASE tag. In IE changing this property after a page loads causes the page to re-resolve all relative URLs on the page to the new BASE HREF. Therefore if images have relative URLs assigned to their src properties either by way of the tag attribute or script a change to the BASE element s href property forces the browser to look for those same relative URLs in the new directory. If the files aren t there then the images show up broken on the page. On the CD-R0M Example on the CD-ROM target Value String Read Write CD-78 Part III Document Objects Reference NN2 NN3 NN4 NN6 IE3 J1 IE3 J2 IE4 IE5 Compatibility The target property governs the default window or frame that is to receive any content coming from a server in response to a click on a link

TỪ KHÓA LIÊN QUAN