Top 50 PHP Blogs And Websites for PHP Developers To Follow in 2019

PHP Blogs List.
The Best PHP blogs from thousands of top PHP blogs in our index using search and social metrics. Data will be refreshed once a week. Also check out Top PHP Youtube Channels list for Top videos on PHP.

1. Planet PHP Blog

Planet PHP Blog

About Blog Planet PHP Blog covers all PHP news in one place. A close to complete list of all important PHP related weblogs.
Frequency about 8 posts per week.
Blog planet-php.net
Facebook fans n/a. Twitter followers 63,700.View Latest Posts ▸

2. Reddit – PHP: The latest news in the PHP world

Reddit - PHP: The latest news in the PHP world

About Blog Ask questions about frameworks, try your hand at php golf and strike gold or simply show off your latest work.
Frequency about 56 posts per week.
Blog reddit.com/r/PHP
Facebook fans 1,285,479. Twitter followers 629,358.View Latest Posts ▸

3. The Zend Blog

The Zend Blog

About Blog Read the latest PHP trends and best practices in the world of cloud, mobile and web application development on the Zend blog, featuring thought leaders from the PHP community
Frequency about 2 posts per month.
Blog blog.zend.com
Facebook fans 51,466. Twitter followers 47,715.View Latest Posts ▸

4. PHP Classes Blog

PHP Classes Blog

About Blog Follow PHPClasses for early insights about upcoming site features. Free ready to use contributed PHP class scripts, book reviews, jobs, specialist forums.
Frequency about 1 post per week.
Blog phpclasses.org/blog
Facebook fans n/a. Twitter followers 47,690.View Latest Posts ▸

5. Laravel News

Laravel News

About Blog Laravel News is the official blog of Laravel. Every day bringing you the latest news, tutorials, and packages for the framework.
Frequency about 5 posts per week.
Blog laravel-news.com/blog
Facebook fans 28,990. Twitter followers 58,666.View Latest Posts ▸

6. Simpliv blog

simpliv logo icon - Copy.png

Simpliv blog is the place to be for an aspiring PHP developer. You will find hands-on guides and tutorials in the best possible way. You get useful and practical skills, and tactics that will help you to enhance your programming skills. Simpliv blog is one of the very few sites that has published videos on PHP programming.

Frequency about 5 posts per week.

Blog https://blog.simpliv.com/

7. Symfony Blog

Symfony Blog

About Blog Symfony is an Open Source PHP Web applications development framework. It was originally conceived by the interactive agency Sensio Labs for the development of web sites for its own customers.
Frequency about 5 posts per week.
Blog symfony.com/blog
Facebook fans 1,906. Twitter followers 34,671.View Latest Posts ▸

8. Voices of the ElePHPant

Voices of the ElePHPant

About Blog Interviews with the people that are making the PHP community special.
Frequency about 3 posts per month.
Blog voicesoftheelephpant.com
Facebook fans n/a. Twitter followers 10,309.View Latest Posts ▸

9. PHPpot Tutorial – Vincy

PHPpot Tutorial - Vincy

About Blog PhpPot is a PHP code and tutorials blog passionately published by Vincy. PHP, jQuery, WordPress, MySql, Ajax are the main technologies in focus here. You can find code to make your web applications better.
Frequency about 1 post per week.
Blog phppot.com
Facebook fans 1,358. Twitter followers 142.View Latest Posts ▸

10. PhpStorm Blog – JetBrains PhpStorm

PhpStorm Blog - JetBrains PhpStorm

About Blog The most intelligent PHP IDE with refactorings, code completion, on-the-fly code analysis and coding productivity orientation.
Frequency about 1 post per week.
Blog jetbrains.com/phpstorm
Facebook fans 96,860. Twitter followers 103,161.View Latest Posts ▸

11. Laravel Daily

Laravel Daily

About Blog This blog shares Laravel framework daily tips, articles and news.
Frequency about 2 posts per week.
Blog laraveldaily.com/blog
Facebook fans 1,884. Twitter followers 6,255.View Latest Posts ▸

12. Code-diesel Blog

Code-diesel Blog

About Blog This blog shares Articles, tutorials and ideas on web development. The ideas are about software in general and php/mysql in particular.
Frequency about 2 posts per month.
Also in Software Development Blogs
Blog codediesel.com
Facebook fans 927. Twitter followers 147.View Latest Posts ▸

13. murze.be Blog – Freek Van der Herten

murze.be Blog - Freek Van der HertenAntwerp, BelgiumAbout Blog A blog on modern PHP and Laravel. Freek Van der Herten is a Laravel enthousiast and PHP developer at Spatie
Frequency about 5 posts per week.
Also in Laravel Framework Blogs
Blog murze.be
Facebook fans n/a. Twitter followers 14,566.View Latest Posts ▸

14. Rob Allen’s DevNotes

Rob Allen's DevNotes

About Blog Rob is a PHP and Zend Framework expert based in Worcester, UK. He runs Nineteen Feet, is the author of Zend Framework in Action.
Frequency about 2 posts per month.
Blog akrabat.com
Facebook fans n/a. Twitter followers 14,092.View Latest Posts ▸

15. PHPGurukul | PHP Projects with Source Code

PHPGurukul | PHP Projects with Source Code

About Blog PHP GURUKUL is a vision to provide free and easy education to everyone over the web. We have an aim to educate and provide you the power to make website anything. Anytime. We don’t teach, we educate. We provide Tutorials for many Programming languages on PHP GURUKUL.
Frequency about 1 post per week.
Blog phpgurukul.com
Facebook fans 14,292. Twitter followers 1,388.View Latest Posts ▸

16. PHPDeveloper.org

PHPDeveloper.org

About Blog This is all about Up-to-the Minute PHP News, views and community.
Frequency about 19 posts per week.
Blog phpdeveloper.org
Facebook fans n/a. Twitter followers 48,744.View Latest Posts ▸

17. Paul M. Jones

Paul M. Jones

About Blog Paul M. Jones is an internationally recognized PHP expert, working in that language since 1999, and programming in general since 1983. He has held roles from junior developer to VP of Engineering in all kinds of organizations (corporate, military, non-profit, educational, medical, and others). He is a regular speaker at technical conferences worldwide.
Frequency about 1 post per month.
Blog paul-m-jones.com
Facebook fans n/a. Twitter followers 5,420.View Latest Posts ▸

18. PHP KOLKATA Blog

PHP KOLKATA Blog

About Blog PHPKolkata is one of the best php training institute and placement consultancy in kolkata.
Frequency about 1 post per week.
Blog phpkolkata.com/blog
Facebook fans 3,157. Twitter followers 40.View Latest Posts ▸

19. PHP Magazine

PHP Magazine

About Blog PHP Magazine is an online magazine about PHP programming language and web application development technologies. Since 2015, their network of 25 Magazines merged in a single magazine to keep focused on just important information.
Frequency about 2 posts per week.
Blog phpmagazine.net
Facebook fans 1000. Twitter followers 2,469.View Latest Posts ▸

20. Exakat – Turn PHP into Analytics

Exakat - Turn PHP into Analytics

About Blog Exakat is an Open Source PHP Code Analysis Engine and an Open Content Rules Library designed for PHP developers looking for efficient answers to their code quality needs
Frequency about 3 posts per month.
Blog exakat.io/community/blog
Facebook fans n/a. Twitter followers 806.View Latest Posts ▸

21. Bootsity | PHP, Laravel, Angular and Web Development Tutorials

Bootsity | PHP, Laravel, Angular and Web Development Tutorials

About Blog PHP, Laravel, Angular and Web Development Tutorials and Interview Questions. Easy to follow tutorials. Interview Questions and Answers ebooks. Bootsity is a technical site focused on the PHP, Laravel and Angular ecosystem. We publish tutorials, blogs and in-depth with a strong focus on to the point concepts and ready-to-run code.
Frequency about 2 posts per month.
Blog bootsity.com
Facebook fans 746. Twitter followers 25.View Latest Posts ▸

22. PHP UK Conference

About Blog PHP UK Conferences are held annually at the end of February each year, in the capital city of London. Attended by hundreds of delegates, speakers, sponsors, partners and volunteer assistants, they are run by volunteers from the PHP community and elected committee members of PHP London.
Frequency about 8 posts per week.
Since Mar 2011
Also in PHP Youtube Channels
Blog youtube.com/user/phpukconfer..
Facebook fans 1,213. Twitter followers 5,727.View Latest Posts ▸

23. Matthias Noback Blog

Matthias Noback Blog

About Blog Matthias Noback is a professional PHP developer, skilled in most of the tried and proven web development languages, i.e. the big ones: PHP, MySQL, HTML, CSS and JavaScript.
Frequency about 2 posts per month.
Blog php-and-symfony.matthiasnoba..
Facebook fans n/a. Twitter followers 6,338.View Latest Posts ▸

24. PHP CORE LAB

PHP CORE LAB

About Blog Quick reference for PHP best practices, PHP tutorials around the Web, PHP programming, PHP and MySQL.
Frequency about 1 post per month.
Blog phpcorelab.com
Facebook fans 17. Twitter followers n/a.View Latest Posts ▸

25. Adam Culp – Geeky Boy Technology Blog

Adam Culp - Geeky Boy Technology Blog

About Blog Geeky Boy (Adam Culp) a South Florida PHP developer shares PHP, MySQL, programming, and other knowledge while posting personal discoveries to remember later.
Frequency about 1 post per month.
Blog geekyboy.com
Facebook fans 55. Twitter followers 3,779.View Latest Posts ▸

26. PHPCluster Blog

PHPCluster Blog

About Blog PHPCluster is a programming blog maintained By author Vikash Kumar Singh. PHPCluster is a tutorial blog all about php,programming, jquery, javascript, ajax, demos, mysql.
Frequency about 2 posts per week.
Blog phpcluster.com
Facebook fans 795. Twitter followers 730.View Latest Posts ▸

27. Lipku

Lipku

