Showing posts with label html tables. Show all posts
Showing posts with label html tables. Show all posts

Friday, 11 February 2011

ASP: How to create custom filters for your tabular data

   


Displaying data in a table is the most used and easiest way of publishing information for the user. It is quite common in web app and sites, that a query resulting recordset is displayed in a tabular form.
In this short article I will explain how to apply custom filters to the recordset, based on users requests. In order to show you how to do it, I need to explain a bit where to start. Our table could be something like:
IDPRODUCT FAMILYDESCRIPTIONCODECOLOURTYPE
1BottleGlass bottle1234GreenProduct
2BoxCarton box5678BrownPackage
The table could go on with all the products. We are going to create links inside the table to filter data.

Wednesday, 22 December 2010

HTML: How to create bar charts with tables

   


In this post I will explain a very - very! - simple method to create vertical or horizontal bar charts using only HTML. You already know that on the web you can find many different solutions to create charts. In October, I  posted a list of jQuery plugins and I know there are other JavaScript snippets or Flash stuff available to draw graphs. However I've always found hard to apply those solutions to my needs. That is because I wanted to use data from a database, while many of the available snippets get the data from txt or xml files.

Monday, 25 October 2010

ASP: simple alternating colour rows in a dynamic table

   


There is a very simple way of presenting a dynamic table with alternate colours for rows. In order to achieve this effect we can use CSS and ASP.
First of all, prepare the CSS style for your rows as follow:
<style type="text/css">
<!--
table.sample tr.d0 td {
    background-color: #0C50DA;
}
table.sample tr.d1 td {
    background-color: #2B78ED;
}
-->
</style>

Wednesday, 20 October 2010

jQuery: enhancing html tables' usage with DataTables plugin

   



Working with tables is a basic need for every web developer. Specifically when data fetched from a database must be tidily presented in your page, tables could be the only viable answer. We can enhance tables' usage with a great jQuery plug-in: DataTables.

 

Wednesday, 8 September 2010

Are keywords and description attributes useful?

   


There was a time when keywords were very important in web sites promotion and ranking. The way search engines spiders considered the content of a page for ranking and appropriate search matching, was strictly related to keywords. But then, many webmasters thought that filling up long lists of not so much related keywords to their pages, helped them to get a higher ranking. When I say "not so much related", I mean that sometimes a good and sexy word could really draw traffic. Webmasters used to look for popular keywords and add them to their pages, regardless that they were consistent or not with the content of the page itself. And so, starting from 1999, search engines have gradually stopped looking for them and stopped considering them. At least most of them (it actually seems that Yahoo is still using them in conjunction with the real page content).

Friday, 23 July 2010

Exporting data to Excel in asp

   


One of the things that I have been asked for several times during web application development, was the possibility of exporting data to Ms Excel. That is because people need to further manipulate query results. I always thought that the best way to deal with data filtering and sorting, is to create a suitable parametric query. Sometimes that is not enough and you end up creating an asp page in order to export data to Ms Excel.

Friday, 16 July 2010

jQuery: the magic wand

   


I don't like CMSs. Well, I must admit: I really hate CMSs. I'm stating that just because I do like programming my own web site with complete freedom. And CMSs - even if they claim to be complete or complicated - are usually too tight for my needs.
Even though that is always true and I won't change my mind in the future, I do believe that sometimes programming everything in a web site is very hard and time consuming. So a little help - with complete freedom and customization - is welcome.

jQuery has nothing to do with CMSs