Thursday, 28 January 2016

Grub rescue in Ubuntu 14.04 (LTS)

My title
If you have a multi-boot machine with Ubuntu 14.04, and mistakenly you have deleted the any partition. Normally your boot loader (Grub generally) goes into rescue mode. And you can not boot your system for any other OS installed on your system.

When you boot your system you get a black screen with grub rescue command prompt like grub rescue> .

Don't worry if you get screen like this.

Just type

grub rescue > ls
output will be like this
(hd0) (hd0,msdos5) (hd0,msdos3) (hd0,msdos2) (hd0,msdos1) (hd1) (hd1,msdos1)
then type
grub rescue > ls (hd0,msdos1)
output may be
Unknown filesystem

try above command with all partitions until you get output like 
file system is ext4 or any other valid linux file type

grub rescue > ls (hd0,msdos2) # let's assume this is the linux partition
grub rescue > set root=(hd0,msdos2)
grub rescue > set prefix=(hd0,msdos2)/boot/grub 
grub rescue > insmod normal 
grub rescue > normal

Noe you system will boot in normal grub boot mode. You will have to run these commands on every boot up until you repair or reinstall your grub boot loader.

Sunday, 18 October 2015

Customize Textbox, List/Menu, Button or Div border style

My title
You can customize Textbox, List/Menu or Div using CSS.

All input can be rounded and with border color:

CSS:-

input{
border-radius: 8px;
border-color: #98bf21;
}

HTML:-

<input type="text" name="username" placeholder="Enter Password" required />

<input type="submit" name="Submit" value="Login" style="width:150px;"/>

 <select name="select2" id="select2">
          <option>Select Scheduled Month</option>
          <option>January</option>
          <option>February</option>
          <option>March</option>
          <option>April</option>
          <option>May</option>
          <option>June</option>
          <option>July</option>
          <option>August</option>
          <option>September</option>
          <option>October</option>
          <option>November</option>
          <option>December</option>
        </select>


Output:-






Thursday, 27 August 2015

Customize your Ubuntu/Linux Environment using "CompizConfig Settings Manager,

My title

Compiz is a compositing manager, which means that it enhances the overall user interaction by adding fancy effects to your windows, from drop shadows to awesome desktop effects like the Desktop Cube or the Expo view.

Compiz can also be a window manager, which means that it is the software between you and your desktop apps. It enables you to move or resize windows, to switch workspaces, to switch windows easily (using alt-tab or so), and so on.

How to install

1. you can download from launchpad website or www.compiz.org.



                                                                             OR



Remember this package depends on :-

Package relationships
So your system should have these packages before installing this package.

2. Then install deb package using terminal


 sudo dpkg -i compizconfig-settings-manager_0.9.11+14.04.20140409-0ubuntu1_all.deb



3 All done.

4. Now use it very carefully otherwise you can dump your desktop.


You will also need to install compiz plugins. Run the following command -

sudo apt-get install compiz compizconfig-settings-manager compiz-plugins

Good Luck !!!!

References:-
http://askubuntu.com/questions/449651/how-do-i-enable-wobbly-windows
https://launchpad.net/ubuntu/trusty/+package/compizconfig-settings-manager
http://www.compiz.org/

Sunday, 19 July 2015

Evolution of Java & Version History

My title

Evolution of Java & Version History

Since, Java is known for the language of Internet. But originally it was not developed for Internet. Its primary purpose was to develop a language that would the platform-independent (i.e. architecture neutral). Java was invented to create software that could be embedded in consumer electronic devices, such as microwave ovens and remote controls.
Java was developed in 18 months by James Gosling, Patrick Naughton and et all at Sun Microsystem in 1991. It was initially called "Oak". But, come in market in 1995 by the name "Java".
So, what was the need of platform independent language?
Contrary to Java, most of languages require specific architecture to run. However it is possible that any language can compile on any architecture, but it requires a compiler that is targeted for that CPU or architecture.
Was the java team only considered about portable programs?
It is not true that only java team considered about a portable program. At early stage of programming, most of the programmers learn that portable programs are desirable. The computer world at that time was divided into three competing camps Intel, Macintosh & UNIX. Programmers are bounded in their boundaries hence; urgent need of portable program was reduced.
But after invent of World Wide Web and presence of diverse computers, operating systems & CPU, need of portable program one again returned with a vengeance. And low-priority problem had become the high-profile necessity.
About Java
Many people think that, Java is enhanced version of C++ because of similarity between them. But expert think that it would be a large mistake. Java is differing practically & philosophically from C++. While it is true that it was influenced by C++.
Java is a high-level programming language as well as a platform.
The Java programming language is designed to meet the challenges of application development in the context of heterogeneous, network-wide distributed environments. Paramount among these challenges is secure delivery of applications that consume the minimum of system resources, can run on any hardware and software platform, and can be extended dynamically.
The Java programming language originated as part of a research project to develop advanced software for a wide variety of network devices and embedded systems. The goal was to develop a small, reliable, portable, distributed, real-time operating platform. When the project started, C++ was the language of choice. But over time the difficulties encountered with C++ grew to the point where the problems could best be addressed by creating an entirely new language platform. Design and architecture decisions drew from a variety of languages such as Eiffel, SmallTalk, Objective C, and Cedar/Mesa. The result is a language platform that has proven ideal for developing secure, distributed, network-based end-user applications in environments ranging from network-embedded devices to the World-Wide Web and the desktop.
[James Gosling, 1996]
Java Versions
1995 – JDK alpha & beta was highly unstable.
23 Jan 1996 – JDK 1.0 Originally called Oak.
19 Feb 1997 – JDK 1.1 JIT compiler released for Microsoft Windows Platform.
8 Dec 1998 – J2SE 1.2 Codename Playground, from here to JDK 1.5 it was re-branded as Java 2     followed by version like J2SE 1.2.
8 May 2000 – J2SE 1.3 Codename Kestrel with HotSpot.
6 Feb 2002- J2SE 1.4 Codename Merlin.
30 Sep 2004- J2SE 5.0 Codename Tiger, Originally numbered 1.5. The number was changed to "better reflect the level of maturity, stability, scalability and security of the J2SE."
11 Dec 2006 – JSE 6 Codename Mustang, Sun replaced the name J2SE to JSE and Sun was take over by Oracle but internal numbering for developers will remain as 1.6.0.
28 Jul 2011 – JSE 7 Codename Dolphin. Java 7 was the default version to download on java.com from April 2012 until Java 8 was released.
18 Mar 2014 – JSE 8 Language-level support for lambda expression under Project Lambda and default methods (virtual extension methods) which make multiple inheritance possible in Java. And implementation of multiple inheritance more precisely. It also allows embed JavaScript code within applications. Java 8 has been the default version to download from the official website.
22 Sep 2016 – JSE 9 might be released.

References:-
1.https://docs.oracle.com/javase/tutorial/getStarted/intro/definition.html.
2.Java 2 The Complete Reference by Herbert Schildt.
 3.The Java Language Environment , a white paper written by James Gosling and Henry McGilton.
4.https://en.wikipedia.org/wiki/Java_version_history#cite_note-JDK7-96

Change image source dynamically on hyperlink

 Changing image source dynamically using JQuery. Here in this example I have created there hyperlink and stored all images in the same folde...