About Blog Lipku.com is a programming blog. here i write the tutorials for PHP, mysql, javascript, jquery, ajax, facebook api, google api and many more. For more updates on these, subscribe with us.
Frequency about 1 post per month.
Blog lipku.com
Facebook fans 396. Twitter followers 518.View Latest Posts ▸

28. SKPTRICKS – Programmer Hub

SKPTRICKS - Programmer Hub

About Blog Welcome to skptricks I have written and developed this site so that Learner may learn computer technologies and various programming languages easily.
Frequency about 4 posts per week.
Blog skptricks.com
Facebook fans 1,841. Twitter followers 256.View Latest Posts ▸

29. Matthew Weierophinney

Matthew Weierophinney

About Blog Matthew Weierophinney is an open source software architect, specializing in PHP. He is a Zend Certified Engineer, and a member of the Zend Education Advisory Board, the group responsible for authoring the Zend Certification Exam.
Frequency about 1 post per month.
Blog mwop.net/blog
Facebook fans n/a. Twitter followers 15,482.View Latest Posts ▸

30. Matt Stauffer on Laravel, PHP, Frontend development

Matt Stauffer on Laravel, PHP, Frontend development

About Blog Matt Stauffer is a developer and a communicator, and Partner/Technical Director at Tighten Co.
Frequency about 1 post per month.
Blog mattstauffer.co/blog
Facebook fans n/a. Twitter followers 21,959.View Latest Posts ▸

31. PHP Development – PHP Blog

PHP Development - PHP Blog

About Blog PHPDevelopment.net offers Professional PHP Development services in the United States. Their U.S. Based PHP Developers provide Enterprise level solutions.
Frequency about 1 post per week.
Blog phpdevelopment.net/php-blog
Facebook fans n/a. Twitter followers n/a.View Latest Posts ▸

32. Sebastian Bergmann

Sebastian Bergmann

About Blog Sebastian Bergmann is the creator of PHPUnit, a de-facto standard in the field of quality assurance in PHP projects. He is a Co-Founder and Principal Consultant with thePHP.cc and offers consulting, training, and coaching services to help enterprises improve the quality assurance process for their PHP-based software projects.
Frequency about 1 post per month.
Blog sebastian-bergmann.de
Facebook fans n/a. Twitter followers 17,417.View Latest Posts ▸

33. The Code Developer Programming Blog

The Code Developer Programming Blog

About Blog The Code Developer is a Programming Blog Maintained by Vikas Tyagi. Tutorials focused on programming, PHP, MySQL, WordPress, Web Development, Web Design.
Frequency about 3 posts per month.
Blog thecodedeveloper.com
Facebook fans 1,838. Twitter followers 33.View Latest Posts ▸

34. eTatvaSoft

eTatvaSoft

About Blog eTatvaSoft is a PHP Web Development company provides PHP Application and Open Source Application Development services around the world.
Frequency about 1 post per week.
Blog etatvasoft.com/blog
Facebook fans n/a. Twitter followers 129.View Latest Posts ▸

35. PHP Clicks

PHP Clicks

About Blog PHP Clicks is a blog for advanced interactive tutorials. It covers HTML, CSS, jQuery, Angular JS, HTML5, CSS3, JavaScript, PHP, MySQL, WordPress, and much more.
Frequency about 1 post per month.
Blog phpclicks.com
Facebook fans 104. Twitter followers 22.View Latest Posts ▸

36. PHP – Sunil

PHP - Sunil

About Blog Find Post on PHP.
Frequency about 1 post per month.
Blog phpsunil.blogspot.com
Facebook fans n/a. Twitter followers n/a.View Latest Posts ▸

37. urmaul.com

urmaul.com

About Blog My name is Bogdan. I live in Berlin and I develop things for the Internet. One time I’ll white here something more.
Frequency about 1 post per month.
Since May 2014
Blog urmaul.com
Facebook fans n/a. Twitter followers n/a.View Latest Posts ▸

38. David Craig PHP Developer

David Craig PHP Developer

About Blog A PHP Developer from the north east of England. Expert in Laravel and WordPress.
Frequency about 1 post per month.
Blog davidcraig.eu/blog
Facebook fans n/a. Twitter followers 3,822.View Latest Posts ▸

39. My Programming Tutorials

My Programming Tutorials

About Blog My Programming Tutorials is one stop solution for passionate programmers which provides various tricks and tutorials on mobile app development, ionic framework, codeigniter, jquery and web development.
Frequency about 1 post per month.
Blog myprogrammingtutorials.com
Facebook fans 358. Twitter followers 55.View Latest Posts ▸

40. Adam Wathan’s Blog

Adam Wathan's Blog

About Blog Adam Wathan is a a software developer, writer, speaker, and entrepreneur from Ontario, Canada. He is the creator of Nitpick CI, author of Refactoring to Collections, and host of the Full Stack Radio podcast.
Frequency about 1 post per month.
Blog adamwathan.me
Facebook fans n/a. Twitter followers 35,921.View Latest Posts ▸

41. SitePoint – PHP

SitePoint - PHP

About Blog Learn PHP with online tutorials, courses and books plus articles from industry experts covering MySQL, Laravel, Symfony, TDD, Restful APIs and more.
Frequency about 2 posts per week.
Blog sitepoint.com/php
Facebook fans 101,576. Twitter followers 126,746.View Latest Posts ▸

42. Laravel Interview Questions

Laravel Interview Questions

About Blog LaravelInterviewquestions.com is a website that provides you latest interviews questions and answers on laravel.
Frequency about 2 posts per month.
Blog laravelinterviewquestions.com
Facebook fans 123. Twitter followers n/a.View Latest Posts ▸

43. Colin O’Dell Blog

Colin O'Dell Blog

About Blog Colin O’Dell is a Web Developer, author, speaker, and open-source project maintainer.
Frequency about 1 post per month.
Blog colinodell.com/blog
Facebook fans n/a. Twitter followers 3,711.View Latest Posts ▸

44. PHP Hurdles – Helping Hands for PHP Developers

PHP Hurdles - Helping Hands for PHP Developers

About Blog PHP Hurdles aims in helping the PHP Developer in their day to day development struggles and challenges faced by them. They are aware of the common struggles of a PHP Developer in his initial days and thus we have created a bucket full of snippets to help them out.
Frequency about 1 post per month.
Blog phphurdles.com
Facebook fans 1,849. Twitter followers n/a.View Latest Posts ▸

45. Phpflow.com – PHP

Phpflow.com - PHP

About Blog This blog contains all PHP related tutorials and articles. You can download php script and see live demo of php tutorial.
Frequency about 2 posts per month.
Blog phpflow.com/php
Facebook fans 14,602. Twitter followers 272.View Latest Posts ▸

46. Stefan Mischook – KillerPHP.com

Stefan Mischook - KillerPHP.com

About Blog Stefan Mischook blog is for to teach PRACTICAL PHP to non-nerd web designer types. With the recent release of PHP7 in 2016, PHP continues to prove that it is a powerful programming language.
Frequency about 1 post per month.
Blog killerphp.com/articles
Facebook fans 1,598. Twitter followers 3,437.View Latest Posts ▸

47. Fabien Potencier

Fabien Potencier

About Blog The blog of Fabien Potencier about web technology and the symfony framework.
Frequency about 1 post per month.
Blog fabien.potencier.org
Facebook fans n/a. Twitter followers 40,513.View Latest Posts ▸

48. Qafoo – PHP Hypertext Processor

Qafoo - PHP Hypertext Processor

About Blog Qafoo GmbH provides Training, Consulting and Support for Quality Assurance Processes and various quality assurance tools like PHP_Depend, PHPMD, Arbit and PhpUnderControl.
Frequency about 1 post per month.
Blog qafoo.com/blog/php.html
Facebook fans 213. Twitter followers 735.

Advertisements

Top 100 PHP Interview Questions and Answers

PHP is the most popular scripting language on the web. Without PHP Facebook, Yahoo, Google wouldn’t have exist. The course is geared to make you a PHP pro. Once you digest all basics, the course will help you create your very own Opinion Poll application.

1) What is PHP?

PHP is a web language based on scripts that allow developers to dynamically create generated web pages.

2) What do the initials of PHP stand for?

PHP means PHP: Hypertext Preprocessor.

3) Which programming language does PHP resemble?

PHP syntax resembles Perl and C

4) What does PEAR stand for?

PEAR means “PHP Extension and Application Repository”. It extends PHP and provides a higher level of programming for web developers.

5) What is the actually used PHP version?

Version 7.1 or 7.2 is the recommended version of PHP.

6) How do you execute a PHP script from the command line?

Just use the PHP command line interface (CLI) and specify the file name of the script to be executed as follows:

php script.php

7) How to run the interactive PHP shell from the command line interface?

Just use the PHP CLI program with the option -a as follows:

php -a

8) What is the correct and the most two common way to start and finish a PHP block of code?

The two most common ways to start and finish a PHP script are:

 <?php [   ---  PHP code---- ] ?> and <? [---  PHP code  ---] ?>

9) How can we display the output directly to the browser?

To be able to display the output directly to the browser, we have to use the special tags <?= and ?>.

10) What is the main difference between PHP 4 and PHP 5?

PHP 5 presents many additional OOP (Object Oriented Programming) features.

11) Is multiple inheritance supported in PHP?

PHP supports only single inheritance; it means that a class can be extended from only one single class using the keyword ‘extended’.

12) What is the meaning of a final class and a final method?

‘final’ is introduced in PHP5. Final class means that this class cannot be extended and a final method cannot be overridden.

13) How is the comparison of objects done in PHP?

We use the operator ‘==’ to test is two objects are instanced from the same class and have same attributes and equal values. We can test if two objects are referring to the same instance of the same class by the use of the identity operator ‘===’.

14) How can PHP and HTML interact?

It is possible to generate HTML through PHP scripts, and it is possible to pass pieces of information from HTML to PHP.

15) What type of operation is needed when passing values through a form or an URL?

If we would like to pass values through a form or an URL, then we need to encode and to decode them using htmlspecialchars() and urlencode().

16) How can PHP and Javascript interact?

