HTML tutorial
CSS3 tutorial
Bootstrap tutorial
JavaScript tutorial
JQuery tutorial
AngularJS tutorial
React tutorial
NodeJS tutorial
PHP tutorial
Python tutorial
Python3 tutorial
Django tutorial
Linux tutorial
Docker tutorial
Ruby tutorial
Java tutorial
C tutorial
C ++ tutorial
Perl tutorial
JSP tutorial
Lua tutorial
Scala tutorial
Go tutorial
ASP.NET tutorial
C # tutorial
Border layout (border layout) offers five regions: east, west, north, south, center. Here are some common usages:
To apply the layout (layout), you should determine a layout (layout) container, and then define some areas. Layout (layout) must require at least a center region, the following is a layout (layout) Example:
<Div class = "easyui-layout" style = "width: 400px; height: 200px;"> <Div region = "west" split = "true" title = "Navigator" style = "width: 150px;"> <P style = "padding: 5px; margin: 0;"> Select language: </ p> <Ul> <Li> <a href="javascript:void(0)" onclick="showcontent('java')"> Java </a> </ li> <Li> <a href="javascript:void(0)" onclick="showcontent('cshape')"> C # </a> </ li> <Li> <a href="javascript:void(0)" onclick="showcontent('vb')"> VB </a> </ li> <Li> <a href="javascript:void(0)" onclick="showcontent('erlang')"> Erlang </a> </ li> </ Ul> </ Div> <Div id = "content" region = "center" title = "Language" style = "padding: 5px;"> </ Div> </ Div>
We create a <div> container with a border layout (border layout), layout (layout) of the container is cut into two parts, the left is the navigation menu on the right is the main content.
Finally, we write an onclick event handler to retrieve the data, 'showcontent' function is very simple:
function showcontent (language) { . $ ( '# Content') html ( 'Introduction to' + language + 'language'); }