Skip to main content

Posts

Showing posts from July, 2007

New Firefox release 2.0.0.6 - Security update

A new version of Firefox, 2.0.0.6 has been released today. This is another security update. And they released the 2.0.0.5 version just 13 days ago. That's why I really love Firefox. When ever an issue is reported, they work on it and provide us with a new version so that we are on the safe side always. And this is not the case with some other browsers where people have to wait months and years for some fixes. So thanks guys for all your dedication on making a better product.

Read the release note for more info.

Scrollable table with GWT

We came across a requirement to build a scrollable data table using Google Web Toolkit (GWT) because we had a limited space, but a growing table depending on the search criteria. As anyone can guess, having a scrollable table would be the best option. For that we used two components rather than one. com.google.gwt.user.client.ui.ScrollPanel and com.google.gwt.user.client.ui.FlexTable. The data table was added inside the Scrollable Panel.

For clarification, we have added the code below.
ScrollPanel scrollPanel = new ScrollPanel(); FlexTable dataTable = new FlexTable(); dataTable.setWidth("100%"); scrollPanel.add(dataTable); scrollPanel.setSize("300", "200"); // add data to table // ....
For setting width and height; it's advised to use CSS rules, but for ease of understanding we have shown some hard coded values here.

Jar not loaded warning/error in Google Web Toolkit (GWT) deployment to tomcat

When a Google Web Toolkit (GWT) web application is deployed to Tomcat web server, you may encounter a warning message as follows.
org.apache.catalina.loader.WebappClassLoader validateJarFile INFO: validateJarFile(<$webAppsFolder$>\WEB-INF\lib\gwt-user.jar) - jar not loaded. See Servlet Spec 2.3, section 9.7.2. Offending class: javax/servlet/Servlet.class
No need to worry too much about this warning message. This raises just because WebappClassLoader has loaded the servlet.jar already. The gwt-user.jar already contain the content of the servlet.jar file. Solution Even though this message can be ignored, this warning message can be avoided just by replacing the gwt-user.jar file with gwt-servlet.jar (which comes with Google Web Toolkit (GWT) download).

Following image shows the content of the gwt-user.jar, and the content of the servlet.jar is highlighted.


gwt-servlet.jar has been created by removing the content of the servlet.jar from the gwt-user.jar, so this change will…

Call a JavaScript function inside body of a web page

JavaScript is mainly used for actions on user events like onClick(), onMouseOver() etc. But what if you need to call a JavaScript function without any user events? Answer would be to use the onLoad() of the <body> tag. <body onLoad="javascript:myfunction()" > But what if you don't have access to change the onLoad()? Is there an answer for that as well?

Yes, and it's easy. Just call the function inside your page as same as you would write JavaScript inside the body of a page.
<script type="text/javascript" language="JavaScript"> doSomething('params'); </script>
In this example, doSomething() function is added to the web page inside the header of the page. And for ease of understanding the complete code is shown below.
<html> <head> <script type="text/javascript" language="JavaScript"> function doSomething(params); //do something nice wit…

[Cricket] Sangakkara joins the "five double hundreds" club

Today Kumara Sangakkara become the seventh cricketer to reach five double hundreds in Test. This is a real achievement and it shows Sangakkara's patience as well as the talents. Sri Lanka is the only country to have more than one player in that list of seven players.

Here are the seven players with five or more double hundreds.

1. Donald Bradman (AUS)- 12
2. Brian Lara (WI) - 9
3. Wally Hammond (ENG) - 7
4. Marvan Atapattu (SL) - 6
5. Javed Miandad (PAK) - 6
6. Kumara Sangakkara (SL) - 5
7. Rahul Dravid (IND) - 5

Well done Sanga.
Creative Commons License Digizol by Kamal Mettananda is licensed under a Creative Commons Attribution-Noncommercial-No Derivative Works 3.0 License .
URL of this page must be supplied in attribution
© 2004-2017