Tuesday, 4 June 2013

What's New in HTML5?

DOCTYPE
The most important deceleration element, this helps your browser to understand what kind of HTML version it is trying to parse.

<!DOCTYPE html>

HTML5 dropped type attribute
<meta http-equiv=”Content-Typecontent="text/html";>
to
<meta charset=”UTF-8”>

<link rel=”stylesheet” href=”style.csstype=”text/css”>
to
<link rel=”stylesheet” href=”style.css”>

You should avoid following tags and attributes in HTML5
<font>, <center>,<frame> align, bgcolor, height, width, size, type

Step 1
Web layout divided into four horizontal parts are Hearder, Nav, Section and Footer.

HTML Code

<header class='container'>1 Header</header>
<nav class='container'>2 Nav</nav>
<section class='container'>3 Main</section>
<footer class='container'>4 Footer</footer>


HTML5 Template Design for Blog.


CSS Code
*{margin:0px; padding:0px}
header, footer, section, nav
{
display:blocks
}
.container
{
margin:0 auto;
width:950px;
margin-top:20px
}

Step 2
Now working with an unorder list <ul> tag.
<nav class='container' id='nav'>
<ul>
<li>HOME</li>
<li>PROJECT</li>
<li>TUTORIALS</li>
<li>FACEBOOK</li>
<li>JQUERY</li>
</ul>
</nav>
HTML5 Template Design for Blog.

#nav
{
overflow:auto;
}
#nav ul
{
list-style:none;
height:30px;
padding:0px;
margin:0px;
}
#nav ul li
{
float:left;
margin:10px;
}


Step 3
section (main part)  dividing into two vertical parts are section(article part) and aside(sidebar part)
<section class='container'>
<section id="content">Article</section>
<aside id='sidebar'>Sidebar</aside>
</section>

HTML5 Template Design for Blog.


CSS code
#main
{
overflow:auto;
}
#content
{
float:left;
width:600px;
}
#sidebar
{
float:right;
width:330px;
}

Article Page
Here article title is the most important and top level, so title should be in <h1> tag.
<section id='content'>

<article>
<header>
<h1>Article Title</h1>
</header>
<p>
Article Description 
</p>
</article>

</section>

HTML5 Template Design for Blog.


Home Page
This page should be with multiple article title links with little description, so that reader can quickly find more information. W3C standards specifying <h1> tag use for top-level heading.
<section id='content'>

<article>
<header>
<h2>Article Title 1</h2>
</header>
<p>
Article Short Description 
</p>
</article>

<article>
<header>
<h2>Article Title 2</h2>
</header>
<p>
Article Short Description 
</p>
</article>

.......

</section>

HTML5 Template Design for Blog.


Modernizr
Modernizr is a JavaScript library that detects the availability of native implementations for next-generation Web Technologies. These technologies are new features that stem from the ongoing HTML5 and CSS3 specifications.
Responsive Web Design using CSS3

HTML Code
For implementing lower version browser like Internet Explorer 7 and 8, you just include modernizr.min.js after style sheet inside header tag. download link.
<!DOCTYPE html>
<!--[if lt IE 7]>
<html class="no-js lt-ie9 lt-ie8 lt-ie7">
<![endif]-->
<!--[if IE 7]>
<html class="no-js lt-ie9 lt-ie8">
<![endif]-->
<!--[if IE 8]>
<html class="no-js lt-ie9">
<![endif]-->
<!--[if gt IE 8]><!-->
<html class="no-js">
<!--<![endif]-->
<head>
<title>Responsive Design with CSS</title>
//Meta tag for devices
<meta name="viewport" content="width=device-width">
<link rel="stylesheet" href="style.css"> //Style Sheet
<script src="modernizr.min.js"></script>
</head>
<body>
<header class='container' id='header'>
Logo Part
</header>

<nav class='container' id='nav'>
<ul>
<li><a href='#'>Home</a></li>
<li><a href='#'>DEMOS</a></li>
<li><a href='#'>PROJECT</a></li>
.....
.....
</ul>
</nav>

<section class='container' id='main'>
<section id='content'>
<article>
<header>
<h1>Article Title</h1>
</header>
<p>
Article Description
</p>
</article>
</section>