PHP and Javascript cannot directly interact since PHP is a server side language and Javascript is a client-side language. However, we can exchange variables since PHP can generate Javascript code to be executed by the browser and it is possible to pass specific variables back to PHP via the URL.

17) What is needed to be able to use image function?

GD library is needed to execute image functions.

18) What is the use of the function ‘imagetypes()’?

imagetypes() gives the image format and types supported by the current version of GD-PHP.

19) What are the functions to be used to get the image’s properties (size, width, and height)?

The functions are getimagesize() for size, imagesx() for width and imagesy() for height.

20) How failures in execution are handled with include() and require() functions?

If the function require() cannot access the file then it ends with a fatal error. However, the include() function gives a warning, and the PHP script continues to execute.

21) What is the main difference between require() and require_once()?

require(), and require_once() perform the same task except that the second function checks if the PHP script is already included or not before executing it.

(same for include_once() and include())

22) How can I display text with a PHP script?

Two methods are possible:

<!--?php echo "Method 1"; print "Method 2"; ?-->

23) How can we display information of a variable and readable by a human with PHP?

To be able to display a human-readable result we use print_r().

24) How is it possible to set an infinite execution time for PHP script?

The set_time_limit(0) added at the beginning of a script sets to infinite the time of execution to not have the PHP error ‘maximum execution time exceeded.’ It is also possible to specify this in the php.ini file.

25) What does the PHP error ‘Parse error in PHP – unexpected T_variable at line x’ means?

This is a PHP syntax error expressing that a mistake at the line x stops parsing and executing the program.

26) What should we do to be able to export data into an Excel file?

The most common and used way is to get data into a format supported by Excel. For example, it is possible to write a .csv file, to choose for example comma as a separator between fields and then to open the file with Excel.

27) What is the function file_get_contents() useful for?

file_get_contents() lets reading a file and storing it in a string variable.

28) How can we connect to a MySQL database from a PHP script?

To be able to connect to a MySQL database, we must use mysqli_connect() function as follows:

<!--?php $database = mysqli_connect("HOST", "USER_NAME", "PASSWORD"); mysqli_select_db($database,"DATABASE_NAME"); ?-->

29) What is the function mysql_pconnect() useful for?

mysql_pconnect() ensure a persistent connection to the database, it means that the connection does not close when the PHP script ends.

This function is not supported in PHP 7.0 and above

30) How be the result set of Mysql handled in PHP?

The result set can be handled using mysqli_fetch_array, mysqli_fetch_assoc, mysqli_fetch_object or mysqli_fetch_row.

31) How is it possible to know the number of rows returned in the result set?

The function mysqli_num_rows() returns the number of rows in a result set.

32) Which function gives us the number of affected entries by a query?

mysqli_affected_rows() return the number of entries affected by an SQL query.

33) What is the difference between mysqli_fetch_object() and mysqli_fetch_array()?

The mysqli_fetch_object() function collects the first single matching record where mysqli_fetch_array() collects all matching records from the table in an array.

34) How can we access the data sent through the URL with the GET method?

To access the data sent via the GET method, we use $_GET array like this:

www.url.com?var=value
$variable = $_GET["var"]; this will now contain 'value'

35) How can we access the data sent through the URL with the POST method?

To access the data sent this way, you use the $_POST array.

Imagine you have a form field called ‘var’ on the form when the user clicks submit to the post form, you can then access the value like this:

$_POST["var"];

36) How can we check the value of a given variable is a number?

It is possible to use the dedicated function, is_numeric() to check whether it is a number or not.

37) How can we check the value of a given variable is alphanumeric?

It is possible to use the dedicated function, ctype_alnum to check whether it is an alphanumeric value or not.

38) How do I check if a given variable is empty?

If we want to check whether a variable has a value or not, it is possible to use the empty() function.

39) What does the unlink() function mean?

The unlink() function is dedicated for file system handling. It simply deletes the file given as entry.

40) What does the unset() function mean?

The unset() function is dedicated for variable management. It will make a variable undefined.

41) How do I escape data before storing it in the database?

The addslashes function enables us to escape data before storage into the database.

42) How is it possible to remove escape characters from a string?

The stripslashes function enables us to remove the escape characters before apostrophes in a string.

43) How can we automatically escape incoming data?

We have to enable the Magic quotes entry in the configuration file of PHP.

44) What does the function get_magic_quotes_gpc() means?

The function get_magic_quotes_gpc() tells us whether the magic quotes is switched on or no.

45) Is it possible to remove the HTML tags from data?

The strip_tags() function enables us to clean a string from the HTML tags.

46) what is the static variable in function useful for?

A static variable is defined within a function only the first time, and its value can be modified during function calls as follows:

<!--?php function testFunction() { static $testVariable = 1; echo $testVariable; $testVariable++; } testFunction();        //1 testFunction();        //2 testFunction();        //3 ?-->

47) How can we define a variable accessible in functions of a PHP script?

This feature is possible using the global keyword.

48) How is it possible to return a value from a function?

A function returns a value using the instruction ‘return $value;’.

49) What is the most convenient hashing method to be used to hash passwords?

It is preferable to use crypt() which natively supports several hashing algorithms or the function hash() which supports more variants than crypt() rather than using the common hashing algorithms such as md5, sha1 or sha256 because they are conceived to be fast. Hence, hashing passwords with these algorithms can create vulnerability.

50) Which cryptographic extension provide generation and verification of digital signatures?

The PHP-OpenSSL extension provides several cryptographic operations including generation and verification of digital signatures.

51) How is a constant defined in a PHP script?

The define() directive lets us defining a constant as follows:

define ("ACONSTANT", 123);

52) How can you pass a variable by reference?

To be able to pass a variable by reference, we use an ampersand in front of it, as follows $var1 = &$var2

53) Will a comparison of an integer 12 and a string “13” work in PHP?

“13” and 12 can be compared in PHP since it casts everything to the integer type.

54) How is it possible to cast types in PHP?

The name of the output type has to be specified in parentheses before the variable which is to be cast as follows:

* (int), (integer) – cast to integer

* (bool), (boolean) – cast to boolean

* (float), (double), (real) – cast to float

* (string) – cast to string

* (array) – cast to array

* (object) – cast to object

55) When is a conditional statement ended with endif?

When the original if was followed by: and then the code block without braces.

56) How is the ternary conditional operator used in PHP?

It is composed of three expressions: a condition, and two operands describing what instruction should be performed when the specified condition is true or false as follows:

Expression_1?Expression_2 : Expression_3;

57) What is the function func_num_args() used for?

The function func_num_args() is used to give the number of parameters passed into a function.

58) If the variable $var1 is set to 10 and the $var2 is set to the character var1, what’s the value of $$var2?

$$var2 contains the value 10.

59) What does accessing a class via :: means?

:: is used to access static methods that do not require object initialization.

60) In PHP, objects are they passed by value or by reference?

In PHP, objects passed by value.

61) Are Parent constructors called implicitly inside a class constructor?

No, a parent constructor have to be called explicitly as follows:

parent::constructor($value)

62) What’s the difference between __sleep and __wakeup?

__sleep returns the array of all the variables that need to be saved, while __wakeup retrieves them.

63) What is faster?

1- Combining two variables as follows:

$variable1 = 'Hello ';

$variable2 = 'World';

$variable3 = $variable1.$variable2;

Or

2- $variable3 = "$variable1$variable2";

$variable3 will contain “Hello World”. The first code is faster than the second code especially for large large sets of data.

64) what is the definition of a session?

A session is a logical object enabling us to preserve temporary data across multiple PHP pages.

65) How to initiate a session in PHP?

The use of the function session_start() lets us activating a session.

66) How can you propagate a session id?

You can propagate a session id via cookies or URL parameters.

67) What is the meaning of a Persistent Cookie?

A persistent cookie is permanently stored in a cookie file on the browser’s computer. By default, cookies are temporary and are erased if we close the browser.

68) When do sessions end?

Sessions automatically end when the PHP script finishes executing but can be manually ended using the session_write_close().

69) What is the difference between session_unregister() and session_unset()?

The session_unregister() function unregister a global variable from the current session and the session_unset() function frees all session variables.

70) What does $GLOBALS mean?

$GLOBALS is associative array including references to all variables which are currently defined in the global scope of the script.

71) What does $_SERVER mean?

$_SERVER is an array including information created by the web server such as paths, headers, and script locations.

72) What does $_FILES means?

$_FILES is an associative array composed of items sent to the current script via the HTTP POST method.

73) What is the difference between $_FILES[‘userfile’][‘name’] and $_FILES[‘userfile’][‘tmp_name’]?

$_FILES[‘userfile’][‘name’] represents the original name of the file on the client machine,

$_FILES[‘userfile’][‘tmp_name’] represents the temporary filename of the file stored on the server.

74) How can we get the error when there is a problem to upload a file?

$_FILES[‘userfile’][‘error’] contains the error code associated with the uploaded file.

75) How can we change the maximum size of the files to be uploaded?

We can change the maximum size of files to be uploaded by changing upload_max_filesize in php.ini.

76) What does $_ENV mean?

$_ENV is an associative array of variables sent to the current PHP script via the environment method.

77) What does $_COOKIE mean?

$_COOKIE is an associative array of variables sent to the current PHP script using the HTTP Cookies.

78) What does the scope of variables mean?

The scope of a variable is the context within which it is defined. For the most part, all PHP variables only have a single scope. This single scope spans included and required files as well.

79) what the difference between the ‘BITWISE AND’ operator and the ‘LOGICAL AND’ operator?

$a and $b: TRUE if both $a and $b are TRUE.

$a & $b: Bits that are set in both $a and $b are set.

80) What are the two main string operators?

The first is the concatenation operator (‘.’), which returns the concatenation of its right and left arguments. The second is (‘.=’), which appends the argument on the right to the argument on the left.

81) What does the array operator ‘===’ means?

$a === $b TRUE if $a and $b have the same key/value pairs in the same order and of the same types.

82) What is the differences between $a != $b and $a !== $b?

