Defect Life Cycle

Defect Life Cycle It indicates the complete life cycle of a defect or a bug right from the stage found, fixed, re-tested and closed. It consist of various status like open/new, assigned, fixed and close/re-open. Open - When we got a bug th...

Download multiple files from media and document in Liferay 6.2

Hello Guys, Liferay store files using media and document which is default functionality of liferay. Liferay support all type file. Below code download files with zip folder using "FileEntryID". NOTE : Liferay fully support to Oracle JDK...

Recovering mysql from backups

Here we will learn how to restore the database from a backup using mysql commands we need to follow the following steps for the process We must have a database dump that we want to restore on the machine with the correct database ...

Creating Select Boxes using form helpers in rails

One of the most common html elements in a web page is select box. In Rails select and option tag helper method is used to display it . select and option tag: <%= select_tag(:city_id, options_for_select[[Bangalore, 1], [Dehradun, 2]]) %&g...

Rails:Populating Select boxes with model data

In model specific form we use select method to display a select box and populate it with model data. Example: #controller @location = Location.new() #view <%= select(:location,:city_id,City.all.collect {|p| [ p.name, p.id ] }) %&g...

Example of Stored Procedure using INOUT mode parameter

Example of Stored Procedure using INOUT mode parameter: INOUT mode is used when you pass and want to get the result using same parameter. Using INOUT mode parameter we can pass the argument to the Stored Procedure and also can get the result wi...

Creating Basic Search Form in Rails

Hi Friends, As we know that, currently there are plenty of content based sites and we usually see a search box within that, to search any topic that is available in that site. So today we will be discussing on how to create a basic search form i...

How to Add and Remove items in array using AngularJS

With the help of Angularjs, We can dynamically add or remove list items in an array. It is shown In the example given below.     Addition of the list items is done using 'push' method and removal of the item is done...

failed to upload image, try again later - Wordpress

When i try to upload an image to a post or a product in my webshop (with woocommerce plugin) i constantly get this error: 'failed to upload image, try again later.' . Does anybody know how to fix this ? Thanks a lot. I already tried increasing...

Geographic Information System

What is GIS: Geographic Information System A geography information system (GIS) is a software tool which is used for analysing and surveying geographic information and occurrence(events) that occurs on Earth. These tools allow users to capture,...

http To https Redirection In ASP.NET

Hello Friend, Many times we need to implement SSL (Secure Socket Layer|) certificate on website for data security. After SSL implementation you don't want to allow page access through http://. If any one try to access website using http://...

Form Helpers in Rails Part-4 (Building Complex Forms)

Hi friends, In my previous blog, we talked about customization of form helpers and how to create forms for external resources through form helpers in Form Helpers in Rails Part-3. Now we will switch to discuss on how to build complex forms in ra...

How to set Cookie() function in JavaScript.

With the help of javascript i have created set Cookie() function. In the below code I have store all the values in the single cookie. By using this function many cookies will store at a time. <script type="text/javascript"> var today ...

Implement Quick Sort using C

Quick Sort Algorithm:- Quick sort is the most famous sorting algorithm. It is the external sorting technique that is based on divide and conquer strategy. The Complexity of this algorithm is following: Best Case:- O(n log n) Average Case:- O...

using head to create header response

While sending an ajax request in rails sometimes we dont need to render any data back to the page . Only status 200 is sufficient to show changes in the view page then we use render :nothing option but there is an alternative to it is head metho...

Form Helpers in Rails Part-3 (Customization and Forms for External Resources)

Hi friends, Previously we talked about form helpers dealing with models in Form Helpers in Rails Part-2. Today we will continue with Form Builders Customizations. As we already discussed that objects from form_for and fields_for are instance of...

Types of Smoke Testing

Smoke Testing Testing the basic and critical features of an application before proceeding with deep rigorous testing is known as Smoke Testing. In Smoke Testing we only test the positive flow of basic and critical features of the application,...

Integration Testing

Integration Testing Testing the data flow or the interface between the modules is known as integration testing. Types of Integration Testing: Incremental Integration Testing. Non-Incremental Integration Testing. Incremental Integ...

How to create Stored Procedure with parameter

Stored Procedures : Stored Procedures are the functions which sits on the database side and provide the services to the user by calling it. Stored Procedures are same as we like functions in our code. Stored Procedures can be created with having ...

Use of Render option in Ruby on Rails

render() method in rails is used for rendering a content to the view . Its uses are: In Controller for rendering an action Example: render :action => "show" This is the most common use of render in controller . The template for sh...

How to pass a variable from php to javascript

Hello reader! There are mane ways to pass a variable from one technology to another technology but if you do want to use PHP, always encode with json_encode before outputting. lets see this quick example <script> var jsvariable ...

Form Helpers in Rails Part-2 (Model Objects)

Hi Friends, In my previous blog Form Helpers in Rails Part-1, we have talked about only the basic form helpers. Today we will be discussing forms with models. As we know in MVC, forms are mostly used for creating, updating or editing models. So...

How to manage Inventory settings in Magento

The product inventory settings can be added in two ways, 1.1) system settings for all the products 1.2) and individually, i.e. you can edit the settings for each product. To access and configure system settings, log into the admin panel, na...

Displaying Cursor Information in MongoDB

As we know cursor in mongoDB can be defined as return value of query run to mongoDB. The information of can be display using cursor.explain() function as show in below: db.collection.find().explain() The explain() method returns a documen...

Send an Email using email component in cakephp

