by http://webgeektutorials.blogspot.com

Friday, August 5, 2011

Javascript to get URL of page

In my project, today i need to get the URL of the page, i used a small Javascript to implement it. In Javascript location object contains information about the current URL. It is supported by all the major browsers.
The location object is part of the window object and is accessed through the window.location property. Quite simple script to do this is :


<script language="javascript" type="text/javascript">
    document.write (document.location.href);
</script>

Properties of Location Object
 hash  Returns the anchor portion of a URL
 host  Returns the hostname and port of a URL
 hostname  Returns the hostname of a URL
 href  Returns the entire URL
 pathname  Returns the path name of a URL
 port  Returns the port number the server uses for a URL
 protocol  Returns the protocol of a URL
 search  Returns the query portion of a URL

Note : Please note that this won't work if you are using frames in your page.

Monday, August 1, 2011

Creating Cross-plattform Mobile Applications with Dojo Toolkit

Dojo is an open source toolkit that helps you write robust and efficient JavaScript code. JavaScript is a language that runs within the Web browser, and there are various flavors of Web browser that interpret the JavaScript in slightly different ways. Toolkits such as Dojo, YUI, Prototype, and many others are designed to abstract away the browser idiosyncrasies so that you don't have to learn them all and handle them in your code.
Some points about Dojo : 
  1. Dojo is JavaScript framework released as open source software. This JavaScript toolkit provides many components to develop rich internet applications.
  2. You can use Dojo toolkit to develop dynamic web applications. Dojo toolkit will put life in your web application and turn it into highly interactive application. You can turn your web application into desktop
  3. like web application.
  4. Dojo offers many widgets, utilities and ajax libraries to develop your application.
  5. Dojo is released under BSD or AFL license
  6. Dojo is free and can be used to develop free or commercial application.
There are often several ways to code the same thing using JavaScript. Toolkits like Dojo provide functions you can use to do things in easier or more efficient ways. Using libraries from a toolkit can reduce the lines of code you write and make your JavaScript applications quicker and more stable.The Dojo Toolkit comes with many amazing modules which all are trying to make your life as a developer many times easier. This short introduction to UI Development will introduce you to the main Dojo layout and form widgets.

Why use Dojo/Dijit? ( http://dojotoolkit.org )

One of the great features of dijit is the fact that it is all ready for a11y (accessibility) and i18n (internationalization). Imagine you are working on a new product, your current market is the one of your country and you are not too concerned about delivering your product in several different languages. Thinking about making your product accessible for people with disabilities is way down the list of your priorities.

Sunday, July 31, 2011

How to Install IIS on windows

How to Install IIS on Windows XP and Windows 2000
  1. On the Start menu, click Settings and select Control Panel
  2. Double-click Add or Remove Programs
  3. Click Add/Remove Windows Components
  4. Click Internet Information Services (IIS)
  5. Click Details
  6. Select the check box for World Wide Web Service, and click OK
  7. In Windows Component selection, click Next to install IIS
After you have installed IIS, make sure you install all patches for bugs and security problems. (Run Windows Update).

How to Install IIS on Windows Vista

  1. Open the Control Panel from the Start menu
  2. Double-click Programs and Features
  3. Click "Turn Windows features on or off" (a link to the left)
  4. Select the check box for Internet Information Services (IIS), and click OK
After you have installed IIS, make sure you install all patches for bugs and security problems. (Run Windows Update).

Thursday, July 28, 2011

Benefits Microsoft LightSwitch 2011

Why use Microsoft LightSwitch?        ( Source Microsoft.com)

Microsoft Visual Studio® LightSwitch™ 2011 is a flexible development tool that enables developers of all skill levels to quickly create and deploy great looking business applications for the desktop and the cloud. With timesaving tools and templates, and an intuitive development environment, Visual Studio LightSwitch helps speed the development and reduces the complexity of everything from UI design to Windows Azure Cloud Deployment. With Visual Studio LightSwitch it is finally practical to create affordable, scalable custom software solutions that bridge the gaps between existing systems and data and help provide comprehensive, user-friendly views of your business data.
With Visual Studio LightSwitch 2011, you can dramatically decrease the time it takes to build a custom application that connects with existing applications, legacy systems and web services. Visual Studio LightSwitch 2011 automatically handles the routine code, letting you focus on developing the custom logic that makes your application unique.

Flexibility for Today and Tomorrow

Visual Studio LightSwitch 2011 gives you the flexibility to keep your technology and business options open, while building a practical, scalable application to match your current needs. With Visual Studio LightSwitch 2011 you can easily interoperate with your existing data systems and web services, choose from a wide range of hosting and deployment options – even add 3rd party plugins as needs change.

Top ten benefits

Build business applications like they
were created by a professional designer Visual Studio LightSwitch 2011 comes with an extensible set of pre-built Application Shells that can give your application the familiar feel of popular Microsoft software.

Build a better application faster
Visual Studio LightSwitch 2011 includes templates for the most common types of business applications. It also contains predefined data types for commonly used fields, like phone numbers and e-mail addresses.

Tuesday, July 26, 2011

Inside Adobe Flash CS 5.5?


"The new features in Flash Professional CS5 should bring smiles to the faces of both designers and developers. Two big improvements in the way Flash handles video are the ability to preview an imported video on the Stage and adjust its parameters on the fly."
"Personally, I already have a project on the burner that the new tools and features in Flash CS5 will shorten development time and more than pay for the price of the upgrade from CS4."
Cyndy Cashman, Layers Magazine, 
April 23, 2010

Adobe® Flash® Professional CS5.5 software is the industry-leading authoring environment for producing expressive interactive content. Create immersive experiences that present consistently to audiences across desktops, smartphones, tablets, and televisions.


What's new in Flash Professional
  • Efficient workflows for mobile development
  • Content scaling when resizing stage
  • Enhanced layer control 
  • Symbol rasterization and better performance
As a core component of the Adobe Flash Platform, Adobe Flash Player allows you to make your web content contextually relevant and reach more users across a wide spectrum of Internet-connected devices, including smartphones, tablets, netbooks, TVs, and PCs. New device-ready features take advantage of native device capabilities that include support for touch, gestures, input models, accelerometer, browser, and additional purpose-built hardware to bring unprecedented creative control and expressiveness to the device browsing experience.

Deprecated commands Oracle 11gR2

The most used to command "crs_stat -t" is deprecated on 11gR2. Instead you would use -
  crsctl status resource [the output will be status of all resources]

You can still use the "-t" option to get a tabular report though ;)
    crsctl status resource -t

 Specify resource name "ora.mydb.test" to get the status of any particular resource -
   crsctl status resource ora.mydb.test