!= means inequality (TRUE if $a is not equal to $b) and !== means non-identity (TRUE if $a is not identical to $b).

83) How can we determine whether a PHP variable is an instantiated object of a certain class?

To be able to verify whether a PHP variable is an instantiated object of a certain class we use instanceof.

84) What is the goto statement useful for?

The goto statement can be placed to enable jumping inside the PHP program. The target is pointed by a label followed by a colon, and the instruction is specified as a goto statement followed by the desired target label.

85) what is the difference between Exception::getMessage and Exception:: getLine?

Exception::getMessage lets us getting the Exception message and Exception::getLine lets us getting the line in which the exception occurred.

86) What does the expression Exception::__toString means?

Exception::__toString gives the String representation of the exception.

87) How is it possible to parse a configuration file?

The function parse_ini_file() enables us to load in the ini file specified in filename and returns the settings in it in an associative array.

88) How can we determine whether a variable is set?

The boolean function isset determines if a variable is set and is not NULL.

89) What is the difference between the functions strstr() and stristr()?

The string function strstr(string allString, string occ) returns part of allString from the first occurrence of occ to the end of allString. This function is case-sensitive. stristr() is identical to strstr() except that it is case insensitive.

90) what is the difference between for and foreach?

for is expressed as follows:

for (expr1; expr2; expr3)

statement

The first expression is executed once at the beginning. In each iteration, expr2 is evaluated. If it is TRUE, the loop continues, and the statements inside for are executed. If it evaluates to FALSE, the execution of the loop ends. expr3 is tested at the end of each iteration.

However, foreach provides an easy way to iterate over arrays, and it is only used with arrays and objects.

91) Is it possible to submit a form with a dedicated button?

It is possible to use the document.form.submit() function to submit the form. For example: <input type=button value=”SUBMIT” onClick=”document.form.submit()”>

92) What is the difference between ereg_replace() and eregi_replace()?

The function eregi_replace() is identical to the function ereg_replace() except that it ignores case distinction when matching alphabetic characters.

93) Is it possible to protect special characters in a query string?

Yes, we use the urlencode() function to be able to protect special characters.

94) What are the three classes of errors that can occur in PHP?

The three basic classes of errors are notices (non-critical), warnings (serious errors) and fatal errors (critical errors).

95) What is the difference between characters \034 and \x34?

\034 is octal 34 and \x34 is hex 34.

96) How can we pass the variable through the navigation between the pages?

It is possible to pass the variables between the PHP pages using sessions, cookies or hidden form fields.

97) Is it possible to extend the execution time of a PHP script?

The use of the set_time_limit(int seconds) enables us to extend the execution time of a PHP script. The default limit is 30 seconds.

98) Is it possible to destroy a cookie?

Yes, it is possible by setting the cookie with a past expiration time.

99) What is the default session time in PHP?

The default session time in php is until the closing of the browser

100) Is it possible to use COM component in PHP?

Yes, it’s possible to integrate (Distributed) Component Object Model components ((D)COM) in PHP scripts which is provided as a framework.

101) Explain whether it is possible to share a single instance of a Memcache between multiple PHP projects?

Yes, it is possible to share a single instance of Memcache between multiple projects. Memcache is a memory store space, and you can run memcache on one or more servers. You can also configure your client to speak to a particular set of instances. So, you can run two different Memcache processes on the same host and yet they are completely independent. Unless, if you have partitioned your data, then it becomes necessary to know from which instance to get the data from or to put into.

102) Explain how you can update Memcached when you make changes to PHP?

When PHP changes you can update Memcached by

  • Clearing the Cache proactively: Clearing the cache when an insert or update is made
  • Resetting the Cache: It is similar to the first method but rather than just deleting the keys and waiting for the next request for the data to refresh the cache, reset the values after the insert or update.

Resource to learn PHP

 

Step By Step PHP Language For Beginners With Examples

Introduction

Interested in creating your own website? Ever wondered how cool is it to have a website that has a log-in/log-out functionality? Want to learn how to Create, Read, Update or Delete(CRUD) records in a database? Have you lost track on your previous tutorials? Well, I’m going to teach you how to create one from scratch where in you will know every single details on how the code works. If you are new to back-end web development, this tutorial is for you. I’ll explain everything in detail so that you won’t have to research some particular methods being used. We won’t be using any frameworks to keep things simple. Also I won’t be focusing on the websites design since were after the functionalities though, it’s easy to implement the design. What will be doing is a simple item list when the users is logged in.

Topic Contents:

1.) Setting up your server

Now that your all set and go, as the basics of programming goes, let’s start by creating a simple shoutout of “hello world” in our server.

First of, go to the directory where you installed your XAMPP (Commonly in C:\xampp). From there go to the htdocs folder (Commonly in C:\xampp\htdocs) and create a folder named “MyFirstWebsite“.

1 - PHP101

From that part, you have now created a Local URL for your website. That folder will be used to supply in all website files (.html, .php, .css, .js, etc.). Open up your text editor and let’s get started!

I use sublime text as my text editor. If your using Notepad++ or any others, it’s ok. It’s not really a big factor but it’s just a preference on which one would you like to use.

What we will do is a basic HTML page and display “hello world” from the server using a basic PHP syntax. We then type the following syntax:

Hello World

<html>
    <head>
    <title>My first PHP Website</title>
    </head>
    <body>
        <?php
            echo "<p>Hello World!</p>";
        ?>
    </body>
</html>

Save the file to the “MyFirstWebSite” Folder and name it as “index.php“. (Directory as seen on the top part of the image)

Now that you have the file. Let’s now open your XAMPP control panel. In case it doesn’t appear on your desktop, it is located in your XAMPP folder as seen on the image:

Untitled

Untitled

Now that it’s there, Run your Apache and mySQL by clicking the “Start” button on the actions column. You should see a random PID(s) and the default port number. Apache is the name of our web server wherein it will handle all the files as well as serve as the communication to the web browser and MySQL is our database which will store all of our information.

Open up your web browser and in the address bar, type localhost. You should see the menu of your XAMPP.

If it’s the first time you run it, it will ask what language would you prefer, just simply pick and it will lead you to the menu. If you will noticed the directory is localhost/xampp, it’s where the default page leads you even if you type in localhost.

Untitled

If that appears, then it means that your XAMPP server is now running. Now let’s try running the website you just placed. Try typing localhost/MyFirstWebsite. It should be the same as the picture below.

Untitled

If you will notice that the URL is MyFirstWebsite, it is derived from the htdocs folder and it automatically reads files that are named “index”(Be it index.html, index.aspx, etc), which serve as the default page. Typing localhost/MyfirstWebsite/index.php is just the same. You can also create your custom name for the URL by simply renaming the folder but let’s just stick to MyFirstWebsite.

Note: If you don’t have a file named index and you entered the URL, you will receive an error 404 for not having the file on the server. If you do have different files that are not named index.<extention>, you have to specify the specific file name. E.x: localhost/MyfirstWebsite/page.php

2.) Creating the public HTML Pages

Next, let’s re-modify our website and add a registration link where our users can register as well as a Log-in page right after getting registered. Let’s modify our home page with the following code:

index.php

Untitled

<html>
    <head>
        <title>My first PHP Website</title>
    </head>
    <body>
        <?php
            echo "<p>Hello World!</p>";
        ?>
        <a href="login.php"> Click here to login 
        <a href="register.php"> Click here to register 
    </body>
</html>

As you can see, we only added 2 links which are for the Login and register. Let’s create the registration page first:

register.php

Untitled

<html>
    <head>
        <title>My first PHP Website</title>
    </head>
    <body>
        <h2>Registration Page</h2>
        <a href="index.php">Click here to go back<br/><br/>
        <form action="register.php" method="POST">
           Enter Username: <input type="text" name="username" required="required" /> <br/>
           Enter password: <input type="password" name="password" required="required" /> <br/>
           <input type="submit" value="Register"/>
        </form>
    </body>
</html>

As you can see, it’s just a basic form where the user can input his/her credentials. Now for the login page:

Hint: Just copy-paste the same code to make things faster.

login.php

Untitled

<html>
    <head>
        <title>My first PHP Website</title>
    </head>
    <body>
        <h2>Login Page</h2>
        <a href="index.php">Click here to go back<br/><br/>
        <form action="checklogin.php" method="POST">
           Enter Username: <input type="text" name="username" required="required" /> <br/>
           Enter password: <input type="password" name="password" required="required" /> <br/>
           <input type="submit" value="Login"/>
        </form>
    </body>
</html>

Basically it’s just the same code as from the register.php but the changes made were the ones underlined.

Click here for the complete login.php code

Try running localhost/MyFirstWebsite again and your pages should look like this:

index.php

Untitled

login.php

Untitled

register.php

Untitled

3.) Creating the database and it’s tables

Now that we have our basic page for the public. Let’s proceed to the database. First, type localhost/phpmyadmin. This will lead you to the phpmyadmin homepage:

localhost/phpmyadmin

Untitled

From there, go to the Databases tab located on top then from the text box in the middle, type first_db then click on create. Just leave the Collation as is.

Untitled

You have just successfully created your first database. Now from there, let’s create a table wherein we can register our users and display information. First, click on first_db located on the left side and create a table named users with 3 columns then click on Go.

Untitled

For the table’s structure, make sure to have the following fields then click on save:

  • Format: Column Name – Type – Length – Null Property – Other Properties
  • id – INT – N/A – Not Null – Auto Increment
  • username – varchar – 50 – Not null
  • password – varchar – 50 – Not null

Leave everything by default if not specified.

Untitled

Note: You need to scroll right for the auto_increment. I just edited the picture to fit the A_I field

Next, create another table named list with 7 columns and for the table’s structure:

  • id – INT – N/A – Not Null – Auto Increment
  • details – text – Not null
  • date_posted – varchar – 30 – Not null
  • time_posted – Time – Not null
  • date_edited – varchar – 30 – Not null
  • time_edited – Time – Not null
  • public -varchar – 5 – Not null

Untitled

4.)Adding users to the database