Hello reader if you want to send email using the email component in cakephp you need to run the email component of cakephp ex You should place email send routine in your AppController: function _sendMail($to,$subject,$template) { $th...

How to create JavaScript confirm Model

In the code given below, i have created a javaScript Confirm Model with the help of bootstrap. I also used document ready event handler to trigger the event.Confirm model without a callback isn't particularly useful,but it is entirely possible ...

Form Helpers in Rails Part 1 (Basics)

Hi Friends, In my previous blogs, I have talked about so many topics related to Ruby on Rails. Now today I am going to start form helpers in rails. As all the points can't be covered in one blog, I am dividing it into parts. Today I will be deal...

Creating A PopUp Window in Liferay

The Below Code will show you how you can create the Popup Window in Liferay.we have given the id **patient-popup** to the popup window and enable that window on onclick event of link button. View.jsp <%@ taglib uri="http://java.sun.com/...

How to make pendrive bootable using command prompt for windows?

If you are trying to make Pen-drive bootable, you can do this by using cmd prompt. Follow the below steps- First make sure to insert the usb drive and then go to Command Prompt---> press start+r key to open run and type cmd in to open comm...

Applying partials to layouts in rails

In Rails we can use partials to organize our code in the layouts . This is generally helpful when we have layouts running up to hundreds of lines. For example we have a top nav bar which looks different for logged in and non logged in user. Then ...

How to send sms using Intent ?

This video tutorial tells you about how to send SMS using android intent. For sending an SMS using Implicit Intent, call the intent like this:- // call Intent to send sms Intent intent = new Intent(Intent.ACTION_VIEW, Uri.fromParts("sms", "9...

Exploratory Testing

Exploratory Testing Whenever the requirements does not exists or requirements exists but not clear then we go for something called as exploratory testing. To perform exploratory testing we first explore the application i.e, use all the poss...

Globalization Testing

Globalization Testing Testing the application for different languages and different country format is known as globalization testing. Types of globalization testing: Internationalization or I18N Testing Localization or L1ON I18N ...

How to install android apk file on Emulator in Linux

To install apk file on Emulator Follow the below mentioned steps: 1.Go to platform-tools in android-sdk and Copy the apk file in it. 2.From your Terminal navigate to platform-tools folder in android-sdk. 3.Then use this command ./adb ...

How to Hide RSS link in WooCommerce

If you want to change or hide RSS link in the primary navigation of your WooCommerce website, without getting into the php files. Use below 2 line code to make this possible- #navigation ul.rss {display:none !important} #navigation ul.rss.car...

Use of :as in Passing parameters to rails partials

While passing objects to partial we can change the name of the local variable in the partial and for that purpose we need to use the :as option. For example we have a partial _account.html.erb where we need to pass a collection @cutomers a...

Capturing part of template in variable in RoR

Hi Friends, Sometimes you need to use a small part of a template at so many places and you have to write the same lines of code on separate places and you also don't want to create separate partials for that. Rails gives a solution to your probl...

Number Formatting in RoR Views

Number Formatting in Rails Numbers are of different formats, according to their uses like phone numbers, percentage, currency etc. In Rails NumberHelper fulfills this requirement by providing methods for formatting numbers into different forms. ...

How to add new Columns to table without loosing data of the older version

I am writing this blog to add columns in our database table which would compatible with old version of database. Here I use Alter Table command on my onUpgrade() method where I make condition for the database version. We can add only one column...

Passing parameters to rails partials

While rendering a partial if we want to send parameters to the partial we can do it like this: <%= render :partial => user_profile_list, :locals => { :user => @user } %> or <%= render :partial => "user_profile_list", :...

Benchmark helper in rails

Rails has benchmark helper to quickly test the time of execution of a given piece of code. Active Record, Action Controller and Action View libraries provides a benchmark() method to measure the performance of code. Example: Model(Active Rec...

Atom Feeds in Rails

Hi friends, We have recently talked about auto_discovery_link_tag, that consumes RSS and Atom feeds. Now we are going into deep what is the atom feeds in Rails and how we can achieve that. Lets begin with a defining Atom Feeds. Atom Feeds are ...

Jquery Return false, event.preventdefault and event.stopPropagation

Return False :- Basically returning false is a way to tell your action (like button click event, submit and load etc. ) is not firing. Return false do the three basic things event.preventDefault(); event.stopPropagation(); Stops the call...

Customise a product tab in woocommerce using 'woocommerce_product_tabs' action hook

Hello Friends, The below code will help you to Customize a product tab in woo commerce using 'woocommerce_product_tabs' action hook, first you have to replace the description tab with a custom function. <?php add_filter( 'woocomme...

auto_discovery_link_tag in rails

Hi guys, Today we are going to discuss about auto_discovery_link_tag in rails. It comes under AssetTagHelper, which gives methods for generating HTML that links views to assets(i.e images, JavaScripts, stylesheets, and feeds). For consuming RS...

How main method internally executed by JVM ?

Hi friends, As we know that , if we declare user define method as static, then there is no need to create object of class. We can call method with the help of class name. Syntax for calling the static method: CLASSNAME.METHODNAME(). Sim...

How to hide sort by price option in WooCommerce

Hello friends, If you want to get rid of sort by price option in you Woo-Commerce site. you can use below css code to hide it: .orderby option[value="price"]{ display: none; } Hope this help you.

Performance Testing

Performance Testing Testing the behavior of an application by applying load is known as performance testing. In Performance testing we check for certain factors like: 1.Response Time - The time taken by the server to process the client'...

Cursor In MongoDB

In mongo shell when find() query executed it return cursor with all document in the collection. However, if the returned cursor is not assigned to any variable then first 20 documents iterated automatically. In other word when a query run to m...

Builder templates in ROR and its uses

Action view templates can be written in various ways depending on the format of the response. If the response is in html format then we can use .erb files i.e. html files, with embedded ruby in it. If the format is in xml then we need to use fil...
1 233 292