Javascript The toFixed() Method

Basically toFixed ( ) method is used to cut a number after the decimal upto certain point . Suppose i have a number **i.e 12.345678** and i want this number **upto 2 decimal** places only , then using toFixed method i can cut the number afte...

What is the difference between Parked Domain, Sub Domain & Add-On Domain?

Subdomain: A subdomain is a site with totally different content but with no new domain name. It's a directory inside public_html folder in your server. For example: mydomain.com/mydirectory or mydirectory.mydomain.com. This facility is free of c...

How to remove index.php from Codeigniter

Hello Reader! If you are new to working on Codeigniter Framework for PHP then you are very likely to encounter with the problem of index.php in url. Now we will see how to get resolve this error and then after you do not need to include index.php...

how to access restful webservice using volley library

I have created a restful web service using this tutorial http://www.tutecentral.com/restful-api-for-android-part-1/ after running this i got an auto generated java file which contains the following code public class RestAPI { private fin...

make your number to 2 decimal places round in PHP

Let's consider the example below using the function sprintf $result = 3.146124; echo sprintf("%.3f",$result); output: 3.140 Alternatively, with printf: $result_rounded = sprintf('%0.2f', $result); Output 3.14

Javascript The toExponential() Method

Basically toExponential method is used to convert a number into exponential form . In this method parameter is optional , if you write the parameter then this method do round the number otherwise not . Syntax numObj.toExponential ( [ fractio...

Reliability Testing

What is Reliability Testing ? Reliability testing elaborated distinct from the average of possibility and data. It was primarily a tool to recommendation nineteenth century seafaring life insurance and insurance companies calculate beneficial ...

Struts framework

The Struts Framework is used to develop Web applications or we can say that it is a standard for developing Web applications. Its features are as: 1.It is an open source 2. It is based on the Model-View-Controller (MVC), MVC levels has: ...

How to get the last key of an given array in PHP

Hello Reader! Getting last the key index of any array PHP can be done on several ways as follows:- Lets consider an example array $MyArray $MyArray = array( 'one' => firstelement, 'two' => secondelement, 'three' =>...

toString() Method in javascript

Basically toString ( ) method is used to convert a number into a String .In this there is no argument . Syntax Obj.toString ( ) Simple Example - var number = 15 ; var no = num.toString ( ) ; // Output -> 15 Every Object has ...

How to get the file format/extension of file in PHP

Getting the file format or extension of any file can be done by various ways, In PHP you can use the one way as written bellow $FileName = explode('.', $_FILES['photo']['name']); $FileFormat = end($FileName); Using the explode yo...

Collections in Java

Collection in java can be called as a container, or an object which binds multiple elements into a single unit. Collections in java is a framework used to store, and manipulate group of elements. They represent data items that form a group on ...

Infinity Number in Javascript

Basically Infinity property is a numeric value i.e represent the undefined value . If the value of infinity is very-very small and negative then it would be negative infinity . If the value of infinity is very-very large and positive then it...

marquee tag in HTML

The HTML marquee tag is used to scroll the portion of text written either horizontally or vertically in your web site page. You can also scroll image in similar manner. By default, the direction is left. So, if you will not mention the directi...

onkeyup Event in Javascript

This function gets Executed when a user releases a key on the keyboard. A function is triggered when user releases the key and it transforms character to upper case. Example <p>This is the example of onkeyup event<...

Sorting using Collection

To sort the collection elements Collection class gives us the methods. In case of Set collection, we have TreeSet that can use to set the Set elements. We can sort elements of type String objects, Wrapper class objects and User-defined class...

Covariant Return Type

When return type of the method of super class is different than the return type of method of subclass and it is also a method overriding then it is known as covariant return type. And here the return type is non primitive. I am writing the si...

Android Parse.com Simple Signup

After set up and integrate parse.com on your project the important thing is to sign up or can say create users. Parse provides facility to their users to access their information in a secure manner. ParseUser is the class that handles muc...

Floating Labels for EditText in Material Design

Hi, We can show floating label for EditText by using android design support library. When we input text on EditText, it shows animation by floating labels. TextInputlayout is newly introduced to show floating label on EditText in design ...

Clipboard Android

Android gives us the facility to copy and paste the data by providing clipboard. We can copy text, binary stream, images or other data. Android provides ClipboardManager to handle all this. We have to instantiate the object of ClipboardMana...

How to generate debug SHA1 in android

Here I write command by which we can get debug SHA1 that is use to generate debug SHA1 in android. This SHA1 further use for Google Map V2. Below is the command keytool -list -v -keystore ~/.android/debug.keystore -alias androidde...

Combining two strings together in PHP

Combining of multiple using to add up one single can be achieve by various ways In PHP you can either join then by using (.) Concatenate Operator or by using String Interpolation: We'll do both of way here Let's consider two stings $o...

Display image preview before upload using jQuery

<html> <head> <script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js"></script> </head> <body> <img id="thumbnail" src="test.png" alt="Image"/> ...

Error obtaining UI hierarchy

Sometimes when we try to capture the screenshot using UI Automator Viewer then the following error is displayed and the screenshot is not captured. Error obtaining UI hierarchy Error while obtaining UI hierarchy XML file: com.android.ddmlib...

How to generate QR Code using PHP?

You can create your QR Code using the PHP QR Code library. Download the QR Code library and include in your script file. Example:- <?php include "phpqrcode/qrlib.php"; // create your QR Code with new text and display it QRcode::png...

How to Generate QR Code?

What is QR Code? A QR code (Quick Response Code) is a type of barcode that is readable by dedicated QR readers, iPhone, Android and smartphones. The barcode using encoded information like numbers, letters, and Kanji characters. QR Code is an 2D ...

Working and Benefits of Cloud Computing

Working of cloud computing: In Cloud Computing environment, local computers are no longer required to install heavy applications and software. The network of computers that make up the cloud handles them instead. Hardware and software demand...

What is Cloud Computing?

Cloud computing can be described in simple words as sharing computing resources. Cloud computing opens new avenues to share resources, software, and information with linked computers and other devices as a utility over the Internet. Cloud Computi...

What are magic functions?

PHP have some magic methods that you can use in OOP (Object Oriented Programming). All the magic functions must be identified with twice underscores (__) prefix and they work as interceptors that will run when certain required conditions are met....

CMS vs Framework

CMS A Content Management System (CMS) is a software tool that provides functionalities to manage content like: create, edit, delete, and publish content. The main goal of CMS is to provide user interface for building and editing websites content....

Blur Image View

Hi, How to blur an Imageview and am already tried it using RenderScript, am new to android can anyone tell me for what this library(renderscript v-8) use ?

How to copy a website from local host to a remote host

Below are few ways by which we can copy a website from local to remote server. Upload all files using FTP such as filezilla or winscp just select all files from directory and upload it to remote host HTML directory for domain. Also another wa...

How to resolve "Unable to connect to the database" error?

There are few most common ways to fix database connection errors which are as given below. 1 Need to check Database details such as username or password which is exist in configuration.php is either incorrect or has been changed. 2 Compare ...

Different Menu item type in joomla

Menu item type in Joomla defines type of page which will display when user select any menu item. As menu item is link to that particular page and menu item type determines the type of that page. For eg if user select category list so it list all...

Unable to install any extension in joomla

There are several cause due to which we are unable to install any extensions some are given below. some of the common issues are "Warning! failed to move file" and "JFolder::create: Could not create directory" So following are the list of the st...

Access Denied in spring security 4 even after successful authentication

In spring security after successfull authentication I was getting the Access denied error to go to pages which had the authentication. What I did was. @Override protected void configure(HttpSecurity http) throws Exception { ht...

How to use Flash on Banners in Joomla?

To use flash on Joomla you need to follow the following steps: Login to back-end of joomla site. Select Component -> Banners. You will Banner Manager page. Click on new button on the top left side. You will see a form to add banners. E...

How to add multiple properties file in spring configuration

Here we have configured the spring mvc configuration. In @ComponentScan we can give the path where we have our components(like controller, model, dao etc). For adding the single properties file we use: @PropertySource("classpath:application.p...

How to use the JTable Class

Table is an abstract class which models the database and need to put constructor which declares the table name and primary key and also override some methods. It is used for creating,updating, reading and deleting of records in database. As this...

How to find the current time and timezone using JavaScript?

If you want to find the current time and timezone using JavaScript, you can use below example. In this example, moment.js api has been used. Code: <!DOCTYPE html> <html> <title>TimeZone</title> <script type=...

How to disable csrf spring security 4

In spring security bydefault the csrf protect in on. As a result it asks for token during login and other requests. Although its not a good practise to disable the protection but we can do it. As we can see in the code below, http.csrf().disable...

How to authenticate MD5 password encyption in spring security 4

Whenever we deal with password in an application, we go for some encryption. In spring the password it authenticated within the configuration. Here is the sample code where we have already saved the password in encrypted form and now during lo...

How to make a redirect html page using jQuery

Redirecting a web page will occur in the header part of the page. In JQuery the page redirect have a code and it will go like this below // similar behavior as clicking on a link window.location.href = "http://findnerd.com"; As soon thi...

Methods to recover or reset admin password in Joomla 2.5 and higher versions.

In joomla you can change the password from back-end normally. For this you need to login to your back-end and go to Users -> User Manager. A list of users appear. Click the name of the admin and an edit form will appear. Now from here you can ...

Undefined Vs Null in Java Script

Undefined Vs Null in JavaScript Undefined means a variable has been declared but not assign any value. While null is an assignment value. It can be assigned to a variable that represent no value. For Example: var x; alert(typeof(x));...

ServletRequest Interface with example

The ServletRequest interface have many methods to handle client requests to access a servlet. It is used for access client requests in servlet. HttpServletRequest extends to ServletRequest. Below example will help you to batter understan...

Javascript The setFullYear() Method

In Javascript , setFullYear ( ) method set the full year for a for a given date based on local time . It return a new timestamp . Syntax -> setFullYear( yearValue , monthValue , dayValue ) <br> Parameter -> yearValue -> I...

Stress Testing

What Is Stress Testing? Stress testing is also a kind of performance testing.This testing also comes under the non functional testing. Stress testing is applied to determine the performance of a system or component at or beyond the limits of i...

What is Servlet

Servlet is a part of java technology which used for to create web application. Servlet technology is used at server side and generates dynamic web page. Servlet make robust and scaleable to web application of java language. Before Servlet, We...

MVC Action Results

MVC Action Results:- ActionResult is a return type of a controller method,it's also called an action method. In MVC by default the controller actions will return the ActionResult Object. You can return various types of...
1 214 292