rajesh gollapudi's blog http://rajeshg.com Most recent posts at rajesh gollapudi's blog posterous.com Tue, 27 Apr 2010 09:57:11 -0700 The State of Web Development 2010 – Web Directions http://rajeshg.com/the-state-of-web-development-2010-web-directi-5 http://rajeshg.com/the-state-of-web-development-2010-web-directi-5

Tuesday, April 27th, 2010

The State of Web Development 2010 – Web Directions

Category: Survey

What are the current Web Directions? John Allsopp is back, with results from his latest State of Web Development 2010 survey.

There is a ton of content here, and the data is made available. For the full report you can grab the PDF.

This article summarizes the preferred environment of web developers and what's hot.

- Firefox is the browser of choice
- Preferred mobile browser is Safari
- Mac OS X is the preferred OS
- Most used js framework is jQuery
- Most developers test on IE (6-8), Safari 4/Chrome and Firefox >3.5

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/681852/41674_706545079_2156_q.jpg http://posterous.com/people/36jwzEOMAcIF Rajesh Gollapudi rajesh Rajesh Gollapudi
Mon, 19 Apr 2010 14:04:00 -0700 BOV - Blast Output Visualization Tool http://rajeshg.com/bov-blast-output-visualization-tool http://rajeshg.com/bov-blast-output-visualization-tool

Thought of posting links to some of my previous work at the Center for Genomics and Bioinformatics(CGB), Indiana University. 

URL: BOV CGB

Description: BLAST Output Visualization Tool (BOV) allows users to interactively visualize the BLAST high-scoring segment pairs between query and hit sequences for dissecting complex matching patterns. This software is aimed at facilitating users interested in identifying regions of colinearity, duplication, translocation, and inversion using the BLAST program.

Publication: 
Rajesh Gollapudi, Kashi Vishwanath Revanna, Chris Hemmerich, Sarah Schaack, and Qunfeng Dong (2008) 
BOV - A Web-based BLAST Output Visualization Tool. BMC Genomics. 2008 Sep 15;9(1):414. [ PubMed ]

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/681852/41674_706545079_2156_q.jpg http://posterous.com/people/36jwzEOMAcIF Rajesh Gollapudi rajesh Rajesh Gollapudi
Wed, 14 Apr 2010 11:05:00 -0700 Great article - WordPress Caching: What’s the best Caching Plugin? http://rajeshg.com/great-article-wordpress-caching-whats-the-bes http://rajeshg.com/great-article-wordpress-caching-whats-the-bes

If you are just looking for the essence of this article, here it is -
Overall the best out of the box cache plugin configuration in my opinion is: Hyper Cache + DB Cache Reloaded. Despite the allure of W3 Total Cache’s professionalism and only slightly less admired performance, I prefer to retain some manual control over my blog. For those on a medium priced shared server or if you like the idea of installing and forgetting, the W3 Total Cache plugin will be your ideal choice.

A lot of people still use WP-Cache and WP Super Cache. They are still respectable Wordpress caching plugins but consider trading up for Hyper Cache or W3 Total Cache. These newer caching plugins prove better performance and install/config much easier and cleaner. Also the development communities around these newer plugins are much more active and attentive to their users.

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/681852/41674_706545079_2156_q.jpg http://posterous.com/people/36jwzEOMAcIF Rajesh Gollapudi rajesh Rajesh Gollapudi
Tue, 13 Apr 2010 11:24:43 -0700 CakePHP 1.3.0-RC4 has arisen (Articles) | The Bakery, Everything CakePHP http://rajeshg.com/cakephp-130-rc4-has-arisen-articles-the-baker http://rajeshg.com/cakephp-130-rc4-has-arisen-articles-the-baker
By Mark Story (mark_story)
The CakePHP development team is happy to announce the release the CakePHP 1.3.0-RC4. This release marks the last release candidate, before 1.3.0 goes to stable.
The CakePHP development team is happy to announce the release the CakePHP 1.3.0-RC4. This release marks the last release candidate, before 1.3.0 goes to stable. Since 1.3.0-RC3 was released 2 weeks ago there have been over 55 commits and 22 tickets fixed. The plan is to release 1.3.0 in 2 weeks, barring the discovery of any critical issues.

Since the last release there have been a few significant changes. Plugin shortcut routes were mostly removed[1]. This was done for a couple reasons. Firstly, they have never 'really' worked properly, and were prone to creating ambiguous routes that possibly left some actions not accessible, by the urls generated for them. Secondly, they incurred additional overhead as the Dispatcher attempted various parameter permutations until finding the correct controller. For these reasons the feature was removed. We are suggesting that users needing the old routing, setup the appropriate routes in their routes.php file.