Now that we have our tables. Let’s move on to the fun part, getting your registration page into action. From your registration.php, add the following below the html codes:

register.php

Untitled

<html>
    <head>
        <title>My first PHP Website</title>
    </head>
    <body>
        <h2>Registration Page</h2>
        <a href="index.php">Click here to go back<br/><br/>
        <form action="checklogin.php" method="POST">
           Enter Username: <input type="text" name="username" required="required" /> <br/>
           Enter password: <input type="password" name="password" required="required" /> <br/>
           <input type="submit" value="Register"/>
        </form>
    </body>
</html>

Here’s the explanation to the code:

  • $_SERVER[“REQUEST_METHOD”] == “POST” – checks if the form has received a POST method when the submit button has been clicked. The POST method is created in the html from the method=”POST”. Click here for the form method reference.
  • $_POST[”] – gets the name coming from a POST method. This just simply gets the input based on the name from the form. In our case it’s username and password.
  • mysql_real_escape_string() – encapsulates the input into a string to prevent inputs from SQL Injections. This ensures that your strings don’t escape from unnecessary characters. Click here to learn more about SQL Injections.

Now try to go to your register.php and try to input anything then click on “Register”. In my case I placed in the username xtian and password as 123456. It should display the inputs below. Here’s my sample:

Untitled

On this part, you should have understood on how to get input from the form. Now to add it to the database. On your register.php, add the following code:

register.php

Untitled

<html>
    <head>
        <title>My first PHP Website</title>
    </head>
    <body>
        <h2>Registration Page</h2>
        <a href="index.php">Click here to go back<br/><br/>
        <form action="checklogin.php" method="POST">
           Enter Username: <input type="text" name="username" required="required" /> <br/>
           Enter password: <input type="password" name="password" required="required" /> <br/>
           <input type="submit" value="Register"/>
        </form>
    </body>
</html>

alert("Username has been taken!");</script>'; // Prompts the user
           Print '<script>window.location.assign("register.php");</script>'; // redirects to register.php
        }
    }

    if($bool)
    {
        mysql_query("INSERT INTO users (username, password) VALUES ('$username', 'password')"); // inserts value into table users
        Print '<script>alert("Successfully Registered!");</script>'; // Prompts the user
        Print '<script>window.location.assign("register.php");</script>'; // redirects to register.php
    }
}
?>

Click here for the complete register.php file

Here are the explanations to the code:

  • mysql_connect(“Server name”,”Server Username”,”Server Password”) – The syntax used to connect to our XAMPP server. localhost or 127.0.0.1 is the name of the server. The default username is root and no password for default.
  • mysql_select_db(“database name”) – Selects the database to be used.
  • or die(‘Message’) – Displays the error message if the condition wasn’t met.
  • mysql_query(‘sql query’) – does the SQL queries. Click here for some SQL query samples. The again, i’m not here to discuss about mySQL.
  • mysql_fetch_array(‘query’) – fetches all queries in the table to display or manipulate data. It is placed in a while loop so that it would query all rows. Take note that only 1 row is queried per loop that’s why a while loop is necessary.
  • $row[‘row name’] – the value of the column in the current query. It is represented as an array. In our case $row is the name of the variable for our row in the loop.

Try the inputs that you have made earlier and see what happens. It should prompt that you have successfully registered. Try going to phpmyadmin and see your users table:

Untitled

Congratulations! Now you know how to add data into the database with data validations.

5.)User log-in: Authentication

Now for the login page. Let’s create a new file called checklogin.php. The reason is going back to our login.php, our form has an action called “checklogin.php”, particularly <form action = “checklogin.php” method= “POST”>. If you will notice on the register.php, it’s also on register.php because the back-end is done on the same file as well.

Let’s now code the checklogin.php with the following syntax:

checklogin.php

Untitled

<?php
    session_start();
    $username = mysql_real_escape_string($_POST['username']);
    $password = mysql_real_escape_string($_POST['password']);
    $bool = true;

    mysql_connect("localhost", "root", "") or die (mysql_error()); //Connect to server
    mysql_select_db("first_db") or die ("Cannot connect to database"); //Connect to database
    $query = mysql_query("Select * from users WHERE username='$username'"); // Query the users table
    $exists = mysql_num_rows($query); //Checks if username exists
    $table_users = "":
    $table_password = "";
    if($exists > 0) //IF there are no returning rows or no existing username
    {
       while($row = mysql_fetch_assoc($query)) // display all rows from query
       {
          $table_users = $row['username']; // the first username row is passed on to $table_users, and so on until the query is finished
          $table_password = $row['password']; // the first password row is passed on to $table_password, and so on until the query is finished
       }
       if(($username == $table_users) && ($password == $table_password))// checks if there are any matching fields
       {
          if($password == $table_password)
          {
             $_SESSION['user'] = $username; //set the username in a session. This serves as a global variable
             header("location: home.php"); // redirects the user to the authenticated home page
          }
       }
       else
       {
        Print 'alert("Incorrect Password!");'; // Prompts the user
        Print 'window.location.assign("login.php");'; // redirects to login.php
       }
    }
    else
    {
        Print 'alert("Incorrect username!");'; // Prompts the user
        Print 'window.location.assign("login.php");'; // redirects to login.php
    }
?>

Click here for the complete checklogin.php code

Here’s the explanation of the code (Some are explained earlier so there’s no need to reiterate):

  • session_start() – Starts the session. This is usually done on authenticated pages. The reason why we used this is because this is required for the $_SESSION[”].
  • mysql_num_rows() – This returns an integer. This counts all the rows depending on the query.
  • $_SESSION[‘name’] – Serves as the session name for the entire session. This is relatively similar to public variables in object-oriented programming. We will be using this for validating whether the user is authenticated or not.

Now try to test your input with a wrong username and password. It should return the desired prompt. After testing, try inputting the correct values. It should lead you to home.php.

Note: home.php does not exist yet so it will produce an error 404.

6.)Setting up the home page for Logged-in users and Logging-out

Now that were authenticated, let now create our home page (home.php) with this following syntax:

home.php

Untitled

<html>
    <head>
        <title>My first PHP Website</title>
    </head>
   <?php
   session_start(); //starts the session
   if($_SESSION['user']){ // checks if the user is logged in  
   }
   else{
      header("location: index.php"); // redirects if user is not logged in
   }
   $user = $_SESSION['user']; //assigns user value
   ?>
    <body>
        <h2>Home Page</h2>
        
<hello>! 
 <!--Display's user name-->
        <a href="logout.php">Click here to go logout</a><br/><br/>
        <form action="add.php" method="POST">
           Add more to list: <input type="text" name="details" /> <br/>
           Public post? <input type="checkbox" name="public[]" value="yes" /> <br/>
           <input type="submit" value="Add to list"/>
        </form>
    <h2 align="center">My list</h2>
Id Details Edit Delete

</body> </html>

Here’s the explanation to the code:

  • session_start() – Basically starts the session. Required for $_SESSION[”].
  • header() – redirects the user.

Try refreshing your browser and it should look like this:

Untitled

Now that we have our home, let’s try creating our logout.php and test if the user’s session is off. What we would do is that if the user is logged-out, the user shouldn’t access home.php. So here’s the simple syntax to logout.php:

logout.php

Untitled

<?php
    session_start();
    session_destroy();
    header("location:index.php");
?>

The syntax is simple. session_destroy() simply remove’s all session’s meaning, the value of $_SESSION[”] will be removed and header() will simply redirect it to the home page.

7.)Testing Page Security

Now try refreshing home.php and click on logout. Now try Clicking on the back button of your browser and see what happens:

Untitled

As you can see, it doesn’t direct you to home.php because you are logged-out. Now for the second test, try manually inputting the address localhost/MyFirstWebsite/home.php. The same case should also happen. Since were logged-out, even a manual input of the address doesn’t access an authorized page. What we have done is a simple security mechanism wherein we redirect back unauthorized users into a public page.

Now try logging in again and let’s go back to home.php.

8.) Adding data to the list – User Access Only

In our next step, let’s create the adding of item’s to the list. As you will notice from the form, it is written as <form action=”add.php” method=”POST”>, meaning our http post request goes to add.php and with that, we create our add.php with the following syntax:

add.php

Untitled

<?php
    session_start();
    if($_SESSION['user']){
    }
    else{ 
       header("location:index.php");
    }

    $details = mysql_real_escape_string($_POST['details']);
    $time = strftime("%X"); //time
    $date = strftime("%B %d, %Y"); //date

    Print "$time - $date - $details";
?>

Take note that this ain’t our official add.php syntax yet, I’m just going to demonstrate the time and date syntax and getting your input.

Now go back to your home.php and try to add an item then click on “Add to list”.

Untitled

This should be the following output on add.php:

Untitled

As you can see, we have our current time, date, and your input. Here’s the explanation to the code:

  • strftime() – get’s the time based on what format your placed.
  • %X – current system time.
  • %B – current system month.
  • %d – current system day.
  • %Y – current system year.

Now let’s modify our add.php and add the following data into the database together with the data from the checkbox:

add.php

Untitled

<?php
    session_start();
    if($_SESSION['user']){
    }
    else{ 
       header("location:index.php");
    }

    if($_SERVER['REQUEST_METHOD'] == "POST")
    {
       $details = mysql_real_escape_string($_POST['details']);
       $time = strftime("%X"); //time
       $date = strftime("%B %d, %Y"); //date
       $decision = "no";
   
       mysql_connect("localhost","root","") or die(mysql_error()); //Connect to server
       mysql_select_db("first_db") or die("Cannot connect to database"); //Conect to database
       foreach($_POST['public'] in $each_check) //gets the data from the checkbox
       {
          if($each_check != null){ //checks if checkbox is checked
             $decision = "yes"; // sets the value
          }
       }

       mysql_query("INSERT INTO list(details, date_posted, time_posted, public) VALUES ('$details','$date','$time','$decision')"); //SQL query
       header("location:home.php");
    }
    else
    {
       header("location:home.php");
    }
?>

