Auto Add Country Code in Input field using JavaScript, here are 3 steps to create and add auto country code,
intlTelInput
JS to set country code.We use International Telephone Input JavaScript plugin to get all the country code with country flag.
Know More: https://github.com/jackocnr/intl-tel-input
Table of Contents
<link rel=”stylesheet” href=”build/css/intlTelInput.css”>
…
Source: https://phpcoder.tech/set-and-display-session-data-in-codeigniter/
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.
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.
$this->load->library(‘session’);
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.
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,
https://phpcoder.tech/open-url-in-new-tab-using-javascript/
<a href=”http://www.phpcoder.tech" target=”_blank”>Visit PHPCODER.TECH</a>
If you want to do the with javascript to open link in a new tab, then we can use the window.open()
the method as the best option in javascript.
window.open() 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.
Table of Contents
<object>
tag.<embed>
tag.<iframe>
tag<iframe>
in HTMLUsing <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,
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.
for ([initialExpression]; [condition]; [incrementExpression])
statement
for (statement 1; statement 2; statement 3) {
// code block to be executed
}
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.
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,
http://phpcoder.tech/check-if-javascript-variable-is-null-or-undefined/
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.
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.
http://phpcoder.tech/how-to-integrate-google-translate-on-website/
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.
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).
http://phpcoder.tech/difference-between-dollar-and-doubledollar-in-php/
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 ($$)
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)…
I am a web application developer. FB Community: @mrpandatech, Twitter: @phpcodertech My PHP problem-solving site http://phpcoder.tech