<aside id='sidebar'> 
</aside>
</section>

<footer class='container' id='footer'>
<p>
© 2009-2013 9lessons.info. 
</p>
</footer>
<body>
</html>

Now this code works fine with Internet Explorer lower version.

Friday, 5 April 2013

11 Ways to Prevent Computer Viruses

It doesn’t matter if you’ve been on the Internet for five minutes or five years, you’ve probably thought about ways in which you can prevent a computer virus from entering your machine. A virus can compromise your personal information and even destroy your computer completely. Luckily, there are many low cost things you can do to protect yourself and stay one step ahead of the hackers. Here are 11 things you can do to help prevent computer viruses from invading your computer.

1. Install a reliable anti virus program – From the first moment you turn your computer on, you should have a trusted anti virus program by your side. Even if you have a machine that isn’t hooked up to the Internet, a reliable anti virus program is a low cost and common sense addition to any machine. There are even free anti virus programs you can download that work almost as well as industry giants like Norton and McAfee.

2. Install anti-spyware and anti-malware programs – As good as the best anti virus programs are, they sometimes need a little bit of help. Thankfully, many of the top anti-spyware programs are completely free. Spybot Search and Destroy and CCleaner are just two free programs that can help prevent computer viruses from doing any damage on your machine. As helpful as these programs are, however, you must update them and run them on a regular basis for them to do any good.

3. Avoid suspicious websites – A good virus protection program will alert you when you visit a website that attempts to install or run a program on your computer. Many less than reputable adult websites do this, so if you get a warning, don’t go back, you may end up with a bug you can’t get rid of.

4. Never Open Email Attachments Without Scanning Them First – The most common way viruses are spread throughout the Internet is still via email. Some attachments, like pictures, now display in emails and don’t require an attachment to be manually opened, but other documents do. Make sure you use an email client that scans all email attachments before you are allowed to open them. This will help prevent computer viruses from getting a foothold on your machine.

5. Set up Automatic Scans – Many of the top anti virus programs, as well as the best anti-spyware programs, now have settings that will let them automatically run during down times or in the middle of the night. Of course, your computer must be on for this to happen, but having daily scans run when nothing else is going on is a great way to prevent even the latest computer viruses from sticking around too long.

6. Watch Your Downloads – Part of the fun of the Internet is downloading music, movies and other items. However, since these downloads are so massive, it can be easy to sneak a virus along for the ride. Only download these files from trusted sites that you can count on, or, at the very least, scan them before you open them.

7. Updates, Updates, Updates – There is a reason why Windows has a feature called Critical Updates. There is an entire branch of Microsoft dedicated to staying one step ahead of the hackers out there so when they manage to fix a possible security loophole, you need to download the patch right away. Help Microsoft help you prevent computer viruses from causing too much trouble.

8. Know What To Look For – Even if you are just a casual computer user, you should have an idea of how your machine operates, what normal pop up windows look like and what popular viruses are out there, that way, when your computer begins exhibiting tell tale signs, you’ll know. You can help prevent computer viruses by staying updated and educated.

9. Stay Away From Cracked Software – It is so secret that you can download illegal, cracked versions of some programs online. As tempting as it may be, these files are almost always infested with advanced and difficult to detect bugs. Play it safe and get your software from the source.

10. Install a Firewall – A firewall is a program that screens incoming Internet and network traffic. Along with your virus program, it can help prevent unauthorized access to your computer.

11. Be prepared to Lock Down – If you hear of a virus that is spreading like wildfire through the Internet, make an extra effort to be careful. Don’t open any suspicious emails or accept any downloads for a week or two until your virus protection program has been updated and you are, once again, safe.

How To Remove Shortcut Virus From Pendrives And Memory Cards


All your folders in pendrive/flash drives or memory cards are converted into shortcut icons Most of the people come across this type of issue with their working environment.


