1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
\r
4 <meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
\r
5 <title>Rico LiveGrid sourced from HTML table</title>
\r
7 <!-- #INCLUDE FILE = "../../plugins/asp/LoadRicoClient.asp" -->
\r
10 set RicoClient = new LoadRicoClient
\r
11 RicoClient.SetRicoClientParentPath "../../ricoClient/"
\r
12 RicoClient.CheckQueryString ' just for demo
\r
13 RicoClient.CreateLinks
\r
14 set RicoClient = Nothing
\r
17 <link href="../demo.css" type="text/css" rel="stylesheet" />
\r
19 <script type='text/javascript'>
\r
20 Rico.onLoad( function() {
\r
21 //alert('We are stopping here, at the start of the onLoad event, to show you that the grid is populated with data from a regular HTML table. This is what browsers with javascript disabled would display.');
\r
23 menuEvent : 'click',
\r
25 highlightElem: 'cursorRow',
\r
27 useUnformattedColWidth: false,
\r
28 columnSpecs : [{width:200},'specQty','specQty','specQty','specQty','specQty']
\r
30 var ex1=new Rico.LiveGrid ('population', new Rico.Buffer.Base(document.getElementById('population').tBodies[0]), opts);
\r
31 ex1.menu=new Rico.GridMenu({});
\r
39 <div id='explanation'>
\r
41 <script type='text/javascript'>
\r
42 document.write(Rico.Lib+' '+Rico.LibVersion);
\r
45 This example demonstrates how Rico can convert an existing HTML table into
\r
46 a much more usable LiveGrid.
\r
47 LiveGrid provides scrolling, column resizing, filtering, and sorting capabilities.
\r
48 Click on a cell to see available actions.
\r
49 <p style='font-size:smaller;'>Data source: <a href="http://www.un.org/esa/population/unpop.htm">Population Division of the
\r
50 Department of Economic and Social Affairs of the United Nations Secretariat</a> (2009).
\r
51 <em>World Population Prospects: The 2008 Revision. Highlights.</em> New York: United Nations. </p>
\r
54 <p class="ricoBookmark"><span id="population_bookmark"> </span></p>
\r
55 <table class="ricoLiveGrid" id="population">
\r
58 <td class='ricoFrozen'></td>
\r
59 <td colspan=5>Population (thousands)</td>
\r
62 <td class='ricoFrozen'>Country or area</td>
\r
72 <td>Afghanistan</td>
\r
96 <td>American Samoa</td>
\r
128 <td>Antigua and Barbuda</td>
\r
176 <td>Azerbaijan</td>
\r
200 <td>Bangladesh</td>
\r
272 <td>Bosnia and Herzegovina</td>
\r
296 <td>British Virgin Islands</td>
\r
304 <td>Brunei Darussalam</td>
\r
320 <td>Burkina Faso</td>
\r
360 <td>Cape Verde</td>
\r
368 <td>Cayman Islands</td>
\r
376 <td>Central African Republic</td>
\r
392 <td>Channel Islands</td>
\r
416 <td>China, Hong Kong SAR</td>
\r
424 <td>China, Macao SAR</td>
\r
456 <td>Cook Islands</td>
\r
464 <td>Costa Rica</td>
\r
472 <td>Côte d'Ivoire</td>
\r
504 <td>Czech Republic</td>
\r
512 <td>Dem. People's Rep. of Korea</td>
\r
520 <td>Dem. Republic of the Congo</td>
\r
552 <td>Dominican Republic</td>
\r
576 <td>El Salvador</td>
\r
584 <td>Equatorial Guinea</td>
\r
616 <td>Faeroe Islands</td>
\r
624 <td>Falkland Islands (Malvinas)</td>
\r
656 <td>French Guiana</td>
\r
664 <td>French Polynesia</td>
\r
744 <td>Guadeloupe</td>
\r
776 <td>Guinea-Bissau</td>
\r
848 <td>Iran (Islamic Republic of)</td>
\r
872 <td>Isle of Man</td>
\r
920 <td>Kazakhstan</td>
\r
952 <td>Kyrgyzstan</td>
\r
960 <td>Lao People's Dem. Republic</td>
\r
1000 <td>Libyan Arab Jamahiriya</td>
\r
1008 <td>Liechtenstein</td>
\r
1016 <td>Lithuania</td>
\r
1024 <td>Luxembourg</td>
\r
1032 <td>Madagascar</td>
\r
1080 <td>Marshall Islands</td>
\r
1088 <td>Martinique</td>
\r
1096 <td>Mauritania</td>
\r
1104 <td>Mauritius</td>
\r
1128 <td>Micronesia (Fed. States of)</td>
\r
1136 <td>Moldova (Republic of)</td>
\r
1160 <td>Montenegro</td>
\r
1168 <td>Montserrat</td>
\r
1184 <td>Mozambique</td>
\r
1224 <td>Netherlands</td>
\r
1232 <td>Netherlands Antilles</td>
\r
1240 <td>New Caledonia</td>
\r
1248 <td>New Zealand</td>
\r
1256 <td>Nicaragua</td>
\r
1288 <td>Northern Mariana Islands</td>
\r
1304 <td>Occupied Palestinian Territory</td>
\r
1344 <td>Papua New Guinea</td>
\r
1368 <td>Philippines</td>
\r
1400 <td>Puerto Rico</td>
\r
1416 <td>Republic of Korea</td>
\r
1440 <td>Russian Federation</td>
\r
1456 <td>Saint Helena</td>
\r
1464 <td>Saint Kitts and Nevis</td>
\r
1472 <td>Saint Lucia</td>
\r
1480 <td>Saint Pierre and Miquelon</td>
\r
1488 <td>St. Vincent and the Grenadines</td>
\r
1504 <td>San Marino</td>
\r
1512 <td>Sao Tome and Principe</td>
\r
1520 <td>Saudi Arabia</td>
\r
1544 <td>Seychelles</td>
\r
1552 <td>Sierra Leone</td>
\r
1560 <td>Singapore</td>
\r
1584 <td>Solomon Islands</td>
\r
1600 <td>South Africa</td>
\r
1616 <td>Sri Lanka</td>
\r
1640 <td>Swaziland</td>
\r
1656 <td>Switzerland</td>
\r
1664 <td>Syrian Arab Republic</td>
\r
1672 <td>Tajikistan</td>
\r
1680 <td>TFYR Macedonia</td>
\r
1696 <td>Timor-Leste</td>
\r
1728 <td>Trinidad and Tobago</td>
\r
1752 <td>Turkmenistan</td>
\r
1760 <td>Turks and Caicos Islands</td>
\r
1792 <td>United Arab Emirates</td>
\r
1800 <td>United Kingdom</td>
\r
1808 <td>United Republic of Tanzania</td>
\r
1816 <td>United States of America</td>
\r
1824 <td>United States Virgin Islands</td>
\r
1840 <td>Uzbekistan</td>
\r
1856 <td>Venezuela (Bolivarian Republic of)</td>
\r
1872 <td>Wallis and Futuna Islands</td>
\r
1880 <td>Western Sahara</td>
\r