Posts filed under 'web'
micro blogging and macro narration
Twitter everywhere. I am really a fan of twitter. It’s a remarkable way to bring bloggers *together and am surprised to see it everywhere. I could also see media companies promoting twitter apps in their set top box.
But i don’t know why but for some reason i am not able to tweet much even though i like the way it takes the message to the people. I remember myself and Joseph were discussing about one such idea exactly a year before(when we never heard of twitter, or say it was not so popular) and we even kept a name for it, life blog. The word life is because, the whole intension of the platform is to narrate the life
So when did this micro blogging idea came into picture ? Is it an easy way to bring in mobile users to blog ? I feel mobile web would bring in lot of changes to the way blogs are read or say conceived. Narration !! Interesting who knows, we may even have a twitter feed running in our personal blog site sometime, Soon !
Another interesting analysis about twitter. It has enormous content nerrated by souls in this world and at times it becomes less manageable. So does it gets shaped up like how a macro blog (or blog) gets shaped? The word *shape has a deeper meaning in the world of expression, esp. in the world of blogs. I believe the regular blogs gives the author a tool to shape up information than it is with the micro blog. Tweets are some sort of expressions carried out in a *timeline. Small time !! I call it small time because it’s the very old nature of west to live every moment and gauging every second. I do not find anything wrong in this conception of “every second” living unless you carry a long size mini notes with you to remember.
It’s really nice to see what people narrate in the little time slots. Mostly it’s like communicating in pieces. Exactly like a asynchronous telephone conversation. Say telegram sort. It’s a gram basically. This little concept drags many people towards it. Say for example, how you felt when you saw you exam result, how you learnt cooking you favourite dish etc.., These things may not shape up to something big, but it has it’s own beauty and essence.
Add comment November 23, 2009
west drags web 2.0
Times of recession and it’s about business survival. Stories of cost cutting, layoffs, no funding for research, frozen development etc…, are closely related to corporates and governance. Ok enough of those boring lines of corporate lecture. Do we see web 2.0 getting affected by these uncertainties of the business world. As a close observer of the web, i could see some sort of dizziness in the world of web development.
I don’t want to talk big players like Google and Micorosoft as they already established some sort of revenue model out of web, but i am worried about the startups. Since most of them being funded by west, aspiring startups might go for a halt for some time. I should say post 2006, the world of web saw many new ideas like Flikr, Facebook , Youtube etc.., Do they evolve as a model ?
So, how long do we wait. Wheres are those budding mobile VAS providers. Can this ecosystem sustain the tides of economic crisis ?
Another important question is: will web 2.0 take a turn someway or take a temporary halt ?
Add comment May 9, 2009
A simple displaytag grid demo
Display tags are pretty good option when it comes to creating a enterprise class data grid.
The sample code given below is quite a head start for building up a bulky grid.
// Create class that returns a list
package org.ixfree.Displayags;
import java.util.*;
public class GridList {
private List aList;
public List getAList() {
return aList;
}
public void setAList(List list) {
aList = list;
}
public GridList(int i)
{
this.aList = new LinkedList<DataBean>();
}
}
// POJO bean that goes into the list. DataBean in our case.
package org.ixfree.Displayags;
public class DataBean {
private String name;
private String age;
public String getName()
{
return this.name;
}
public String getAge()
{
return this.age;
}
public String setName(String name)
{
this.name = name;
}
public String setAge(String age)
{
this.age = age;
}
}
// Get the libraries reffered
// Sql needed if you wanna get the data out of the table. Ofcourse there are much better ways to do it.
<%@ taglib uri=”http://displaytag.sf.net” prefix=”display”%>
<%@ page import=”java.util.*” %>
<%@ page import=”org.ixfree.Displayags.*” %>
<%@ page import=”java.sql.*” %>
<%
// Make a list of data for populating grid
List<DataBean> list = new GridList(6).getAList();
// .. Get the data into the bean and add it to the list.
// .. Every bean here refers to a row in the grid. Yeppiiie….
// Put the list in the request
request.setAttribute( “storedList”,list);
%>
// Make it as a XHTML (good for the browser)
<head>
<!– All script and style/references goes here –>
<link href=”ixfreeDemoDisplayTags.css” rel=”stylesheet” type=”text/css”>
</head>
<body>
<!– If you dont want the grid to introduce scroll bar for the window, but ok for the grid –>
<div id=”My_DisplayTag_Grid” style=”width: 800px; height: 360px; overflow: auto” >
<!–
The pageSize is pretty useful when you wanna have pagination
class is just our regular css stuff
headerClass applies to the TH’s
name attribute of the display:table tag does the magic of reading our list.
–>
<display:table name=”storedList” class=”myDisplayTagStyle” id=”displayTable” pagesize=”10″ requestURI=”theCurrentJspPage.jsp”>
<display:column sortable=”true” property=”name” title=”Name” class=”myDisplayTagStyle” headerClass=”myDisplayTagStyle”/>
<display:column sortable=”true” property=”age” title=”Age” class=”myDisplayTagStyle” headerClass=”myDisplayTagStyle” />
</display:table>
</div>
</body>
### ixfreeDemoDisplayTags.css goes this way ###
html
{
scrollbar-base-color: #dddddd;
}
table.myDisplayTagStyle
{
background-color: #dddddd;
}
td.myDisplayTagStyle
{
border-color: black;
border-width: 1px 1px 1px 1px;
border-style: solid;
margin: 0;
font-family:Arial Verdana;
font-size:10pt;
overflow: auto;
white-space:nowrap;
padding-top: 6px;
padding-right: 6px;
padding-left: 6px;
padding-bottom: 6px;
}
tr.odd
{
border-color: black;
border-width: 1px 1px 1px 1px;
border-style: solid;
margin: 0;
padding: 4px;
background-color: #ffffff;
white-space:nowrap;
}
tr.even
{
border-color: black;
border-width: 1px 1px 1px 1px;
border-style: solid;
margin: 0;
padding: 4px;
background-color: #dddddd;
white-space:nowrap;
}
th.myDisplayTagStyle
{
background-color: #dddddd;
border-color: black;
border-width: 1px 1px 1px 1px;
border-style: solid;
font-size: 9pt;
white-space: nowrap;
padding-top: 10px;
padding-right: 10px;
padding-left: 10px;
padding-bottom: 10px;
}
Add comment December 11, 2008
Simple Dojo Datagrid + JSON Store
Sample Dojo Grid with JSON access below
Works for Dojo 1.2, and not with earlier versions.
And one fabulous improvement with the new grid (dojox.grid.DataGrid) is that when we try to load the data from json, it shows a Loading symbol which i feel is pretty cool compared to the earlier dojox.Grid. And the layout definition is fairly simplified. What i would love to see in future is a framework with which people can work with less scripting knowledge.
<!DOCTYPE HTML PUBLIC “-//W3C//DTD HTML 4.01 Transitional//EN” “http://www.w3.org/TR/html4/loose.dtd”>
<html>
<head>
<title>Layout Markup Basic</title>
<style type=”text/css”>
@import “dijit/themes/soria/soria.css”;
@import “dijit/themes/tundra/tundra.css”;
@import “dojox/grid/resources/Grid.css”;
@import “dojox/grid/resources/tundraGrid.css”;
@import “general.css”;
</style>
<script type=”text/javascript” src=”dojo/dojo.js” djConfig=”isDebug:false, parseOnLoad: true”></script>
<script type=”text/javascript”>
dojo.require(“dojo.data.ItemFileReadStore”);
dojo.require(“dojox.grid.DataGrid”);
dojo.require(“dojo.parser”);
dojo.require(“dijit.form.Button”);
dojo.require(“dijit.form.TextBox”);
dojo.require(“dijit.form.DateTextBox”);
dojo.require(“dijit.form.ComboBox”);
dojo.require(“dijit.layout.ContentPane”);
dojo.require(“dijit.layout.TabContainer”);
var jsonStore = new dojo.data.ItemFileReadStore({ url: “MyJson.jsp” });
</script>
</head>
<body class=”soria”>
<table id=”gridNode” jsId=”grid” dojoType=”dojox.grid.DataGrid” autowidth=”true”
query=”{ customer_name: ‘*’ }” store=”jsonStore” class=”tundra” style=”height:300px;width:400px”>
<thead>
<tr>
<th field=”customer_name”>Customer Name</th>
<th field=”customer_address” width=”100px”>Customer Address</th>
</tr>
</thead>
</table>
</body>
</html>
MyJson.jsp Sample goes below:
<%@ taglib prefix=”json” uri=”http://www.atg.com/taglibs/json” %>
<json:object>
<json:array name=”items” var=”item” items=”2″>
<json:object>
<json:property name=”customer_name” value=”nancy”/>
<json:property name=”customer_address” value=”LA”/>
</json:object>
<json:object>
<json:property name=”customer_name” value=”ken”/>
<json:property name=”customer_address” value=”CA”/>
</json:object>
</json:array>
</json:object>
If we need a json to be dynamically associated to the grid on any event, simple 3 steps will do:
- dojo.require(“dojo.data.ItemFileReadStore”);
- jsonStore = new dojo.data.ItemFileReadStore({ url: “<url for json rendering>”})
- var grid = dijit.byId(“gridNode”); // our grid div
- grid.setStore(jsonStore); // no need for a separate refresh call
If you have any comments or corrections, then please leave a comment.
Add comment October 7, 2008
Simple Dojo Grid
Hi Friends. I was working on a simple data grid using Dojo. Thanks to SitePen’s blogs. It was quite useful except for the fact that i messed up with the css and took some time to make over.
Dojo makes an intensive use of JSON and it’s really a brilliant idea which is evolving quite firmly. We are there to use JSON more in the future.
Try to deploy in any web server and make sure the Dojo, Digit and Dojox are in the path of this file which we deploy.
<html><head>
<script type=”text/javascript” src=”dojo/dojo.js” djconfig=”parseOnLoad: true, isDebug: false”> </script>
<script type=”text/javascript” src=”dojox/grid/Grid.js”></script>
<style type=”text/css”>
@import “dojox/grid/_grid/tundraGrid.css”;
</style>
<script type=”text/javascript”>
var data = [
[ '4001', 'SB', '19/10/1983', '19/10/1920' ],
[ '4002', 'SB', '20/10/1983', '20/10/1920' ],
[ '4003', 'FD', '21/10/1983', '21/10/1920' ],
[ '4004', 'FD', '22/10/1983', '22/10/1920' ]
];
var cell = { name: ‘Cell Name’ };
var subrow = [ cell ];
var view = { rows: subrow };
var structure = [ view ];
var subrow = [
{ name: 'Account Number' },
{ name: 'Account Type' },
{ name: 'Start Date' },
{ name: 'Expiry Date' }
];
var view = {
rows: [ subrow ]
};
var structure = [
view
];
var model = new dojox.grid.data.Table(null, data);
</script>
</head><body class=”tundra”>
<div id=”grid1″ dojotype=”dojox.Grid” autowidth=”true” model=”model” structure=”structure” class=”grid”/>
</body></html>
PS:- Try the latest Dojo version to avoid any mishaps.
Oho… This is not the way to go. Try dojo toolkit version 1.2 grid like given here
One problem regarding working on DOJO is the lack of documentation and heavy depencendy on search engines. This has been felt/discussed in many places. When i had to find the list of dijit widgets i could not get proper answers. Finally found this link: http://redesign.dojotoolkit.org/jsdoc/dijit/HEAD/dijit.form.
And do write in your comments when you try to populate grid using JSON or any other technique.
2 comments September 30, 2008