PHP OOP or Procedural

I am new to PHP, Which one should I go for first, PHP OOP or Procedural.

Php
I love php
Where are you learning it

1 Like

Procedural is an easier way, most code you will encounter in tutorials will be of this type.
OOP is a modern approach, more difficult to grasp.

If you have previous experience programming then try learning proper OOP with PHP to avoid re-learning things later on. Otherwise both ways are still valid.

Currently Iā€™m reading Professional PHP which focuses on modern development practices.

1 Like

I have slightly experience of programming. Thank you for the suggestion, I will go for difficult considering OOP.

Iā€™m learning from online youtube tutorials and from book PHP Development Tool Essentials by Chad Russel.

Consider https://knpuniversity.com/, https://laracasts.com/ or https://www.codecourse.com/ for excellent video materials.

First one specialises on Symfony, other two on Laravel with some Vue.

All three have good introduction courses. Some courses on knpuniversity, laracasts and codecourse are free.

1 Like

Functional, of course.

1 Like

Why FCC doesnā€™t have PHP courses?

FCC is supported by volunteers. We donā€™t have time to develop programs for every language. Every one has a favorite language. No matter what choices are made, someone will feel left out. The choice was made to focus on Node/Express/Mongo on the backend. Maybe in the future a php program will be made. Maybe you can spearhead that.

1 Like

Hi, but PHP is not the most common choice now ?

Well, people basicaly do what they want. But knowing PHP is maybe more important than playing with nodeJS :confused:
But like people said, itā€™s very nice to keep everying under the Javascript language.

Letā€™s not descend into the ā€œmy favorite programming language can beat up your favorite programming languageā€ argument.

Yes, PHP is everywhere, but a lot of that has to do with WordPress being everywhere and WP uses PHP.

Every language has itā€™s strengths and weaknesses. Every language has a situation where it is not the right choice and they all have places where they shine. Every language have people that love it an people that hate it.

Many languages have a life cycle. COBOL was once cutting edge. I remember hearing that C was the last language weā€™d ever need. Then I heard the same about C++. I heard that Java as going to take over the world. People now say similar things about JS. It goes on and on.

PHP does appear to be on a bit of a decline. But it wonā€™t go away anytime soon, especially while WordPress is built around it. Remember COBOL? There are some great paying jobs out there for guys working on legacy COBOL code.

Whatever its merits or weaknesses, PHP will be a profitable language to learn for some time to come. It just doesnā€™t happen to be one that FCC teaches at this time.

3 Likes

Thank you for those link. Iā€™m on to it.

1 Like

Learn PHP and donā€™t stop there. If you feel like PHP is the way to go, donā€™t listen to useless discussions on this is better than that, Itā€™s not about the language believe me, Itā€™s all about your creative drive and unique vision on making something useful for everyone. Go for it, and along the way submerge yourself in the wonderfull world of CSS3 and HTML5, Your walk through coding by itself, will take you where you want to go, and You will get there.

Since you are training as an engineer, you should stop asking for advice. Learn about the differences between the two styles, understand the pros and cons, then make your own decision.