How to Learn PHP
Web Technology around PHP
HTML ( Hypertext Markup Language )
Used to define a web view. Everything that appears on the web, ranging from images, text, text thickness, text position, buttons, forms and so on, is written in HTML. The latest version of HTML called HTML 5 is a development of previous versions such as HTML 4 and XHTML. If you're learning HTML, make sure you're learning the latest version of HTML.
CSS ( Cascading Style Sheets )
Also used to define web views. But more towards "decorate" the web display. CSS points to certain elements in HTML, and modifies its appearance, it can be in the form of shape, text thickness, text color, text position, and so on.
Also note, jQuery library is not the same as jQuery UI . jQuery is used to quickly manipulate the DOM. While jQuery UI is used to display a UI ( User Interface / interface) that is sweeter and interactive compared to the usual HTML UI. jQuery UI has a fairly heavy size and a few drawbacks. For now, I recommend using jQuery alone, and combining it with another UI Framework like Bootstrap or Modernizr .
-- Stop and move on to the next topic if you want to go fast --
Why choose PHP
PHP is considered easy to learn because:
- Easy to install. There are many installation packages on the internet, such as XAMPP, Appserv, and WAMP.
- Does not require complex variable and library declarations.
- When installed, usually can be directly connected to various database servers.
- There are already many tutorials and discussions of PHP tricks on the internet.
- You can even try to get your site online on various free hostings available on the Internet.
Web programming languages other than PHP:
- ASP .NET family. There are several technologies related to ASP, such as ASP .NET itself, and several versions of ASP .NET MVC. Finally, we have reached MVC 5. Please note that ASP .NET MVC is a web programming framework. So it's a bit different from pure PHP. However, it can be equated with PHP if PHP uses a library framework such as Code Igniter, Yii, or Laravel.
- Java Enterprise Edition. Using the Java programming language. The author himself has not succeeded in trying to run hello world on this platform.
- Code Fusion. This technology is a bit old, and it looks like almost no one is using it anymore.
- Ruby On Rails. It's been pretty booming for a few years, but the future seems a bit bleak.
- NodeJS. Is a new technology, but recently started to boom. But this technology is still immature. So the authors suggest this technology is enough to be studied as a hobby and anticipation.
ASP.NET using either VB.NET or C# is a skillset that is quite sought after, but according to the author, it is not easy to learn ASP.NET. However, if you have a .NET programming background, for example for the desktop, maybe ASP can be a consideration.
When compared to PHP, PHP has several advantages over others:
- Hurry up . There are many sites comparing the speed of PHP, ASP and NodeJS with varying opinions. I'm not here to take sides, but PHP 7 is planned to be released and the speed of PHP 7 has increased significantly compared to PHP 5. So for the future, PHP will not lose in terms of speed.
- Cheap . We can easily find free, cheap or expensive PHP hosting. Not so with ASP.NET. Quite a lot of hosting for ASP.NET, but rarely free. As for NodeJS, there are not many NodeJS hosting services.
- Multi-platform . PHP can be run either on Linux or Windows. Just note that on Linux servers, URLs are case sensitive, so it's important to pay attention to URLs. For example "../images/Questionmarks.png" is not the same as "../images/assignments.png".
The author is more likely to be pure without a framework. Because new frameworks will continue to emerge, whereas if we have a good code structure, our code will still be very maintainable. But even if you choose to use a framework, this tutorial will still be very useful because pure PHP can be used in any PHP framework.
If you want to use the PHP Framework, I really suggest rethinking. If you really want to, go for Code Igniter, because it is one of the oldest and most widely used frameworks. Gambling with Yii, Laravel or the like will only get you 1 or 2 years of success. The rest of you will be busy learning new frameworks.