In other project news, thanks to some contributions the API now has far more links back to the book than ever before. The 1.3 book has been receiving a healthy amount of translation attention. There are now 4 languages with more than 70% complete translations. A big thanks to everyone who has contributed to the translation efforts. You can now download CakePHP logos, powered by logos and iPad wallpapers[2].

We'd like to thank everyone who has contributed documentation, tickets and code between the last release and now.

Download a packaged release [3]
View the changelog [4]

[1] http://cakephp.lighthouseapp.com/projects/42648/tickets/535-paginator-sort-produces-incorrect-url-in-plugins
[2] http://cakephp.org/logos
[3] http://github.com/cakephp/cakephp1x/downloads
[4] http://cakephp.lighthouseapp.com/projects/42648/changelog-1-3-0-rc4

 

Migrated the dev version of Finelight site to the latest CakePHP release candidate. In case you missed it, CakePHP 1.3 RC4 is out. Looking forward to the official 1.3 release in 2 weeks.

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/681852/41674_706545079_2156_q.jpg http://posterous.com/people/36jwzEOMAcIF Rajesh Gollapudi rajesh Rajesh Gollapudi
Thu, 08 Apr 2010 14:07:38 -0700 Move website http://rajeshg.com/move-website http://rajeshg.com/move-website


This one was launched a while ago (in October) to showcase Finelight's Move process.
Designed by: John Jacobsen
Developed with help from: Srilatha Marru

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/681852/41674_706545079_2156_q.jpg http://posterous.com/people/36jwzEOMAcIF Rajesh Gollapudi rajesh Rajesh Gollapudi
Wed, 07 Apr 2010 21:23:31 -0700 NCH Landing page for Gastro Campaign http://rajeshg.com/nch-landing-page-for-gastro-campaign http://rajeshg.com/nch-landing-page-for-gastro-campaign

Designed by John Jacobsen, with help from Sarah Stup
url: http://www.nch.org/medical-services/gastroenterology-center/connie.php or http://nch.org/gi

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/681852/41674_706545079_2156_q.jpg http://posterous.com/people/36jwzEOMAcIF Rajesh Gollapudi rajesh Rajesh Gollapudi
Wed, 07 Apr 2010 21:01:46 -0700 What's next in CSS http://rajeshg.com/whats-next-in-css http://rajeshg.com/whats-next-in-css

Cascading style sheets(CSS), which is responsible for styling various web pages, is and has always been going through a lot of changes. This blog post, tries to summarize some of the new and exciting ways to write it.

  1. Grids
    • Reset - reset the default font styling in all major browsers
    • Column grid
    • A set of classes or styles, which you can use to generate a grid. This is extremely helpful if you want to layout a site quickly. Most often these grids provide a centered layout of some xxx px, which can be split into any number of columns that you wish.
    • Typography
    • A set of classes which prescribe the default font sizes and the type of fonts to use. For example,<h1> bold 36px Verdana and <h2> bold 30px Verdana
    • Icons
    • A set of icons that are widely used. Although the default icons may not be useful or ideal for everyone, they can act as a placeholder. Typically they include icons such as RSS feed, user add/delete, buttons etc
    • Styles for form elements
    • This is very helpful, if the website that you are developing includes lot of forms. Frequently the grids provide ways to develop inline and block styles for form elements.
    • Scripts/Tools
    • Scripts to minify/compress the css. These could help you save bandwidth. My personal preference is the Yahoo UI compressor, which can compress both your css and js.
  2. CSS Grids are widely used to handle the differences between various browser implementations and to simplify common tasks. Of the various grids - 960.gs, YUI grid, Blueprint, Bluetrip seem to be ones that are widely used. CSS grids typically include the following - You can choose one or more of the available components from a CSS Framework depending on your situation. Be advised, there is no one framework that can be used for handling all the styles/issues that you have in mind. Each CSS framework is designed with a set of principles in mind, while being flexible enough to allow addition of other styles.
  3. OO approaches to write/generate CSS
    First of all, CSS is not object oriented and is not a programming language. The sole purpose of CSS is to let the browser know how to display or render a HTML element. Object oriented approaches to CSS, are targeted at redundancies in writing CSS. For example, consider the following CSS
    #container #content #header .title {
        font-size: 16px;
    }
    #container #content #header .sub-title {
        font-size: 12px;
    }
    You see the problem? If you change the name of the '#content' to '#newcontent', within your html markup, then you end up changing all occurrences of #content in your CSS. SaSS and xCSS are attempts at applying the DRY (Do not Repeat Yourself) programming paradigm to CSS. They typically rely on a programming language such as PHP or ruby to generate CSS. For example, SaSS converts

    #box
    :border 0
    :color black
    .orange
    :border 1px orange

    to

    #box {
    border: 0;
    color: black;
    }
    #box .orange {
    border: 1px orange;
    }

     Combine this with the abilities to use variables, mixins and templates. You can see how useful it could be in managing the css for a big corporate website.