Now in this post I will discuss how to clean that virus. For this there is no need of  any antivirus software. If you have not formatted your flash drive then you can solve theis problem.
Just fallow the below steps …..
Click on "Start" -->Run --> type cmd and click on OK.
Here I assume your pen drive letter as K:
Enter this command.
attrib -h -r -s /s /d k:\*.*
You can copy the above command --> Right-click in the Command Prompt and
paste it.
Note : Don't forget to replace the letter k with your pen drive letter.
Now press "Enter".
That’s it!!!!
Now check for your files and folder in Pen Drive.
keep visiting for latest updates…..
If you have any problem while cleaning the virus, feel free to comment below…

Wednesday, 27 February 2013

CLOUD COMPUTING

What is Cloud Computing?

 

Until recently, computing meant a program that ran on a desktop or laptop computer on your desk, or a server in your lab. Or, using the internet, you could use a program that was running on a server somewhere else in the world. But it was always a specific piece of hardware in a specific location that was running the program.
In the context of cloud computing, cloud refers to the internet. And then, cloud computing means that the computing is happening somewhere in the cloud. You don't know where the computing is happening, most of the time, you can't know where it is happening (since it can keep moving around), and the most important factor is that you don't care.
Some service provider is providing you with virtual computers, or virtual disks, or virtual file-systems, or virtual databases, or even higher level constructs (to be described later), and guaranteeing that they will take care of everything related to the virtual hardware that you got - you just need to upload your program and run it.
To understand this better, consider milk. In the old days, everybody had a cow. And they squirted milk out of the cow. And then made butter, buttermilk, paneer, paneer pakodas, and ras-malai from it. But more recently, businesses have sprung up who will deliver you milk in plastic packets at your door, or even butter, paneer pakodas and ras-malai. This model has proved to be so convenient to people (especially those who hate the smell of cow-dung) that very few people now have cows. (If you're a student, and have a cow in your hostel, please let us know - we'd love to hear from you!)
The cow in this example is like the hardware. And milk is the product. Having your own cow is equivalent to traditional computing using your own labs. Getting milk delivered to your door is cloud computing.

How is Cloud Computing Implemented?

 

Cloud computing largely depends upon virtualization technology. Virtualization refers to the technique in which all the capabilities of a piece of hardware are faithfully reproduced in a software program. So, for example, a virtual machine has a virtual CPU, virtual memory and a virtual disk. The virtual CPU might emulate, for example, an Intel x86 chip, and then it is able to take an executable file consisting of x86 instructions and execute them all. This virtual machine thus behaves just like a real machine - you can install an Operating System on it, you can boot into the OS, and then install other programs into the OS that you just installed. You can reboot the machine, power it off, and power it on again, just like real machines.
However, the virtual machine is just an executable program that is stored on some large real machine somewhere. When the executable is run, it behaves like a machine. When the program is shutdown, it saves the entire state of the machine (including contents of the virtual RAM, contents of the virtual disk, contents of the CPU registers, etc) on a file on the real disk of the real machine.
The most interesting thing is that the program and the data of the virtual machine can be copied to another real machine, and when the program is run there, it will behave exactly like the first virtual machine, and continue executing from exactly where it left off. Thus, a key feature of virtual machines are that they can be moved from one real machine to another, and in fact, from one geographic location to another, with very little effort. Advanced virtualization techniques allow this kind of virtual machine migration to be done without requiring the virtual machines to be shutdown - i.e. the virtual machine can move from one location to another while the programs inside the virtual machines continue to run uninterrupted.
VMWare is the leader in building virtual machine software, and Xen is the most important open source alternative to it. There are of course many other smaller players into this market.

Types of Cloud Computing - IaaS, PaaS and SaaS

There are different kinds of cloud computing, but before we understand that we need to understand what is computing. Computing really can be broken up into these pieces:
  • Hardware
    • CPU
    • Memory
    • Disk (File-System, Database)
  • Software
    • Operating System (Linux, Windows, Solaris)
    • Software Development Environment (Visual Studio, Java+Eclipse, Ruby on Rails, Python)
    • The actual programs/applications that people use (Documents, Spreadsheets, Sales Management Software, Customer Relationship Management Software, Accounting Packages, etc)
