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
8 require "LoadRicoClient.php";
\r
10 <link href="../demo.css" type="text/css" rel="stylesheet" />
\r
12 <script type='text/javascript'>
\r
13 Rico.loadModule('LiveGridBasic','LiveGridMenu');
\r
15 Rico.onLoad( function() {
\r
16 //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
18 menuEvent : 'click',
\r
20 highlightElem: 'cursorRow',
\r
22 useUnformattedColWidth: false,
\r
23 columnSpecs : [{width:200},'specQty','specQty','specQty','specQty','specQty']
\r
25 var ex1=new Rico.LiveGrid ('population', new Rico.Buffer.Base(document.getElementById('population').tBodies[0]), opts);
\r
26 ex1.menu=new Rico.GridMenu({});
\r
34 <table id='explanation' border='0' cellpadding='0' cellspacing='5' style='clear:both'><tr valign='top'><td>
\r
36 <script type='text/javascript'>
\r
37 document.write(Rico.Lib+' '+Rico.LibVersion);
\r
40 This example demonstrates how Rico can convert an existing HTML table into
\r
41 a much more usable LiveGrid.
\r
42 LiveGrid provides scrolling, column resizing, filtering, and sorting capabilities.
\r
43 Click on a cell to see available actions.
\r
44 <p style='font-size:smaller;'>Data source: <a href="http://www.un.org/esa/population/unpop.htm">Population Division of the
\r
45 Department of Economic and Social Affairs of the United Nations Secretariat</a> (2009).
\r
46 <em>World Population Prospects: The 2008 Revision. Highlights.</em> New York: United Nations. </p>
\r
49 <script type="text/javascript"><!--
\r
50 google_ad_client = "pub-7218597156507462";
\r
51 /* 125x125, created 5/11/09 */
\r
52 google_ad_slot = "9298106441";
\r
53 google_ad_width = 125;
\r
54 google_ad_height = 125;
\r
57 <script type="text/javascript"
\r
58 src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
\r
63 <p class="ricoBookmark"><span id="population_bookmark"> </span></p>
\r
64 <table class="ricoLiveGrid" id="population">
\r
67 <td class='ricoFrozen'></td>
\r
68 <td colspan=5>Population (thousands)</td>
\r
71 <td class='ricoFrozen'>Country or area</td>
\r
81 <td>Afghanistan</td>
\r
105 <td>American Samoa</td>
\r
137 <td>Antigua and Barbuda</td>
\r
185 <td>Azerbaijan</td>
\r
209 <td>Bangladesh</td>
\r
281 <td>Bosnia and Herzegovina</td>
\r
305 <td>British Virgin Islands</td>
\r
313 <td>Brunei Darussalam</td>
\r
329 <td>Burkina Faso</td>
\r
369 <td>Cape Verde</td>
\r
377 <td>Cayman Islands</td>
\r
385 <td>Central African Republic</td>
\r
401 <td>Channel Islands</td>
\r
425 <td>China, Hong Kong SAR</td>
\r
433 <td>China, Macao SAR</td>
\r
465 <td>Cook Islands</td>
\r
473 <td>Costa Rica</td>
\r
481 <td>Côte d'Ivoire</td>
\r
513 <td>Czech Republic</td>
\r
521 <td>Dem. People's Rep. of Korea</td>
\r
529 <td>Dem. Republic of the Congo</td>
\r
561 <td>Dominican Republic</td>
\r
585 <td>El Salvador</td>
\r
593 <td>Equatorial Guinea</td>
\r
625 <td>Faeroe Islands</td>
\r
633 <td>Falkland Islands (Malvinas)</td>
\r
665 <td>French Guiana</td>
\r
673 <td>French Polynesia</td>
\r
753 <td>Guadeloupe</td>
\r
785 <td>Guinea-Bissau</td>
\r
857 <td>Iran (Islamic Republic of)</td>
\r
881 <td>Isle of Man</td>
\r
929 <td>Kazakhstan</td>
\r
961 <td>Kyrgyzstan</td>
\r
969 <td>Lao People's Dem. Republic</td>
\r
1009 <td>Libyan Arab Jamahiriya</td>
\r
1017 <td>Liechtenstein</td>
\r
1025 <td>Lithuania</td>
\r
1033 <td>Luxembourg</td>
\r
1041 <td>Madagascar</td>
\r
1089 <td>Marshall Islands</td>
\r
1097 <td>Martinique</td>
\r
1105 <td>Mauritania</td>
\r
1113 <td>Mauritius</td>
\r
1137 <td>Micronesia (Fed. States of)</td>
\r
1145 <td>Moldova (Republic of)</td>
\r
1169 <td>Montenegro</td>
\r
1177 <td>Montserrat</td>
\r
1193 <td>Mozambique</td>
\r
1233 <td>Netherlands</td>
\r
1241 <td>Netherlands Antilles</td>
\r
1249 <td>New Caledonia</td>
\r
1257 <td>New Zealand</td>
\r
1265 <td>Nicaragua</td>
\r
1297 <td>Northern Mariana Islands</td>
\r
1313 <td>Occupied Palestinian Territory</td>
\r
1353 <td>Papua New Guinea</td>
\r
1377 <td>Philippines</td>
\r
1409 <td>Puerto Rico</td>
\r
1425 <td>Republic of Korea</td>
\r
1449 <td>Russian Federation</td>
\r
1465 <td>Saint Helena</td>
\r
1473 <td>Saint Kitts and Nevis</td>
\r
1481 <td>Saint Lucia</td>
\r
1489 <td>Saint Pierre and Miquelon</td>
\r
1497 <td>St. Vincent and the Grenadines</td>
\r
1513 <td>San Marino</td>
\r
1521 <td>Sao Tome and Principe</td>
\r
1529 <td>Saudi Arabia</td>
\r
1553 <td>Seychelles</td>
\r
1561 <td>Sierra Leone</td>
\r
1569 <td>Singapore</td>
\r
1593 <td>Solomon Islands</td>
\r
1609 <td>South Africa</td>
\r
1625 <td>Sri Lanka</td>
\r
1649 <td>Swaziland</td>
\r
1665 <td>Switzerland</td>
\r
1673 <td>Syrian Arab Republic</td>
\r
1681 <td>Tajikistan</td>
\r
1689 <td>TFYR Macedonia</td>
\r
1705 <td>Timor-Leste</td>
\r
1737 <td>Trinidad and Tobago</td>
\r
1761 <td>Turkmenistan</td>
\r
1769 <td>Turks and Caicos Islands</td>
\r
1801 <td>United Arab Emirates</td>
\r
1809 <td>United Kingdom</td>
\r
1817 <td>United Republic of Tanzania</td>
\r
1825 <td>United States of America</td>
\r
1833 <td>United States Virgin Islands</td>
\r
1849 <td>Uzbekistan</td>
\r
1865 <td>Venezuela (Bolivarian Republic of)</td>
\r
1881 <td>Wallis and Futuna Islands</td>
\r
1889 <td>Western Sahara</td>
\r