I am eager to hear about any good frameworks or tools that I might have missed as part of this blog post.

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/681852/41674_706545079_2156_q.jpg http://posterous.com/people/36jwzEOMAcIF Rajesh Gollapudi rajesh Rajesh Gollapudi
Wed, 07 Apr 2010 20:54:02 -0700 New Finelight Website http://rajeshg.com/new-finelight-website http://rajeshg.com/new-finelight-website

We changed Finelight's web site last Friday, in our efforts to improve Finelight's search engine ranking, add more social media features and promote involvement of Finelighters among many others.

You can follow Finelight on Twitter @finelight and be a fan on Facebook.

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/681852/41674_706545079_2156_q.jpg http://posterous.com/people/36jwzEOMAcIF Rajesh Gollapudi rajesh Rajesh Gollapudi
Mon, 01 Mar 2010 13:31:46 -0800 NCH landing page for pancreatic cancer campaign http://rajeshg.com/nch-landing-page-for-pancreatic-cancer-campai http://rajeshg.com/nch-landing-page-for-pancreatic-cancer-campai

Rajesh

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/681852/41674_706545079_2156_q.jpg http://posterous.com/people/36jwzEOMAcIF Rajesh Gollapudi rajesh Rajesh Gollapudi
Fri, 12 Feb 2010 15:03:00 -0800 How to set child element opacity different from parent element http://rajeshg.com/how-to-set-child-element-opacity-different-fr http://rajeshg.com/how-to-set-child-element-opacity-different-fr

When using css (opacity) to set the transparency of an element, the child elements inherit the transparency of the parent element.

For example, if you set 50% transparency to the body element, the whole pages becomes 50% transparent. Even if you explicitly set the opacity to 1 for the child elements, the transparency is still there.

This is particularly not desired if your child elements has text.  As you can see from the screenshots, the text looks clear in Screenshot 1.  In Screenshot 2, the text dissolves into the background when opacity is set to 0.5. I used opacity 0.5 just to demonstrate this. The text looks better with opacity 0.9, but this is not the ideal solution.

Solution
To prevent this, the only way is to use a  png with the desired alpha transparency.
Note:
Transparent pngs are not supported by IE 6. So make sure that you use the fix mentioned at TwinHelix


 

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/681852/41674_706545079_2156_q.jpg http://posterous.com/people/36jwzEOMAcIF Rajesh Gollapudi rajesh Rajesh Gollapudi
Fri, 22 Jan 2010 17:12:20 -0800 NCH Landing Page for Cardiac Campaign http://rajeshg.com/nch-landing-page-for-cardiac-campaign http://rajeshg.com/nch-landing-page-for-cardiac-campaign

Screenshot taken on IE 6 using Adobe BrowserLab :)
Designed by John Jacobsen

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/681852/41674_706545079_2156_q.jpg http://posterous.com/people/36jwzEOMAcIF Rajesh Gollapudi rajesh Rajesh Gollapudi
Fri, 22 Jan 2010 09:22:12 -0800 Project Sikuli http://rajeshg.com/project-sikuli-2 http://rajeshg.com/project-sikuli-2

Nice way to automate day to day tasks

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/681852/41674_706545079_2156_q.jpg http://posterous.com/people/36jwzEOMAcIF Rajesh Gollapudi rajesh Rajesh Gollapudi
Wed, 28 Oct 2009 19:59:00 -0700 Centering an element on a page http://rajeshg.com/centering-an-element-on-a-page http://rajeshg.com/centering-an-element-on-a-page

Here is how you can position an element at the center of a web page (both horizontally and vertically).

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
<html>
<head>
<style type="text/css">
div#centered {
    position: absolute;
}
</style>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js">
</script>
<script type='text/javascript'>
$(document).ready(function(){
var height = $('#centered').height();
var width = $('#centered').width();
var docheight = $(document).height();
var docwidth = $(document).width();
var top = (docheight - height)/2;
var left = (docwidth - width)/2;

$('#centered').css('top', top+'px');
$('#centered').css('left', left+'px');
});
</script>
</head>
<body>
akjdakfjdkf
<div id="centered">
       <p>Paragraph 1 text.</p>
       <p>Paragraph 2 text.</p>