In fact, quite a few commands have been deprecated in 11gR2; For the complete list refer to

What is Orastack ?

ORASTACK is an Oracle supplied utility specifically for Windows Operating system. It allows us to modify the default stack size of a thread/session when created in the Oracle executable. It should be run against a specific Oracle binary such as "sqlplus.exe", "tnslsnr.exe" etc. It alters the part of the binary header that defines the default stack size used by "the create thread API".

By reducing the stack of every session created in the Oracle executable, it is possible to serve more users. In a system with a 1000 users reducing the
stack from 1Mb to 500K would release 500Mb of the address space for other
allocations or more users. However if its set too low then session might fail with ORA-3113 error.

Friday, July 15, 2011

Google+ and chrome extension

Google+ is a social networking service operated by Google Inc. The service launched on June 28, 2011, in an invite-only testing phase.Google+ will be built as a layer that not only integrates different Google social services, such as Google Profiles and Google Buzz, but also introduces many new features including Circles, Hangouts, Sparks and Huddles. Google+ will also be available as a desktop application and as an application on Android and iOS operating systems.


Already using Google+? Follow Mashable News for the latest about the platform’s new features, tips and tricks as well as our top social media and technology updates.

While Google works on adding more features, some available Chrome extensions can fill the functionality gap. You want to get better notifications, enjoy improved sharing options, or scroll through your stream more quickly, there’s an extension available — for free — to help.

There are some chrome extension listed below, will improves Google+
Note: These extensions are available with chrome.

Wednesday, July 13, 2011

MySql Best Opensource Database for Ruby on Rails

RoR is being highly discussed phrase in the realm of web development. Thinking why is it so? Ruby on Rails can be defined as a full stack framework which means that this framework covers everything which is needed to build a web application. It is an open source web application framework that can help you building web applications with an out of the box architecture. It is written in Ruby which is an object oriented language with clean syntax that can make programming enjoyable. Moreover Rails could help you creating a web application almost ten times faster than you do with regular java framework and that too without compromising with the quality. As it uses the MVC architecture pattern, it organizes the application programming that provides flexibility and simplicity. RoR is a great framework for them who have high timeliness and budget constraint.

While SQLite3 is extremely convenient for development and testing databases, and PostgreSQL has powerful Generalized Search Tree indexes and is very close to being enterprise-ready, MySQL is the choice for many Web sites thanks to its excellent read performance, transparent support for large text and binary objects, and incredibly easy administration. Stored procedures, functions, triggers, and updateable views were added to MySQL in version 5, overcoming the largest technical objections to its deployment at many sites. MySQL also has a large, helpful user base, and some poster-child deployments including eBay, Yahoo, and Craigslist.
You can download MySql module for ruby on rails from link given below.

Tuesday, July 12, 2011

Common ways to redirect website

However there are many ways to redirect website's but here are simple ways by examples, This question often comes in-front of you when giving interview for web designer or developer.

For this example I will use the website: http://www.domain.com
Let’s say this site is build in the folder: /folder/ we need a redirect from
DOMAIN to DOMAIN/FOLDER.

META Tags:
Create in the root of your domain an index.html and use a meta-refresh tag in the of your HTML.
This way of redirecting is according to W3C not so nice, and it also will have a delay.
You can set this delay, however I set it to 0.

<meta http-equiv="refresh" content="0;URL=http://www.domain.com/folder/" />

Link :
Not so nice, but to most accessible way, is to just create an empty index.html with an hyperlink
to your new folder.