Click here for the complete add.php code

Here’s a little explanation:

  • foreach() – gets the value of the checkbox. As you will notice, the checkbox format in the form is name=”checkbox[]”. To get data from checkbox, it has to be instantiated as an array. Doing so would make it possible to get data from multiple checkboxes.

Now try entering some data and click “Add to list”. In my case, I’ll just use fish again. Let’s go to our phpmyadmin and let’s see if the data has been added. Here’s the result of my case:

localhost/phpmyadmin

Untitled

9.)Displaying data in the home page

Now that we have seen that the data has been successfully added. Let’s now display the data in our home page. Let’s modify our home.php and let’s add some columns for the date:

home.php

Untitled

<html>
    <head>
        <title>My first PHP Website</title>
    </head>
   <?php
   session_start(); //starts the session
   if($_SESSION['user']){ // checks if the user is logged in  
   }
   else{
      header("location: index.php"); // redirects if user is not logged in
   }
   $user = $_SESSION['user']; //assigns user value
   ?>
    <body>
        <h2>Home Page</h2>
        
<hello>! 
 <!--Display's user name-->
        <a href="logout.php">Click here to go logout</a><br/><br/>
        <form action="add.php" method="POST">
           Add more to list: <input type="text" name="details" /> <br/>
           Public post? <input type="checkbox" name="public[]" value="yes" /> <br/>
           <input type="submit" value="Add to list"/>
        </form>
    <h2 align="center">My list</h2>
    ';
             Print '";
             Print '";
             Print '";
             Print '";
             Print '';
             Print '';
             Print '';
          Print '';
       }
    ?>
Id Details Post Time Edit Time Edit Delete Public Post
‘. $row[‘id’] . “ ‘. $row[‘details’] . “ ‘. $row[‘date_posted’] . ” – ” . $row[‘time_posted’] . “ ‘. $row[‘date_edited’] . ” – ” . $row[‘time_edited’] .” edit delete ‘. $row[‘public’] . ‘

</body> </html>

The explanation to the added code is quite simple. It just basically displays the data coming from the while loop. It has been explained earlier in our tutorial so I believe that by this point, you should have understood the process of getting the data in the query. Going back to the browser, try refreshing your home.php and see what happens:

Untitled

It should now display that data. From our CRUD checklist, we have now accomplished Create and Read. Next is to update(edit) and delete information. If you will notice we have edit and delete links displayed on the column. I’ll add another data to the list named “tuna” to have another example and this time, it’s privacy to no:

Untitled

10.) Editing Data

Let’s now try editing our data and to do that we will use a new functionality called “GET“. With our previous methods, we have been using POST as our http request but this time, let’s use GET for editing and deleting records. To start of, let’s modify our home.php and add a little code to 2 columns:

home.php

Untitled

<html>
    <head>
        <title>My first PHP Website</title>
    </head>
   <?php
   session_start(); //starts the session
   if($_SESSION['user']){ // checks if the user is logged in  
   }
   else{
      header("location: index.php"); // redirects if user is not logged in
   }
   $user = $_SESSION['user']; //assigns user value
   ?>
    <body>
        <h2>Home Page</h2>
        
<hello>! 
 <!--Display's user name-->
        <a href="logout.php">Click here to go logout</a><br/><br/>
        <form action="add.php" method="POST">
           Add more to list: <input type="text" name="details" /> <br/>
           Public post? <input type="checkbox" name="public[]" value="yes" /> <br/>
           <input type="submit" value="Add to list"/>
        </form>
    <h2 align="center">My list</h2>
    ';
             Print '";
             Print '";
             Print '";
             Print '";
             Print '';
             Print '';
             Print '';
          Print '';
       }
    ?>
Id Details Post Time Edit Time Edit Delete Public Post
‘. $row[‘id’] . “ ‘. $row[‘details’] . “ ‘. $row[‘date_posted’] . ” – ” . $row[‘time_posted’] . “ ‘. $row[‘date_edited’] . ” – ” . $row[‘time_edited’] .” edit delete ‘. $row[‘public’] . ‘

</body> </html>

If you have noticed, we only added URL parameter for the edit and delete links namely id. We will be using this later to handle thee data. The reason why we use id is because it’s a unique identifier. It is possible for the person to have enter the same data so it’s not recommended to use the details as a mean for manipulation later on.

Try putting your cursor into the edit link and you will see the value of the id onthe lower left:

Untitled

Now that we have that, let’s try creating our edit.php and let’s try to get the data from there:

edit.php

lines 1 – 42

Untitled

<html>
    <head>
        <title>My first PHP Website</title>
    </head>
   <?php
   session_start(); //starts the session
   if($_SESSION['user']){ // checks if the user is logged in  
   }
   else{
      header("location: index.php"); // redirects if user is not logged in
   }
   $user = $_SESSION['user']; //assigns user value
   ?>
    <body>
        <h2>Home Page</h2>
        
<hello>! 
 <!--Display's user name-->
        <a href="logout.php">Click here to go logout</a><br/><br/>
        <a href="home.php">Return to home page</a>
    <h2 align="center">Currently Selected</h2>
     0)
           {
              while($row = mysql_fetch_array($query))
              {

Some explanations to the code:
  • !empty() – a method that checks if the value is not empty. The syntax can be reversed if you want to check if it’s empty by removing the explanation point (!), therefore it’s syntax would be empty().
  • $_GET[”] – Used to get the value from the parameter. In our case, we use id as our URL parameter so the syntax would be $_GET[‘id’].
  • $id_exists – the variable that checks whether the given id exists.
  • $_SESSION[‘id’] – we place the value of id into session to use it on another file.

lines 42 – 76 Untitled

Print "<tr>";
   Print '

“; Print ‘”; Print ‘”; Print ‘”; Print ‘”; Print “”; } } else { $id_exists = false; } } ?>

Id Details Post Time Edit Time Public Post
‘ . $row[‘id’] . “ ‘ . $row[‘details’] . “ ‘ . $row[‘date_posted’] . ” – ” . $row[‘time_posted’].” ‘ . $row[‘date_edited’] . ” – ” . $row[‘time_edited’].” ‘ . $row[‘public’] . “

<br/> Enter new detail: <input type=”text” name=”details”/> <br/> public post? <input type=”checkbox name=”public[]” value=”yes”/> <input type=”submit” value=”Update List”/> </form> ‘; } else { <h2 align=”center”>There is not data to be edited.</h2> } ?> </body> </html> Click here for the complete edit.php code (Only refer to the front-end part. Github Sourced)

The reason why we are putting the variable $id_exists is because in case the user modifies the URL parameter into a non-existing number(in our case we only have 2 rows/id’s), we can display a prompt in which the data doesn’t exist.

Now try clicking the edit link into the first row and it should display like this:

Untitled

Complete edit.php code:

<html>
    <head>
        <title>My first PHP Website</title>
    </head>
   <?php
   session_start(); //starts the session
   if($_SESSION['user']){ // checks if the user is logged in  
   }
   else{
      header("location: index.php"); // redirects if user is not logged in
   }
   $user = $_SESSION['user']; //assigns user value
   ?>
    <body>
        <h2>Home Page</h2>
        
<hello>! 
 <!--Display's user name-->
        <a href="logout.php">Click here to go logout</a><br/><br/>
        <a href="home.php">Return to home page</a>
    <h2 align="center">Currently Selected</h2>
     0)
           {
              while($row = mysql_fetch_array($query))
              {
                  Print "";
                     Print '";
                     Print '";
                     Print '";
                     Print '";
                     Print '";
                  Print "";
               }
            }
            else
            {
               $id_exists = false;
            }
         }
      ?>
Id Details Post Time Edit Time Public Post
‘ . $row[‘id’] . “ ‘ . $row[‘details’] . “ ‘ . $row[‘date_posted’] . ” – ” . $row[‘time_posted’].” ‘ . $row[‘date_edited’] . ” – ” . $row[‘time_edited’].” ‘ . $row[‘public’] . “

<br/> Enter new detail: <input type=”text” name=”details”/> <br/> public post? <input type=”checkbox name=”public[]” value=”yes”/> <input type=”submit” value=”Update List”/> </form> ‘; } else { <h2 align=”center”>There is not data to be edited.</h2> } ?> </body> </html> Click here for the complete edit.php code (Only refer to the front-end code. Github sourced)

Let’s try modifying the URL parameter by removing ?id=1 and now should result to localhost/MyFirstWebsite/edit.php and it should result like this:

Untitled

Now try putting a value that is greater than the id number, in our case, let’s try 5 and it should result like this:

localhost/MyFirstWebsite/edit.php?id=5

Untitled

Now that we secured our URL parameters, lets now place the edit syntax. Let’s go back to edit.php and add some following code to update the information to the database:

edit.php

Untitled

<?php
   if($_SERVER['REQUEST_METHOD'] == "POST")
   {
      mysql_connect("localhost", "root", "") or die (mysql_error()); //Connect to server
      mysql_select_db("first_db") or die ("Cannot connect to database"); //Connect to database
      $details = mysql_real_escape_string($_POST['details']);
      $public = "no";
      $id = $_SESSION['id'];
      $time = strftime("%X"); //time
      $date = strftime("%B %D, %Y"); //date

      foreach($_POST['public'] as $list)
      {
         if($list != null)
         {
            $public = "yes";
         }
      }
      mysql_query("UPDATE list SET details='$details', public='$public', date_edited='$date', time_edited='$time' WHERE id='$id'");
      header("location:home.php");
   }
?>

Click here for the complete edit.php code (Github)

Now try refreshing and go back to the edit page. Let’s try a different data. In my case, I’ll be using “Salmon” and change it to non-public:

edit.php?id=1

Untitled

Go ahead and click Update list and you should be redirected to home.php and see the updated list.

Untitled

Now, we have a time and date of edit displayed on the Edit Time column. Our privacy has been set now to non-public and the value has changed into Salmon.

Congratulations! We have now done the edit function!

11.) Deleting data

