Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
PHP or die
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Kosuke Ogawa
January 22, 2021
Technology
290
0
Share
PHP or die
Webナイト宮崎 Vol.12 ~てげPHP学びたい~ - connpass
https://tegehoge.connpass.com/event/199828/
Kosuke Ogawa
January 22, 2021
More Decks by Kosuke Ogawa
See All by Kosuke Ogawa
TypeScript リテラル型について
koogawa
1
280
Nuxt.js で非同期なデータを取得するときのポイント
koogawa
0
330
Vue 入門者が日報ツールを作ってみた
koogawa
1
370
地方に住むエンジニアがこの先生きのこるには
koogawa
0
1.2k
Firestore のデータ設計について
koogawa
0
820
はじめてウェブサイトで Firebase を使ってみた
koogawa
1
470
iOSアプリ開発におけるJavaScript
koogawa
1
450
Stack Overflow活動 その後の活動報告
koogawa
1
210
「まりも」と iOS の 6年間
koogawa
4
7.4k
Other Decks in Technology
See All in Technology
🀄️ on swiftc
giginet
PRO
0
330
暗黙知について一歩踏み込んで考える - 暗黙知の4タイプと暗黙考・暗黙動へ
masayamoriofficial
0
1.3k
Introduction to Sansan Meishi Maker Development Engineer
sansan33
PRO
0
380
Contract One Engineering Unit 紹介資料
sansan33
PRO
0
16k
DevOpsDays2026 Tokyo Cross-border practices to connect "safety" and "DX" in healthcare
hokkai7go
0
130
OBI+APMでお手軽にアプリケーションのオブザーバビリティを手に入れよう
kenshimuto
0
230
機能・非機能の学びを一つに!Agent Skillsで月間レポート作成始めてみた / Unifying Bug & Infra Insights — Building Monthly Quality Reports with Agent Skills
bun913
5
4k
会社紹介資料 / Sansan Company Profile
sansan33
PRO
16
410k
NOSTR, réseau social et espace de liberté décentralisé
rlifchitz
0
160
非エンジニア職からZOZOへ 〜登壇がキャリアに与えた影響〜
penpeen
0
180
Master Dataグループ紹介資料
sansan33
PRO
1
4.6k
数案件を同時に進行するためのコンテキスト整理術
sutetotanuki
1
200
Featured
See All Featured
Discover your Explorer Soul
emna__ayadi
2
1.1k
Connecting the Dots Between Site Speed, User Experience & Your Business [WebExpo 2025]
tammyeverts
11
880
Sam Torres - BigQuery for SEOs
techseoconnect
PRO
0
240
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
55
3.3k
How to Think Like a Performance Engineer
csswizardry
28
2.5k
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
35
3.4k
For a Future-Friendly Web
brad_frost
183
10k
A brief & incomplete history of UX Design for the World Wide Web: 1989–2019
jct
1
350
Skip the Path - Find Your Career Trail
mkilby
1
100
The agentic SEO stack - context over prompts
schlessera
0
740
The Illustrated Children's Guide to Kubernetes
chrisshort
51
52k
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
38
2.8k
Transcript
PHP OR DIE WebφΠτٶ࡚ Vol.12
ࣗݾհ ➤0HBXB,PTVLFʢ!LPPHBXBʣ ➤Ξϧגࣜձࣾ ➤ٶ࡚͔Β౦ژʹϑϧϦϞʔτ ➤J04 4XJGU "OESPJE ,PUMJO 5ZQF4DSJQU
$44 7VFKT /VYUKTͳͲ ➤ݸਓ։ൃͰ1)1ʢࣝ7FSY Ͱࢭ·ͬͯΔʣ
Α͘ݟΔʁίʔυ
ಉ͡ϊϦͰ͜͏͔ͨͬͨ͠ PHP Parse error: syntax error, unexpected 'return'
https://stackoverflow.com/questions/14393173/in-php-why-does-or-die-work-but-or-return-doesnt
ͭ·Γɺreturn ʮࣜʯͰͳ͍
“ࣜɺPHP ʹ͓͚Δ࠷ॏཁͳϏϧσΟϯάϒ ϩοΫͰ͢ɻPHPʹ͓͍ͯɺ΄ͱΜͲશͯͷ ͷࣜͰهड़͞Ε·͢ɻ ࠷؆୯Ͱ࠷ਖ਼֬ͳ ࣜͷఆٛɺ"͕͋Δͷશͯ"Ͱ͢ɻ ࣜͱ - PHPϚχϡΞϧ
ࣜͷྫ ➤$a = 5 ➤5 5 ͱ͍͏Λ༗͢Δʮࣜʯ ➤$b =
$a ➤$a 5 ͱ͍͏Λ࣋ͭʮࣜʯ ➤$c = foo(); ➤foo() ԿΒ͔ͷΛฦ͢ʮࣜʯ
࠷ॳͷྫΛࢥ͍ग़ͯ͠ΈΔ ➤ $fp = false or die(“hoge”); ΤϥʔʹͳΒͳ͍ ➤ $fp
= false or return 0; PHP Parse error: syntax error, unexpected ‘return' $fp = ࣜ1 or ࣜ2
݁ɿΑͬͯɺ࣍ͷίʔυΤϥʔʹͳΔ PHP Parse error: syntax error, unexpected 'return'
RETURN ➤ ੍ޚߏͷͻͱͭ
͋Γ͕ͱ͏ ͍͟͝·ͨ͠