강의

멘토링

로드맵

Inflearn brand logo image
Programming

/

Programming Language

PHP 7+ プログラミング

PHP言語を始める方々のために、基本文法から組み込み関数、ウェブセキュリティ、掲示板作成まで、バイブルとなるようにとの思いで、今回の講座を作ってみました。

  • pronist
PHP

学習した受講者のレビュー

こんなことが学べます

  • PHP 7+ 基礎文法

  • PHP で使われる様々な組み込み関数

  • PHP のウェブセキュリティ要素

  • PHPで会員制掲示板を作る

  • PHP レガシープロジェクト 脱出

もうレガシーはやめて、
過去を乗り越えて未来へ進もう!
정상우の『Awesome Laravel』
어썸 라라벨

PHP 7+ プログラミング

基礎文法から内蔵関数、ウェブセキュリティ、掲示板作成まで、入門初級段階でPHP言語を始める方々のためのバイブルとなるような気持ちで、今回の講座を作成いたしました。

カリキュラム

この講座ではPHPプログラミング基礎文法から始めて組み込み関数、Webセキュリティ、掲示板作成まで、Web開発において基礎となる部分についてお話しします。既存の「PHP 7+ プログラミング」講座では扱わなかった様々な組み込み関数や、掲示板での単純な実装だけでなく関数化を通じてコードの品質向上まで図れるよう構成してみました。

必ず知っておくべきPHP基礎文法

PHP 7+ バージョンに該当する基本的な文法を習得します。この講座は基本的にPHP 7.2バージョンを基準としていますが、PHP 7.4バージョンに登場したArrow FunctionSpread Operator in Arrayもカバーできるよう構成しました。したがって、講義をゆっくりと追いかけていけば、講義が制作された時点での最新バージョンであるPHP 7.4バージョンまで習得することができます。

よく使用されるPHP組み込み関数

String、Password HashingなどPHPプログラミングをする際に必ず知っておくべき組み込み関数について学びます。内容が多く見えるかもしれませんが、掲示板作成でかなりの数を使用することになります。ただし、単純に羅列する方式で進行されるため、退屈に感じる可能性があります。そのため、掲示板作成を先に進めてから組み込み関数パートを見るのも一つの方法です。

*他のチャプターよりも組み込み関数で特に多くの途中放棄が発生します。リファレンス方式で進行されるため面白くないからです。全部やろうとせず、該当機能が必要だと思われる時に受講するのが望ましいです。

セキュリティを忘れないでください。

Session、XSSなどウェブセキュリティについて学習します。PHPは他の言語に比べて参入障壁がやや低いため、むしろセキュリティのような事項が守られないケースが多いです。これはウェブアプリケーション作成において問題となる可能性があり、私たちがたとえセキュリティ専門家ではないとしても、基本的なセキュリティ事項は守る必要があります。

結局、掲示板を作ることになっています。

レガシープロジェクトで掲示板を作成します。白紙からindex.phpを作成することから始まってプロジェクトが進行されます。このような掲示板プロジェクトが現在フレームワーク中心で開発されて動いているWebアプリケーションの世界において合わないかもしれません。しかしPHPのフレームワークであるLaravelを少しでも理解するためにはレガシーでプロジェクトを作成してみる必要があり、驚くことに現場にはレガシーで作成されたPHP 4、PHP 5アプリケーションも多いです。

いつまで、レガシーですか?

レガシーで作成した掲示板プロジェクトを「どのようなアーキテクチャ」を描写しながら似たように真似します。オブジェクト指向で実装した「本物」ではないため言及しません。しかし現在存在するコードを関数化することで、コードが劇的に変化する様子を見ることができます。オブジェクト指向で実装してみることは『PHP 7+ プログラミング:オブジェクト指向』で話す予定です。

講義を受講する前に必要なもの

開発サーバーはビルトイン内蔵サーバーを使用しますが、必要に応じてWAMPのようなツールを使用するか、PHPマニュアルを参考にしてください。

  • PHP 7.4.21 TS(Thread Safe) (64bit)
  • XDebug 3.0.4 TS (64bit)
  • コードエディターはVSCode(Visual Studio Code)を使用します。

フロントエンドにCSS FrameworkとテキストエディターとしてCKEditor 5を使用します。

Q&A

2023年07月24日から個人的な事情により講義に関する質問をお受けしておりません。ただし、これまで数年間に作成された質疑応答はご覧いただけます。コミュニティで質問を探してみることをお勧めします。

公式ドキュメント & 書籍

Q. この講座の後はどのようなことを勉強すればよいでしょうか?

A. オブジェクト指向パートを必ず勉強する必要があります。資料はPHPドキュメントを見るのがまだましです。もちろん、PHPは関数型プログラミングもできるので、それを調べてみるのも良いでしょう。その他にPHP Coding Standard、PSR(PHP Standard Recommendation)なども調べる必要があります。一つ確実なことは、オブジェクト指向を勉強する前にLaravelフレームワークに移るのは避ける方が良いということです。

この講座の次の講座は『PHP 7+ プログラミング:オブジェクト指向』です。今回の講座で関数についての話を主にしたとすれば、オブジェクト指向ではクラスとオブジェクトについての話を主にし、それだけでなくパッケージマネージャーなどもう少し深い内容を見ていきます。

2020年06月09日『PHP 7+ プログラミング: オブジェクト指向』講義が公開されました。