Looking back to the CRUD, we have now done creating(adding), reading(displaying), and updating(editing) records. Now for the last part, deleting records. For this part it’s just relatively the same as what we have done on edit but what differs is just the SQL statement. Instead of using UPDATE, we will be using the DELETE syntax. In deleting records, we have to prompt people making sure that they’d really want to delete the record so we will be adding a little javascript in home.php. To do that, let’s modify our code and add some int home.php

home.php

Untitled

<table border="1px" width="100%">
    
       Id
       Details
       Post Time
       Edit Time
       Edit
       Delete
       Public Post
    
    ';
             Print ''. $row['id'] . "";
             Print ''. $row['details'] . "";
             Print ''. $row['date_posted'] . " - " . $row['time_posted'] . "";
             Print ''. $row['date_edited'] . " - " . $row['time_edited'] ."";
             Print '<a href="edit.php?id='.$row['id'].'">edit';
             Print '<a href="#" nclick="myfunction('.$row['id'].')">delete</a>';
             Print ''. $row['public'] . '';
          Print '';
       }
    ?>



<script>
    function myFunction(id)
    {
       var r = confirm("Are you sure you want to delete this record?");
       if(r == true)
       {
          window.location.assign("delete.php?id=" + id);
       }
    }
</script>

Click here for the complete home.php code

As you have noticed, we edited the link for the delete. We changed href into “#” and added and onclick function for Javascript for the method of myFunction and inside it’s parameter is the id of the row. Below the table written is the Javascript syntax wherein it prompts the user if he/she want’s to delete the record. If the user confirms, the page then directs to delete.php together embedded with the value of the id. Now let’s create delete.php and here’s the following syntax:

delete.php

Untitled

<?php
    session_start(); //starts the session
    if($_SESSION['user']){ //checks if user is logged in
    }
    else {
       header("location:index.php"); //redirects if user is not logged in.
    }

    if($_SERVER['REQUEST_METHOD'] == "GET")
    {
       mysql_connect("localhost", "root", "") or die(mysql_error()); //connect to server
       mysql_select_db("first_db") or die("cannot connect to database"); //Connect to database
       $id = $_GET['id'];
       mysql_query("DELETE FROM list WHERE id='$id'");
       header("location:home.php");
    }
?>

Click here for the complete delete.php code

The code is just simple and the syntax are also the ones that we used before but noticed we have changed our request method into GET. We are now using the GET request since we have a URL parameter. Now try refreshing home.php and let’s try deleting the first record. This should be the result:

Prompting:

Untitled

End-result:

Untitled

Congratulations! Now we have now officially completed our CRUD statements!

12.) Displaying public data

Now for the last part, displaying public data. We will be displaying data that’s been set to yes in our index.php, in which is a page for non-authenticated users. It’s very simple. We just have to edit our index.php and add a some php code and table. Here’s our updated index.php:

index.php

Untitled

Now log-out and see your default page. It should look something like this:

Untitled

Note: You won’t see the data yet since we haven’t set any information to public.

Now let’s log-in again and this time, let’s add some more data. In my case I’ve added the following:

  • Salad – public
  • Corn – non-public
  • Pasta – public
  • Chicken – public
  • Spaghetti – non-public

With a total of 6 data’s with 3 of each privacy setting:

home.php

Untitled

Now let’s log-out and see our default page(index.php). It should now look like this:

index.php

Untitled

As you can see, it only display’s data that are set to public.

Congratulations! We have finally finished the tutorials for this session!

13.) De-briefing and Summary

In the end, you should have the following files:

Untitled

As I mentioned earlier, I’ll be uploading the finished product. Click here

I also uploaded the sql file for the database in case you want to use the exact data that I have. To import the sql file, you can just simply click on export and select the sql file but make sure to create the database first. If you like, I can create a separate blog for that. Just let me know in the comments section.

Resources to learn PHP

PHP For Dynamic Websites

Introduction to PHP In Arabic

Learn SASS and SCSS

PHP Specialist (2017 Edition)

PHP: Import CSV File to MySQL

Learn Complete PHP & MYSQL Programming From Scratch

PHP and MYSQL Course from Scratch with Projects

Learn Step by Step Codeigniter 3 with Bootstrap 4 From Scratch with Advance

Learn Complete PHP MySQL by Building 5 Projects from Scratch

PHP PDO – Create a Personal Contacts Agenda Project

Learning PHP Data Objects PDO

PHP Secure Login and Registration System + Email Activation

Crear Documentos Pdf, Word, Excel en Php Generar Reportes 

Is PHP dead? What is the job outlook and future of PHP in the next five years?

PHP is far from dead. Since we get similar questions all the time, I am just going to repeat an answer from another discussion.

Is PHP still relevant as of 2019?

COBOL, a 1959 dinosaur language deployed on few tens of thousands installations is still relevant in 2019.

PHP is actively developed on 2019 and deployed on several hundreds of millions installations.

Therefore even just the “still widely used in many web apps” is plenty enough to justify learning it.

Plus, PHP is so easy to learn and used everywhere that not knowing it is:

  • a bad reference on your curriculum,
  • like not knowing any shell or bash command. Sure, you can ignore those but it shows the moment you are assigned some simple tasks. Your boss will know. Your colleagues will know.

Is PHP good for anything?

PHP, especially after version 7.0, is fast, simple, very syntax rich. It comes with embedded security libraries while being the cheapest language available on every host provider.
PHP runs on multiple CPU cores (Node.js needs additional work) and can be used both as sync and async (like Node.js) with an additional script.

PHP implements type hinting, interfaces, facades, traits, singletons, closures, structured exceptions, generic containers, iterators, namespaces, packages (Composer, akin to npm), unit tests, continuous integration…
It comes with thousands of packaged (and stand-alone) libraries, MVC / REST frameworks. Some, in example Laravel, are an industry standard.
And all of this can be learned one bit at a time, because basic PHP is as simple as writing “print(“Hello world”);”. Even a child can learn PHP.
As such, you can find cheap PHP developers everywhere in the world, not just in California.

Sure, with immense quantity, comes a immense range of quality. Therefore it’s plenty possible to find a bad PHP coder or an excellent coder. Companies may help themselves with the help of online PHP perspective developers check/interview tools.

Is PHP still growing?

PHP powers the hugest majority of the websites in the world. By far. This is thanks to some “giant” applications like WordPress or very large “users” (Facebook and many others).

When not used as async, event driven model, base PHP faces upper limits on the amount of concurrent website hits that are below Node.js, Go and Scala. Not using PHP as async, event driven model allows to quickly and easily create complex applications that are still more than fast enough to be used by large enterprises.
When used with async model, its speed grows as shown in the chart below (created on old PHP 5.x, that ran at half speed vs what PHP 7.x runs today):

These hits were achieved by using Symfony, a very feature rich but very slow framework. By using one of many PHP API backend optimized frameworks (Lithium, Lumen, Fat Free Framework…) speed more than doubles.

Here is a more recent chart, featuring PHP 7.0 performance by switching model:

PHP 7.2 is about 5% faster than PHP 7.0 featured on the chart.

Since achieving enterprise grade, ultra-massive throughput (a la YouTube-Netflix-Amazon scale) involves a whole re-thinking of data centers, servers, services stacks and so on, the embedded costs of using async PHP or another solution become just “one of many balance voices” in the whole project.

In case the above is still not enough, Facebook developed both a PHP compiler and a PHP virtual machine (HHVM) to further improve performance. Facebook is perhaps the most known PHP “business card”, it’s the living proof of a modern and ever evolving, ultra-massive website that runs the PHP language.

Conclusion

I hope by reading the post above you understand why PHP is here to stay and be relevant for many years to come:

  • Easy to learn
  • Very rich, both on syntax features and constructs
  • Easy to find everywhere, on any hosting, with no additional costs
  • Huge amount of third party libraries, packages, tutorials, books
  • Cheapest costs of all
  • Cheapest, easiest to find developers for your company
  • Even in default configuration, more than adequate for all but the most demanding heavy usage. With additional effort, able to scale up to Facebook levels.

Some Resources of PHP:

PHP For Dynamic Websites

Introduction to PHP In Arabic

Learn SASS and SCSS

PHP Specialist (2017 Edition)

PHP: Import CSV File to MySQL

Learn Complete PHP & MYSQL Programming From Scratch

PHP and MYSQL Course from Scratch with Projects

Learn Step by Step Codeigniter 3 with Bootstrap 4 From Scratch with Advance

Learn Complete PHP MySQL by Building 5 Projects from Scratch

PHP PDO – Create a Personal Contacts Agenda Project

Learning PHP Data Objects PDO

PHP Secure Login and Registration System + Email Activation

Crear Documentos Pdf, Word, Excel en Php Generar Reportes 

PHP Frameworks Guide & Top 10 Best PHP Framework 2019

PHP is used by almost 83% of websites across the world and is thus one of the widely used languages for web design and development throughout the world. Rasmond Lerdoff did not develop it as a programming language. It originated simply to manage his personal website. But later the official version was released in 1997 after many months of beta tests and improvement work. PHP was earlier abbreviated as Personal Home Page but it is better known as Hypertext Preprocessor now.

The latest version PHP 7 was aimed to optimize PHP performance by refactoring the Zend Engine and make use of more compact data structures with improved cache locality while retaining near-complete language compatibility. A framework is used for its faster development, easier maintainability, fewer issues, and better security reasons.

Why use a top PHP Framework?

There are some pretty reasons for using PHP frameworks:

  • Organization of code and file is extremely easy
  • Numerous libraries and tools are available that can help in form validation, database abstraction, input/output filtering, session, and cookie handling, and managing email, calendar, and pagination etc.
  • Most of the frameworks follow MVC model architecture
  • Frameworks help out with less code which ultimately speeds up development
  • Frameworks come with various input and output filtering functions that add an additional security layer to protect the website against certain attacks.
  • Frameworks suit well to teamwork
  • With active community support, frameworks come with a solution for any query very quickly

Line Up of Best PHP Frameworks in 2019

1. Laravel