Each of the things mentioned above can be 'virtualized' and put in the cloud independently. Thus, Amazon EC2 gives a CPU+memory in the cloud. Amazon EBS gives a disk in the cloud, and S3 gives a file-system in the cloud. Microsoft Azure gives a Visual Studio Development environment in the cloud - so that apps developed using Visual Studio can be run 'in the cloud' without you having to worry about the hardware that it runs on. Similarly Google App Engine gives a Java or Python environment in the cloud where you can run your Java/Python apps and they take care of the hardware. Finally, Google Docs is an example of software in the cloud - you directly create documents, presentations, spreadsheets via your web browser. Microsoft too has Office 365, which is their SaaS offering and includes SaaSified versions of Word, Excel, etc. There is no hardware or software to install.
Depending upon what is being virtualized, we get three types of Cloud Computing:
  • IaaS or Infrastructure as a Service: these are various services where the hardware is being virtualized. Virtual machines (i.e. CPU + Memory), virtual disks (e.g. Amazon EBS), virtual file-systems (e.g. Amazon S3), virtual databases (e.g. Google BigTable, Amazon SimpleDB, SQL Azure) are all examples of infrastructure. Basically, these are services that are looking to replace all the hardware infrastructure that sits in your server rooms and labs.
  • PaaS or Platform as a Service: these are various services where the software development platform (i.e. programming language, runtime environment, etc.) is being virtualized. Google AppEngine (Java/Python), Microsoft Azure (.NET/Visual Studio) are examples of PaaS. In the cow & milk example, PaaS would be equivalent to getting paneer or khoya delivered to your home. You can use this to cook your own delicious items.
  • SaaS or Software as a Service: these are various services that have decided to skip the hardware and software engineers altogether and directly approach the end-user with software that s/he wants to use. In IaaS you can install your own OS and software and use it. In PaaS you can write programs in that platform and run them. In SaaS you need to do nothing. There is ready-made software that you can directly start using. Like SalesForce - software used by sales agents. In the cow & milk example, SaaS is equivalent to home-delivery of cooked food (paneer makhanwala and ras-malai).

Advantages of Cloud Computing

There are a number of advantages Cloud Computing has over the old way of doing things:
  • Convenience: Cloud Computing is easy. Not having to deal with real machines, and disk failures, and electricity failures, etc is a huge benefit. Anyone who has had to deal with cleaning cow-dung, going to the vet for treating cow diseases, and complaining neighbours will appreciate the huge convenience of milk packets over having a cow.
  • Cost: There are two different cost advantages to cloud computing. Sometimes it is cheaper than the physical alternative. At other times, the advantage comes from the fact that you have to pay small installments every month instead of a large chunk of money when you're buying the infrastructure.
    • Cheaper: Usually cloud computing turns out to be cheaper. This is mainly because cloud computing providers are able to share their infrastructure across a large number of customers, giving them economies of scale, and higher utilization. You can't buy just half of a physical server, but the typical IaaS provider sells low-end virtual machines which are roughly equivalent to 1/10th of a server.
    • Pay-as-you-go: Imagine you're a startup. Buying a server will cost you $4000. And that's Rs. 2L that you don't really have right now. By contrast, buying compute cycles on Amazon EC2 might cost you $100 per month - which is much more manageable. And at times when you're not really using the server, you shut it off, and don't pay for it. If during a busy month, you need two servers, you get a second server for just one month, and then delete it at the end of the month. Much better than having to buy an entire second server that will be useless after the first month.
  • Easy scalability: If you're a growing company, and the demand for computing suddenly increases (for example, if your website is mentioned in TechCrunch and you suddenly get 10,000 new customers), it is very difficult to suddenly scale up your physical infrastructure. That would involve buying new servers, migrating programs, files, and databases. And a whole bunch of other setup. By contrast, IaaS providers provide these services at the click of a button. PaaS and SaaS providers take care of scaling completely, in a manner transparent to you, and you don't even need to think about it.
  • Location Independence: A cloud computing service can be used from where-ever you are, whereas most physical infrastructure ties you down to one place.
There are a bunch of other advantages, but this should be enough to keep you happy for now. Check out our further reading section if you want more on this.

Important platforms and players in Cloud Computing