今こそオブジェクト指向で一歩前に進むべき時
『PHP 7+ プログラミング: オブジェクト指向』
PHP 7+ 프로그래밍: 객체지향

こんな方に
おすすめです

学習対象は
誰でしょう?

  • PHP を 学んでみたい 方

  • PHPでウェブサービスを構築してみたい方

  • PHP を しっかり学びたい方

こんにちは
です。

1,739

受講生

73

受講レビュー

187

回答

4.2

講座評価

4

講座

Github: https://github.com/pronist · Email: pronist@naver.com

カリキュラム

全体

71件 ∙ (15時間 33分)

講座資料(こうぎしりょう):

授業資料
講座掲載日: 
最終更新日: 

受講レビュー

全体

30件

3.7

30件の受講レビュー

  • sinnara135792511님의 프로필 이미지
    sinnara135792511

    受講レビュー 2

    平均評価 4.0

    3

    56% 受講後に作成

    The class content is good.. but I wonder if they prepare it.. When explaining functions or logic, why? and how to use it are things that beginners desperately want... Oh my.. I took off 1 point because I skipped over it too quickly. Also, when I skipped around, my pronunciation was slurred a lot, so it was hard to understand. The reason students pay to take the class is because they want to know why functions are used.. how the logic works, but there are almost no cases where they are taught.. Since there aren't many video lectures related to PHP controllers right now, if you have to watch this, I recommend this lecture. :) Please... If it's because of the pronunciation, please put subtitles on it.. Ah! It's good to leave comments.. Of course, it's the students' job to pick out and eat it nutritiously.. I said I'd answer.. I'm not saying that I'll just tell you what I want...ㅎ.ㅐ.

    • dirend79555님의 프로필 이미지
      dirend79555

      受講レビュー 47

      平均評価 5.0

      5

      100% 受講後に作成

      Thank you for opening a good lecture. The students in this lecture understood the http protocol, and although it is a php lecture, it was a good lecture to give those who are just starting to create a web the overall direction and basics of the web. I personally recommend it to those who are worried about how to configure basic security when creating a web for the first time. The teacher kindly answered many questions, so I was able to complete the copy project safely. (I was honored that my question was listed as a reference question!!^^) While waiting for the next lecture, I hope you make the code font a little bigger.^^ Thank you!!

      • pronist
        知識共有者

        Oh, thank you for leaving a review. The object-oriented section has been made up to the grammar section, but I think the font size should be increased for the next section. (You are the first person to complete this course. Thank you!)

    • ghzm02641021님의 프로필 이미지
      ghzm02641021

      受講レビュー 7

      平均評価 4.1

      3

      37% 受講後に作成

      I wish you could pronounce it correctly.. I'm a little disappointed that I can't hear what you're saying even though I'm concentrating on it. The lecture itself is easy..

      • pronist
        知識共有者

        Thank you for the review! I think my pronunciation was a bit awkward because it was my first lecture. xD + And then I realized.. I guess I'll have to re-encode it and make the sound louder.. ㅜㅜ

    • henu님의 프로필 이미지
      henu

      受講レビュー 9

      平均評価 5.0

      5

      100% 受講後に作成

      The main language for development work is JAVA, but I am maintaining legacy projects created with PHP 5.* versions. In the case of PHP, I learned it by myself with a thin book and working on the job. When I was working on advanced tasks, I felt frustrated because I didn't have a deep knowledge of PHP. However, after taking this lecture, I had the opportunity to properly learn about PHP's basic grammar and development methods. Of course, I learned based on PHP 7, but there was no problem applying what I learned in this lecture to a PHP 5.* project. I think proper learning of version 7 would start with the OOP lecture. I will take a break here for a while and review my work and study the OOP lecture. I would like to thank the instructor who answered my questions with sincerity, and the instructor who gave me the opportunity to learn modern PHP.

      • pronist
        知識共有者

        Thank you for watching the lecture. Looking back, it was a lecture that had many shortcomings in explanation and various aspects, but I am glad that you understood it. Thank you for leaving a review. If you have any questions about the object-oriented lecture, please ask questions. ㅎㅎ

    • devedu1609님의 프로필 이미지
      devedu1609

      受講レビュー 2

      平均評価 4.5

      4

      100% 受講後に作成

      path patch, rewind rewind this part is too... yes... well...

      • pronist
        知識共有者

        Oh, I pronounced it wrong lol I'll reflect on it. Are the other parts okay? If there are any other problems besides what you mentioned in other class reviews, please let me know :) I'll be able to improve it in future classes.

      • In Section 4, you created a legacy project example and talked about the problems, and you said you would fix these parts in Section 5. When you create a functions.php file in the lib folder, it feels like you just copy and paste this part when creating a bulletin board. Of course, you will understand it after you create it all. Do you actually create it like this when you implement it? Before starting Section 5, I think it would be good to explain how Laravel follows the structure, how I organized the folders, how this folder was organized, and why it was created this way. When I wrote the legacy code, it was like this, but I will change this part like this. If you tell me in advance and proceed with the lecture, I think it will be easier to understand.

      • pronist
        知識共有者

        I definitely can't seem to shake off the idea that functions.php is being created all at once. I also agree that there was a lack of additional explanation. Good. Thank you for your valuable opinion. :)

    ¥6,533

    pronistの他の講座

    知識共有者の他の講座を見てみましょう!

    似ている講座

    同じ分野の他の講座を見てみましょう!