It continues to be the most favored and widely used PHP framework since 2015. Laravel simplifies the authorization logic and control access to resources. It supports object-oriented libraries that come along with many pre-installed features. Tools like Artisan are included and help perform tedious programming tasks which are otherwise manually performed by most of the programmers. It also has support for MVC architecture like Symphony that ensures clarity in logic and presentation.

2. CakePHP

The best thing about CakePHP is its 100% backward compatibility that makes it instantly upgradable. Although it does not adapt to newer PHP habits it has shown some consistency in form of stable releases. Going with Fat Models, Skinny Controller and automatic routing approach imply most of the work is automated.

3. Zend Framework

Re-usability of code is the biggest advantage of Zend framework. Imbibing all the goodness of object-oriented approach, making use of just what you need and removing other things, a package full of tools, components, and libraries, liberty to choose own model, a large community with elaborated documentation acts as an addendum to its richness and usability.

4. Symfony

Flexibility, reliability, ease of testing, long-term support, large community, elaborated documentation are some of the pluses that go in favor of Symphony as a programming framework.

5. Codeigniter

MVC Architecture, no server requirements, easily extendable and understandable, package full of libraries, components, and tools, built-in libraries, comes without installation, built-in security tools, database abstraction, active community support, and extensive documentation and above everything, the ExpressionEngine allows re-using libraries and functions.

6. Yii2

Easy to Install, Modern Technologies, Highly Extensible, Provision for Testing, Simple to implement Security, Short Development Time, Better Performance, Swift Error Handling, Logging and making use of theme

7. Phalcon

Easy to install, usage of modern technologies, highly extensible, integration of Codeception encourages testing the code for the application, simplified security, short development time, and better performance makes it a framework to create modern web applications that also perform well.

8. Aura

Aura is an open source, UI framework used to build PHP applications that are dynamic and flexible, scalable and extensible. Tag-based layout & component definition, a strongly typed event model with Encapsulated UI development, extends, implements, abstract – Object-oriented programming behavior, controllers, models, CSS, markup and static resources, comes with integrated support for functional and performance testing, and responsive (mobile ready).

9. Slim

It’s a micro framework, a core set of tools that yields quick development, is easy to learn, lightweight, secure, has HTTP methods, can be used to develop both small and large websites and an elaborated documentation

10. Fatfree

It’s a powerful PHP framework, which is known for its high speed, high modularity, clean and comprehensive documentation, comes without coding or directory structure, multiple view engines, easy to learn, implement and for creating robust web applications.

The Forthcoming Best PHP Alternatives

Off and on programmers pick new skills and languages to stay relevant with changing technologies and the way IT and related industries function. Many such high level, object oriented, server –side scripting languages, that are comparable to PHP are (in no particular order):

  • Javascript

  • Python

  • Java

  • Go

  • Ruby

  • C#

  • Elixir

  • Erlang

  • C++

  • Rust

Without skipping, Node.js for sure makes a mark in this illustrative list, as it has learnt from the mistakes of other languages that include .NET, PHP and Java, and has little legacy crud, to become one of the best alternatives to PHP programming language.

The Closing Section

It can get really difficult to select the right PHP development framework to create web applications of choice. We at Simpliv have been making use of various PHP development frameworks to build PHP applications on regular basis. We have tried and tested various PHP frameworks from time to time where Laravel development tops our list.  On one hand, it propels you to create secure and testable web applications, as the features can be used in the same manner as are provided, some others can also be customized to suit to the needs of the application. We really encourage you to check out some frameworks for your next web project. Hire PHP developers from our team of experts to incite your next web project. Would you like a free instant quote? We’re here for you!

Recommended Resources:

PHP For Dynamic Websites

Introduction to PHP In Arabic

Learn SASS and SCSS

PHP Specialist (2017 Edition)

PHP: Import CSV File to MySQL

Learn Complete PHP & MYSQL Programming From Scratch

PHP and MYSQL Course from Scratch with Projects

Learn Step by Step Codeigniter 3 with Bootstrap 4 From Scratch with Advance

Learn Complete PHP MySQL by Building 5 Projects from Scratch

PHP PDO – Create a Personal Contacts Agenda Project

Learning PHP Data Objects PDO

PHP Secure Login and Registration System + Email Activation

Crear Documentos Pdf, Word, Excel en Php Generar Reportes 

Data Visualization certification course with Tableau, R and Python

ABOUT THE COURSE

Data science doesn’t need to be the complex subject it is thought to be. Not with Simpliv, for sure. Understand when to use the right tools, how to connect to the right data source, how to connect Tableau Desktop with R to optimize the functions of R, packages, libraries and saved models. Also learn to use Python scripts for your fields in Tableau in the same way as you do with R. Ideal for becoming a complete data professional.

Who is the target audience?

All the professionals who are passionate about business intelligence, data visualization, and data analytics.

Basic knowledge:

There are no prerequisites for taking up this certification training course.

 Curriculam

Visualization with Tableau

  • Tableau – An Introduction
  • Aggregation and Granularity
  • Action Filters and Action Highlights
  • Customer Segmentation Dashboard
  • Data Blending
  • Find top 10 Gems
  • Table Calculations (Explaining various Table calculations)
  • Difference between Table calculations and Calculated fields
  • LOD Functions
  • How to connect to databases (Video based)
  • How to integrate Tableau with R (Video based)
  • Dashboarding Techniques
  • Other Charts

Python and R basics

  • Tableau – An Introduction
  • Core programming concepts
  • Objects in Python
  • Visualizations in Python
  • Packages in Python
  • Packages in Python
  • Matrix Operations
  • Dataframes
  • Introduction to R
  • Objects in R
  • Core programming concepts
  • Visualizations in R (Packages in R)
  • Matrix Operations
  • Dataframes
  • Lists in R
  • Apply family functions in R
  • Projects and Tests

 Event Type – Online Classroom Training

Price:   $499 (Enroll Today and Get Flat 40% OFF($299) )

 New Batch starts from 23 Sep 2019 Days: Mon-Fri (15 Days) 09:00 AM – 12:00 PM (PDT)

Contact Us:

Simpliv

Email: support@simpliv.com

Phone India: 76760-08458

Phone USA: 510-849-6155

 

To Enroll Click Here: https://www.simpliv.com/virtual-classroom/data-visualization-with-tableau-r-and-python

 

 

What is Tableau? Why Tableau? How does Tableau work?

What is Tableau?

Tableau is a powerful and fastest growing data visualization tool used in the Business Intelligence Industry. It helps in simplifying raw data into the very easily understandable format.

Data analysis is very fast with Tableau and the visualizations created are in the form of dashboards and worksheets. The data that is created using Tableau can be understood by professional at any level in an organization. It even allows a non-technical user to create a customized dashboard.

The best feature Tableau are

  • Data Blending
  • Real time analysis
  • Collaboration of data

The great thing about Tableau software is that it doesn’t require any technical or any kind of programming skills to operate. The tool has garnered interest among the people from all sectors such as business, researchers, different industries, etc.

What is Tableau used for?

Usage of Tableau software are listed below:

  • Tableau software is used to translate queries into visualization.
  • It is also used for managing metadata.
  • Tableau software imports data of all the sizes and ranges.
  • For a non-technical user Tableau is life saver as it offers the facility to create “no-code” data queries.

As Tableau is an emerging technology, Data visualization tool is used for business intelligence industry. Organizations like Amazon, Walmart, Accenture, Lenovo and so on widely use this tool.

Why Tableau?

Why use Tableau software when there are a whole lot of tools available to perform data visualization?

Tableau is greatly used because data can be analyzed very quickly with Tableau. Also, visualizations are generated as dashboards and worksheets. Tableau allows us to create dashboards that provide actionable insights and drives the business forward. The products of Tableau always operate in virtualized environments when they are configured with the proper underlying operating system and hardware. Tableau is used to explore data with limitless visual analytics.

A few features of Tableau are given below:

  • Real-time analysis
  • Data Blending
  • Collaboration of data
  • No need any technical knowledge

How does Tableau work?

Tableau connects and extracts the data stored in various places. It can pull data from any platform imaginable. A simple database such as an excel, pdf, to a complex database like Oracle, a database in the cloud such as Amazon webs services, Microsoft Azure SQL database, Google Cloud SQL and various other data sources can be extracted by Tableau.

When Tableau is launched, ready data connectors are available which allows you to connect to any database. Depending on the version of Tableau that you have purchased the number of data connectors supported by Tableau will vary.

The pulled data can be either connected live or extracted to the Tableau’s data engine, Tableau Desktop. This is where the Data analyst, data engineer work with the data that was pulled up and develop visualizations. The created dashboards are shared with the users as a static file. The users who receive the dashboards views the file using Tableau Reader.

The data from the Tableau Desktop can be published to the Tableau server. This is an enterprise platform where collaboration, distribution, governance, security model, automation features are supported. With the Tableau server, the end users have a better experience in accessing the files from all locations be it a desktop, mobile or email.

Summary

  • Tableau is a powerful and fastest growing data visualization tool used in the Business Intelligence Industry
  • The Tableau Product Suite consists of 1) Tableau Desktop 2) Tableau Public 3) Tableau Online 4) Tableau Server and Tableau Reader
  • Tableau Desktop has a rich feature set and allows you to code and customize reports
  • In Tableau public, workbooks created cannot be saved locally, in turn, it should be saved to the Tableau’s public cloud which can be viewed and accessed by anyone
  • Tableau server is specifically used to share the workbooks, visualizations that are created in the Tableau Desktop application across the organization
  • Tableau online has all the similar functionalities of the Tableau Server, but the data is stored on servers hosted in the cloud which are maintained by the Tableau group.
  • Tableau Reader is a free tool which allows you to view the workbooks and visualizations created using Tableau Desktop or Tableau Public.
  • Tableau connects and extracts the data stored in various places. It can pull data from any platform imaginable.
  • The spreadsheet application used for manipulating the data while Tableau is a perfect visualization tool used for analysis

Check out the Simpliv Data Visualization certification course with Tableau to get a head start in your Business Intelligence career!

Related Articles