In infrastructure as a service, the clear leader is Amazon. EC2 is its service that gives you virtual machines in the cloud on which you can install whatever operating system you want. Amazon has a bunch of other infrastructure as a service offerings, including EBS (virtual hard disks in the cloud), S3 (a simple service that allows you to store and retrieve files), SimpleDB (a non-relational database in the cloud), Amazon Relational Database (did you guess that this is a relational database in the cloud?). It has further offerings in the form of: messaging, queuing services, caching services, content delivery services, monitoring services, load balancing services, ecommerce/payments/billing services. But we'll leave the discussion about those for another day.
The most well-known instance of Platform as a Service is Google's AppEngine which allows programs to be written in Java or Python (or in fact any language written for the JVM, like Scala, Closure, JRuby), with Google BigTable as the corresponding database offering. SalesForce, which revolutionized cloud computing by showing that software-as-a-service can actually make lots of money, is a force to be reckoned with in PaaS space because of their Force.com platform. This requires programming in Apex (a Java-like programming language). SalesForce has also bought Heroku (a Ruby+Rails PaaS provider) so expect more Ruby/Rails here.
Lots of big players are entering the PaaS market. Microsoft is of course in here with Azure that gives .NET in the cloud, and SQL Azure, which essentially gives SQLServer in the cloud. VMWare is jumping in with Cloud Foundry which supports Java (Spring), Ruby (Rails and Sinatra), and JavaScript (Node.js), and MySQL, MongoDB and Redis as databases. Interesting, the code that runs Cloud Foundry is open source. Red Hat has OpenShift, another free PaaS offering that supports a large number of frameworks and languages. Oracle, IBM, and a bunch of startups (like dotCloud, Cumulogic/CloudBees). Amazon is also entering this space with an offering called Elastic Beanstalk - which allows Java deployment in the cloud.
Software as a Service has become so common that it is impossible to make a listing. Pretty much any software that you can think of has a SaaS alternative these days.

How should students get ready for Cloud Computing?

As a student who is soon going to be dumped in the big-bad world, what are the best ways of picking up real-world cloud computing skills? Here are some suggestions:
  • Google AppEngine: This is totally free, and you can use Java (so no need to learn a new language). Just go to the Getting Started with Java on Google AppEngine page, and follow the instructions there. In no time, you will have set up your first AppEngine app. After this, build another app - in some area that you find interesting. Maybe something to do with cricket scores. Or Bollywood movie ratings. Or motorbikes. And build an interesting website, fully in AppEngine. If you're lucky, your site will go viral and Google will take care of the scaling, and you won't have to look for a job!
    • If you are OK with learning a new language, I would highly recommend building AppEngine apps in Python.
  • Amazon EC2: Amazon gives free access to a basic EC2 machine in the cloud for one year. That gives you a full machine of your own, where you are the root user. Get one of these and then use web-based tutorials to do interesting things with this machine - like experimenting with different operating systems (various flavors of linux), installing a firewall, installing a web-server, and other more advanced stuff.
  • If you're into Microsoft Technologies, try out Windows Azure free for 3 months (25 hours of compute time) for free. The tools that you'll need to develop the app (Visual Studio, and local Azure simulator for testing your app) are available for free to students who register for the DreamSpark program. Or, I would suggest forming a student group in your college and getting in touch with Microsoft, and convincing them to offer free Azure for students of your college. I would suggest trying to convince Aditee Rele.

Further Reading

This article just scratches the surface. There are lots of interesting areas to do further research. These could include:
  • Understanding the strengths and weaknesses of IaaS vs Paas vs SaaS
  • Things to worry about when migrating an in-house app to the cloud
  • How to set-up auto-scaling of your cloud app (because auto-scaling is really not so auto)
  • Failure-proofing your app. How to ensure that you survive even if your cloud computing provider has a failure
  • Data Portability and Vendor Lock-In
  • How to estimate the costs of your cloud computing infrastructure (since pricing is a nightmare in the cloud)
  • How to choose a cloud computing provider
  • Worrying about security and local laws
  • Private clouds
  • Cross-platform cloud computing frameworks. These are libraries that allow you to write apps in a way that the same app can run on different cloud computing services.
  • Mobile App Development + Cloud Computing = A match made in heaven
  • Disadvantages of cloud computing
Here are some starting points for your further reading: