Auto Add Country Code in Input field using JavaScript, here are 3 steps to create and add auto country code,

  • Include major CDNs.
  • Create an HTML input field.
  • Include intlTelInput JS to set country code.
  • Create a script to set the code on the selected country.
Image for post
Image for post

We use International Telephone Input JavaScript plugin to get all the country code with country flag.

Know More:

Table of Contents

Include Major CDNs

<link rel=”stylesheet” href=”build/css/intlTelInput.css”>


In Set and Display Session Data in CodeIgniter, first we have to learn a little bit about Session in CodeIgniter.

When we develop a website, we need to track user’s state and activity for this we have to use Session. In CodeIgniter session library or class already available to use. We just initialize it on our program.

Image for post
Image for post

CodeIgniter Session Initialization

Session in CI, session data are globally available through the complete website, if we want to get those data we have to first initialize the session first.


Set Session Data in CodeIgniter

After initialize the session we can set the user’s data. …

The CSS background-image property used to apply the graphic or gradient to the HTML element. Graphics like JPEG, JPG, PNG GIF.

There are also two types of CSS background-image, one is the gradient image and another is a regular image.

Image for post
Image for post
CSS background-image Properties

Table of Contents

Syntax: CSS background-image

Setting background image on HTML <body> element.

body {
background: url(anyImage.jpg);
background-color: #fff;

The url() part of the background image syntax is used for setting the path of the image.

You can also set base64 encoded image URL on…

In HTML we use <a> tag for a hyperlink to another page. For Open URL in New Tab Using JavaScript we use <a> tag target attribute.

In HTML <a> tag’s target attribute provides a simple way to open a new tab or new window of the browser. We use _blank as a value in the target attribute in the anchor tag. Check below,

<a href=”" target=”_blank”>Visit PHPCODER.TECH</a>

Image for post
Image for post

If you want to do the with javascript to open link in a new tab, then we can use the the method as the best option in javascript. method take…

In this article, we discuss How to Embed PDF in Website Using HTML. In HTML there are 3 ways to embed PDF in HTML.

Image for post
Image for post

Table of Contents

3 Ways to Embed PDF in Website using HTML

  1. Using <object> tag.
  2. Using <embed> tag.
  3. Using <iframe> tag

Embed PDF using <iframe> in HTML

Using <iframe> you can set height and width of the PDF.

<iframe src=”PDF_SOURCE_URL” width=”100%” height=”100%”>

HTML tag has some attributes which are used to manage the embed PDF on the HTML <iframe>. Attributes are explained below,

  • src — here you can…

Javascript loop statements or the type of the loops like javascript for loop is used for executing the block of the code number of times.

Syntax: JavaScript For Loop

for ([initialExpression]; [condition]; [incrementExpression])

for (statement 1; statement 2; statement 3) {
// code block to be executed

  • Statement 1 is executed one time before the execution of code blocks.
  • In statement 2 you put the condition for the loop.
  • In statement 3, it is executed after the code block has been executed.
Image for post
Image for post

JavaScript For Loop

Loops are very user-friendly when you want to use the same code again and again with different values you can…

In this, PHP Code work article we less talk about actual programming using PHP. We discuss the execution or behind the scene of PHP Code execution.

Image for post
Image for post

Introduction about PHP

PHP is a scripting language that is mainly used for web application development. Script or scripting languages are capable of executing without compiled.

PHP used by the largest companies and organizations for developing their web-based applications. PHP language is mandatory for a complete understanding of PHP based popular frameworks like,

4 Important Points about PHP Code

  • PHP is an interpreted language.
  • PHP interpreter will load the source code and execute it.
  • The main difference between PHP and other languages like…

Here we are learning about some very basic JavaScript functionality. At the time of Website development, we use NULL which is an assignment value. In JavaScript mostly we getting an error statement called “undefined variable”. Before we start with “Check if JavaScript variable is NULL or Undefined”, first we learn about the difference between NULL or Undefined.

Image for post
Image for post

Difference between JavaScript NULL or JavaScript Undefined

In JavaScript, you can check the variable is Undefined or Null or empty string or has a value. Below are some points for clarifying the difference.

  1. In JavaScript Undefined means, the variable has declared but no value has assigned to it. …

Integrate Google Translate on website is a great way to provide your content all over the world with great content. But as a developer, we have to get that knowledge about how Google Translate works.

Image for post
Image for post

How Google Translate works

If we think that Google has a huge database of words then the answer is “No”.

Generally, Google Translate working is based on “SMT” (statistical machine translation).

  • Means Google gets the data from the user entries and they used to find those words parallel for matching.
  • They take input letters and produce an output sequence of those letters.

Done with a small explanation about…

Here is a most confusing question that, what is the Difference between $ and $$ in PHP. We all know that in PHP programming $ is used for declaring variables or when we write a variable name in PHP, use $ before that name. Today we check the

difference between single dollar ($) and double dollar ($$)

Image for post
Image for post

First thing, in the single dollar ($) stored data is fixed while in the double dollar ($$) is changed dynamically. Variable means are changeable. With explanation variables are those things which are changeable on time.

$var: represnts a variable

$$var (variable’s variable)

Bikash Panda

I am a web application developer. FB Community: @mrpandatech, Twitter: @phpcodertech My PHP problem-solving site

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store