</div>
kadjkfjadkf
kajfkadjf
<div>
akjfkdajfk
</div>
<p>ajdfkdjaf kajfkdajf .jkjakdjfakdjf.
kadjfkadjfka.
kdjfkajdfkdajf kajdfkadjf kjfkajdfka. </p>
</body>
</html>

The content of the div with the id 'centered', will be positioned at the center of the web page. The 'absolute' positioning ensures that it is positioned at the center w.r.t the webpage or document.Instead if you want to position an element relative to an enclosing div, changing docheight and docwidth variables accordingly ensures that your element is centered.

This is often useful in situations where you want to display error messages like 404-page not found and for showing 'page redirect' messages.

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/681852/41674_706545079_2156_q.jpg http://posterous.com/people/36jwzEOMAcIF Rajesh Gollapudi rajesh Rajesh Gollapudi
Fri, 23 Oct 2009 16:26:00 -0700 How to make a footer stick to the bottom of a webpage http://rajeshg.com/how-to-make-a-footer-stick-to-the-bottom-of-a http://rajeshg.com/how-to-make-a-footer-stick-to-the-bottom-of-a

Often you face a situation where you don't have enough content on the webpage to make use of the space available in the browser window. A good example, for this is the "404 - File not found" page on your site.

I use the following technique to get rid of the situation where the footer doesn't stick to the bottom of the page. The idea is simple - Measure the height of the content and compare it with your window height. If the content height is less than the window height, then fill the difference with an empty space or to say exactly, add a div with the height set to the difference.

The code below uses jquery javascript library and should work pretty much in every browser.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
/**
* @author rajesh gollapudi
*/
$(document).ready(function(){
    placeFooter();
    $(function(){
        $(window).resize(function(){
        // console.log('You resized the window!');
if ($('#footer-spacer').length) {
$('#footer-spacer').remove();
}
            placeFooter();
        });
    });
});
function placeFooter(){
    // console.log("window height: " + $(window).height());
    var bottom = $('#footer').position().top + $('#footer').height();
    // console.log("footer position: " + bottom);
    if (bottom < $(window).height()) {

        var diff = $(window).height() - bottom;
        // We need to add bottom padding to this difference. This is to push the footer up a little bit, if the footer has any padding defined.
        var padding = parseInt($('#footer').css('padding-bottom')) + parseInt($('#footer').css('padding-top'));
        diff = diff - padding;


$('#footer').before("<div id='footer-spacer' style='height:" + diff + "px;'></div>");
}
}

Enjoy !!

Update:

I have updated the code above, to make sure that the footer sticks to the bottom on window resize events. Now when you are using FireBug, to should notice the footer moving up and down and window resize events. This is especially useful if you have a large monitor.

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/681852/41674_706545079_2156_q.jpg http://posterous.com/people/36jwzEOMAcIF Rajesh Gollapudi rajesh Rajesh Gollapudi
Fri, 23 Oct 2009 15:42:00 -0700 Includes in Javascript http://rajeshg.com/rajesh-4 http://rajeshg.com/rajesh-4

Ever wondered how to include other javascript files in javascript, here is how you can do it.

You can ask me when this could be useful. You can use it when you want to conditionally include javascript and css files. Lets say on the admin part of the site you want to use a different stylesheet, then you can parse the url and include the stylesheet, given certain parameters or if the url matches a regular expression.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
<script type='text/javascript'>
// For js file
loadjscssfile("http://example.com/js/rssfeedreader.js", "js");
// For css file
loadjscssfile("http://example.com/css/rsspage.css", "css");

function loadjscssfile(filename, filetype){
    if (filetype == "js") { //if filename is a external JavaScript file
        var fileref = document.createElement('script')
        fileref.setAttribute("type", "text/javascript")
        fileref.setAttribute("src", filename)
    }
    else
    if (filetype == "css") { //if filename is an external CSS file
        var fileref = document.createElement("link")
        fileref.setAttribute("rel", "stylesheet")
        fileref.setAttribute("type", "text/css")
        fileref.setAttribute("href", filename)
    }
    document.getElementsByTagName("head")[0].appendChild(fileref)
}
</script>

Permalink | Leave a comment  »

]]>
http://files.posterous.com/user_profile_pics/681852/41674_706545079_2156_q.jpg http://posterous.com/people/36jwzEOMAcIF Rajesh Gollapudi rajesh Rajesh Gollapudi