Answer : 3
Key value of ‘true’ will act as 1. So it wil replace the array value from 1 to 3… Read more
Answer : 3
Key value of ‘true’ will act as 1. So it wil replace the array value from 1 to 3… Read more
PHP 7 is a major release of PHP programming language and is touted to be a revolution in the way web applications can be developed and delivered for mobile to enterprises and the cloud.
PHP 7 uses new Zend Engine 3.0 to improve application performance almost twice and 50% better … Read more
Lot of features added to PHP 7, the most significant ones are mentioned below −
Improved performance − Having PHPNG code merged in PHP7, it is twice as fast as PHP 5.
Lower Memory Consumption − Optimized PHP 7 utilizes lesser resource.
Scalar type declarations − Now parameter and return … Read more
In PHP 7, introduced Scalar type declarations, has been . Scalar type declaration has two options −
coercive – coercive is default mode and need not to be specified.
strict – strict mode has to explicitly hinted.
It support gollowing types for function parameters,
int,float,bool,string,interfaces,array,
callable.
HTML5 attributes are case insensitive and may be written in all uppercase or mixed case, although the most common convention is to stick with lowercase.
The attributes listed below are supported by almost all the HTML 5 tags.
Attribute Keyword | Optional Values | Description |
---|---|---|
accesskey | User Defined | Specifies a keyboard shortcut |
A new feature being introduced in HTML 5 is the addition of custom data attributes.
A custom data attribute starts with data- and would be named based on your requirement.
The above will be perfectly valid HTML5 with two custom attributes … Read more
Redis is an open source under BSD licensed, in-memory data structure store, used as a database, cache and message broker. Redis supports data structures such as strings, hashes, lists, sets, sorted sets with range queries, bitmaps, hyperloglogs and geospatial indexes with radius queries.
It is written in ANSI C and … Read more
You need to download the phpredis from redis website https://redis.io/download Once you’ve downloaded it, extract the files to phpredis directory. On Ubuntu, install the following extension.
Add extension in php.ini.
Here is the simple step to connect to Redis server on localhost and retrieve data.
//Connecting to Redis server
$redis = new Redis();
$redis-connect(‘127.0.0.1’, 8001);
echo “Connected to Redis server”;
//set the data
$redis-set(“name”, “Kiran”);
// Get the stored data
echo “Name
Here is the simple step to connect to Redis server on localhost and retrieve list of records.
//Connecting to Redis server
$redis = new Redis();
$redis-connect(‘127.0.0.1’, 8001);
echo “Connected to Redis server !”;
//set the data
$redis-lpush(“students-list”, “Arun”);
$redis-lpush(“students-list”, “Sarath”);