ºÝºÝߣ

ºÝºÝߣShare a Scribd company logo
<?php 
?> 
echo `An introduction to PHP`;
<?php 
?> 
echo `An introduction to PHP`; 
echo `7 reasons why it¡¯s yucky`;
<?php 
?> 
echo `First, the good parts`; 
var_dump([ 
`Web¡¯s most popular server lang`, 
`Incredibly easy to deploy`, 
`WordPress, uber popular framework`, 
`Templating is built-in` 
]);
<?php 
?> 
echo `Problem #1`; 
echo `Templating is built-in`; 
foreach($arr as $el) { 
echo `<p>`; 
echo doSomeMysteriousThing($el); 
echo `</p>`; 
}
<?php 
?> 
echo `Problem #2`; 
echo `It can be very inconsistent`; 
echo 'hello nworld'; 
// hello nworld 
echo "hello nworld"; 
// hello 
// world
<?php 
?> 
echo `Problem #3`; 
echo `Everything is a function!!!`; 
array_push($arr, `abc`); // 5.3 
array_key_exists($arr, `abc`); // bool 
$r = array_merge($arr, [`abc`]); 
$r = array_map(`func`, $arr); 
$r = count($arr);
<?php 
?> 
echo `Problem #4`; 
echo `Equality is unequal`; 
`6` == ` 6` // true 
`133` == `0133` && 133 != 0133; // true 
`foo` == 0 && `foo` == true; // true 
NULL < -1 && NULL == 0; // true
<?php 
?> 
echo `Problem #5`; 
echo `Scope is weird...`; 
if (1 === 1) { $v = `if`; } 
function a() { $v = `a`; } 
function b() { global $v; $v = `b`; } 
a(); echo $v; // `if` 
b(); echo $v; // `b`
<?php 
?> 
echo `Problem #6`; 
echo `Debugging is terrible!`; 
echo $arr; // `Array` 
print_r($arr); // Array ( [0] => 1 [1] 
var_dump($arr); // array(4) { [0]=> int( 
var_dump(debug_backtrace());
<?php 
?> 
echo `Problem #7`; 
echo `Documentation is terrible`; 
echo ($documentation == $forum); 
// 1
<?php 
?> 
echo `In the end...`;
<?php 
?> 
echo `In the end...`; 
echo `...it doesn¡¯t matter that much`; 
$u = `http://blog.codinghorror.com/`; 
$u .= `php-sucks-but-it-doesnt-matter`; 
echo $u;

More Related Content

What's hot (18)

Presentation on php string function part-1
Presentation on php string function part-1Presentation on php string function part-1
Presentation on php string function part-1
Mysoftheaven (BD) Ltd.
?
Barely Legal Xxx Perl Presentation
Barely Legal Xxx Perl PresentationBarely Legal Xxx Perl Presentation
Barely Legal Xxx Perl Presentation
Attila Balazs
?
PHP and Databases
PHP and DatabasesPHP and Databases
PHP and Databases
Things Lab
?
Unix shell scripting basics
Unix shell scripting basicsUnix shell scripting basics
Unix shell scripting basics
Abhay Sapru
?
Three Objectionable Things
Three Objectionable ThingsThree Objectionable Things
Three Objectionable Things
Pete Goodliffe
?
De 0 a 100 con Bash Shell Scripting y AWK
De 0 a 100 con Bash Shell Scripting y AWKDe 0 a 100 con Bash Shell Scripting y AWK
De 0 a 100 con Bash Shell Scripting y AWK
Adolfo Sanz De Diego
?
Generating Power with Yield
Generating Power with YieldGenerating Power with Yield
Generating Power with Yield
Jason Myers
?
Synapseindia php development tutorial
Synapseindia php development tutorialSynapseindia php development tutorial
Synapseindia php development tutorial
Synapseindiappsdevelopment
?
PHP an intro -1
PHP an intro -1PHP an intro -1
PHP an intro -1
Kanchilug
?
PHPer¤Î¤¿¤á¤ÎPerlÈëéT@ Kansai.pm#12
PHPer¤Î¤¿¤á¤ÎPerlÈëéT@ Kansai.pm#12PHPer¤Î¤¿¤á¤ÎPerlÈëéT@ Kansai.pm#12
PHPer¤Î¤¿¤á¤ÎPerlÈëéT@ Kansai.pm#12
Kazuki KOMORI
?
PHP Basics and Demo HackU
PHP Basics and Demo HackUPHP Basics and Demo HackU
PHP Basics and Demo HackU
Anshu Prateek
?
Scratching the surface of hunky-dory Elixir features
Scratching the surface of hunky-dory Elixir featuresScratching the surface of hunky-dory Elixir features
Scratching the surface of hunky-dory Elixir features
Adam Hodowany
?
Troubleshooting Plone
Troubleshooting PloneTroubleshooting Plone
Troubleshooting Plone
Ricado Alves
?
"Character sets and iconv" PHP source code
"Character sets and iconv" PHP source code"Character sets and iconv" PHP source code
"Character sets and iconv" PHP source code
Daniel_Rhodes
?
Django Environment
Django EnvironmentDjango Environment
Django Environment
Loren Davie
?
Bloqueador cmd-sh
Bloqueador cmd-shBloqueador cmd-sh
Bloqueador cmd-sh
msbertoldi
?
QNlocal: Docker, Continuous Integration, WordPress e milioni di visite. Si ¨¨ ...
QNlocal: Docker, Continuous Integration, WordPress e milioni di visite. Si ¨¨ ...QNlocal: Docker, Continuous Integration, WordPress e milioni di visite. Si ¨¨ ...
QNlocal: Docker, Continuous Integration, WordPress e milioni di visite. Si ¨¨ ...
alessandro mazzoli
?
Php mysql
Php mysqlPhp mysql
Php mysql
Alebachew Zewdu
?
Presentation on php string function part-1
Presentation on php string function part-1Presentation on php string function part-1
Presentation on php string function part-1
Mysoftheaven (BD) Ltd.
?
Barely Legal Xxx Perl Presentation
Barely Legal Xxx Perl PresentationBarely Legal Xxx Perl Presentation
Barely Legal Xxx Perl Presentation
Attila Balazs
?
PHP and Databases
PHP and DatabasesPHP and Databases
PHP and Databases
Things Lab
?
Unix shell scripting basics
Unix shell scripting basicsUnix shell scripting basics
Unix shell scripting basics
Abhay Sapru
?
Three Objectionable Things
Three Objectionable ThingsThree Objectionable Things
Three Objectionable Things
Pete Goodliffe
?
De 0 a 100 con Bash Shell Scripting y AWK
De 0 a 100 con Bash Shell Scripting y AWKDe 0 a 100 con Bash Shell Scripting y AWK
De 0 a 100 con Bash Shell Scripting y AWK
Adolfo Sanz De Diego
?
Generating Power with Yield
Generating Power with YieldGenerating Power with Yield
Generating Power with Yield
Jason Myers
?
PHPer¤Î¤¿¤á¤ÎPerlÈëéT@ Kansai.pm#12
PHPer¤Î¤¿¤á¤ÎPerlÈëéT@ Kansai.pm#12PHPer¤Î¤¿¤á¤ÎPerlÈëéT@ Kansai.pm#12
PHPer¤Î¤¿¤á¤ÎPerlÈëéT@ Kansai.pm#12
Kazuki KOMORI
?
PHP Basics and Demo HackU
PHP Basics and Demo HackUPHP Basics and Demo HackU
PHP Basics and Demo HackU
Anshu Prateek
?
Scratching the surface of hunky-dory Elixir features
Scratching the surface of hunky-dory Elixir featuresScratching the surface of hunky-dory Elixir features
Scratching the surface of hunky-dory Elixir features
Adam Hodowany
?
Troubleshooting Plone
Troubleshooting PloneTroubleshooting Plone
Troubleshooting Plone
Ricado Alves
?
"Character sets and iconv" PHP source code
"Character sets and iconv" PHP source code"Character sets and iconv" PHP source code
"Character sets and iconv" PHP source code
Daniel_Rhodes
?
Bloqueador cmd-sh
Bloqueador cmd-shBloqueador cmd-sh
Bloqueador cmd-sh
msbertoldi
?
QNlocal: Docker, Continuous Integration, WordPress e milioni di visite. Si ¨¨ ...
QNlocal: Docker, Continuous Integration, WordPress e milioni di visite. Si ¨¨ ...QNlocal: Docker, Continuous Integration, WordPress e milioni di visite. Si ¨¨ ...
QNlocal: Docker, Continuous Integration, WordPress e milioni di visite. Si ¨¨ ...
alessandro mazzoli
?

Similar to An Introduction to PHP... and Why It's Yucky! (20)

Introduction to PHP
Introduction to PHPIntroduction to PHP
Introduction to PHP
Bradley Holt
?
Php Lecture Notes
Php Lecture NotesPhp Lecture Notes
Php Lecture Notes
Santhiya Grace
?
Perl basics for Pentesters
Perl basics for PentestersPerl basics for Pentesters
Perl basics for Pentesters
Sanjeev Kumar Jaiswal
?
Php hacku
Php hackuPhp hacku
Php hacku
Tom Praison Praison
?
Web 8 | Introduction to PHP
Web 8 | Introduction to PHPWeb 8 | Introduction to PHP
Web 8 | Introduction to PHP
Mohammad Imam Hossain
?
2014 database - course 2 - php
2014 database - course 2 - php2014 database - course 2 - php
2014 database - course 2 - php
Hung-yu Lin
?
HackU PHP and Node.js
HackU PHP and Node.jsHackU PHP and Node.js
HackU PHP and Node.js
souridatta
?
Php Crash Course - Macq Electronique 2010
Php Crash Course - Macq Electronique 2010Php Crash Course - Macq Electronique 2010
Php Crash Course - Macq Electronique 2010
Michelangelo van Dam
?
PHP for hacks
PHP for hacksPHP for hacks
PHP for hacks
Tom Praison Praison
?
Perl Moderno
Perl ModernoPerl Moderno
Perl Moderno
Tiago Peczenyj
?
Unix Shell Scripting Basics
Unix Shell Scripting BasicsUnix Shell Scripting Basics
Unix Shell Scripting Basics
Dr.Ravi
?
Top 10 php classic traps php serbia
Top 10 php classic traps php serbiaTop 10 php classic traps php serbia
Top 10 php classic traps php serbia
Damien Seguy
?
Node.js for PHP developers
Node.js for PHP developersNode.js for PHP developers
Node.js for PHP developers
Andrew Eddie
?
My shell
My shellMy shell
My shell
Ahmed Salah
?
Good Evils In Perl
Good Evils In PerlGood Evils In Perl
Good Evils In Perl
Kang-min Liu
?
slidesharenew1
slidesharenew1slidesharenew1
slidesharenew1
truptitasol
?
My cool new ºÝºÝߣshow!
My cool new ºÝºÝߣshow!My cool new ºÝºÝߣshow!
My cool new ºÝºÝߣshow!
omprakash_bagrao_prdxn
?
Building Modern and Secure PHP Applications ¨C Codementor Office Hours with Be...
Building Modern and Secure PHP Applications ¨C Codementor Office Hours with Be...Building Modern and Secure PHP Applications ¨C Codementor Office Hours with Be...
Building Modern and Secure PHP Applications ¨C Codementor Office Hours with Be...
Arc & Codementor
?
Modern Perl
Modern PerlModern Perl
Modern Perl
Marcos Rebelo
?
Zend Certification Preparation Tutorial
Zend Certification Preparation TutorialZend Certification Preparation Tutorial
Zend Certification Preparation Tutorial
Lorna Mitchell
?

Recently uploaded (20)

World Information Architecture Day 2025 - UX at a Crossroads
World Information Architecture Day 2025 - UX at a CrossroadsWorld Information Architecture Day 2025 - UX at a Crossroads
World Information Architecture Day 2025 - UX at a Crossroads
Joshua Randall
?
Transform Your Future with Front-End Development Training
Transform Your Future with Front-End Development TrainingTransform Your Future with Front-End Development Training
Transform Your Future with Front-End Development Training
Vtechlabs
?
Gojek Clone Multi-Service Super App.pptx
Gojek Clone Multi-Service Super App.pptxGojek Clone Multi-Service Super App.pptx
Gojek Clone Multi-Service Super App.pptx
V3cube
?
UiPath Agentic Automation Capabilities and Opportunities
UiPath Agentic Automation Capabilities and OpportunitiesUiPath Agentic Automation Capabilities and Opportunities
UiPath Agentic Automation Capabilities and Opportunities
DianaGray10
?
Fl studio crack version 12.9 Free Download
Fl studio crack version 12.9 Free DownloadFl studio crack version 12.9 Free Download
Fl studio crack version 12.9 Free Download
kherorpacca127
?
Unlock AI Creativity: Image Generation with DALL¡¤E
Unlock AI Creativity: Image Generation with DALL¡¤EUnlock AI Creativity: Image Generation with DALL¡¤E
Unlock AI Creativity: Image Generation with DALL¡¤E
Expeed Software
?
Deno ...................................
Deno ...................................Deno ...................................
Deno ...................................
Robert MacLean
?
FinTech - US Annual Funding Report - 2024.pptx
FinTech - US Annual Funding Report - 2024.pptxFinTech - US Annual Funding Report - 2024.pptx
FinTech - US Annual Funding Report - 2024.pptx
Tracxn
?
Wondershare Dr.Fone Crack Free Download 2025
Wondershare Dr.Fone Crack Free Download 2025Wondershare Dr.Fone Crack Free Download 2025
Wondershare Dr.Fone Crack Free Download 2025
maharajput103
?
SMART SENTRY CYBER THREAT INTELLIGENCE IN IIOT
SMART SENTRY CYBER THREAT INTELLIGENCE IN IIOTSMART SENTRY CYBER THREAT INTELLIGENCE IN IIOT
SMART SENTRY CYBER THREAT INTELLIGENCE IN IIOT
TanmaiArni
?
TrustArc Webinar - Building your DPIA/PIA Program: Best Practices & Tips
TrustArc Webinar - Building your DPIA/PIA Program: Best Practices & TipsTrustArc Webinar - Building your DPIA/PIA Program: Best Practices & Tips
TrustArc Webinar - Building your DPIA/PIA Program: Best Practices & Tips
TrustArc
?
THE BIG TEN BIOPHARMACEUTICAL MNCs: GLOBAL CAPABILITY CENTERS IN INDIA
THE BIG TEN BIOPHARMACEUTICAL MNCs: GLOBAL CAPABILITY CENTERS IN INDIATHE BIG TEN BIOPHARMACEUTICAL MNCs: GLOBAL CAPABILITY CENTERS IN INDIA
THE BIG TEN BIOPHARMACEUTICAL MNCs: GLOBAL CAPABILITY CENTERS IN INDIA
Srivaanchi Nathan
?
Brave Browser Crack 1.45.133 Activated 2025
Brave Browser Crack 1.45.133 Activated 2025Brave Browser Crack 1.45.133 Activated 2025
Brave Browser Crack 1.45.133 Activated 2025
kherorpacca00126
?
MIND Revenue Release Quarter 4 2024 - Finacial Presentation
MIND Revenue Release Quarter 4 2024 - Finacial PresentationMIND Revenue Release Quarter 4 2024 - Finacial Presentation
MIND Revenue Release Quarter 4 2024 - Finacial Presentation
MIND CTI
?
Unlocking DevOps Secuirty :Vault & Keylock
Unlocking DevOps Secuirty :Vault & KeylockUnlocking DevOps Secuirty :Vault & Keylock
Unlocking DevOps Secuirty :Vault & Keylock
HusseinMalikMammadli
?
Stronger Together: Combining Data Quality and Governance for Confident AI & A...
Stronger Together: Combining Data Quality and Governance for Confident AI & A...Stronger Together: Combining Data Quality and Governance for Confident AI & A...
Stronger Together: Combining Data Quality and Governance for Confident AI & A...
Precisely
?
Wondershare Filmora Crack 14.3.2.11147 Latest
Wondershare Filmora Crack 14.3.2.11147 LatestWondershare Filmora Crack 14.3.2.11147 Latest
Wondershare Filmora Crack 14.3.2.11147 Latest
udkg888
?
Field Device Management Market Report 2030 - TechSci Research
Field Device Management Market Report 2030 - TechSci ResearchField Device Management Market Report 2030 - TechSci Research
Field Device Management Market Report 2030 - TechSci Research
Vipin Mishra
?
How Discord Indexes Trillions of Messages: Scaling Search Infrastructure by V...
How Discord Indexes Trillions of Messages: Scaling Search Infrastructure by V...How Discord Indexes Trillions of Messages: Scaling Search Infrastructure by V...
How Discord Indexes Trillions of Messages: Scaling Search Infrastructure by V...
ScyllaDB
?
Cloud of everything Tech of the 21 century in Aviation
Cloud of everything Tech of the 21 century in AviationCloud of everything Tech of the 21 century in Aviation
Cloud of everything Tech of the 21 century in Aviation
Assem mousa
?
World Information Architecture Day 2025 - UX at a Crossroads
World Information Architecture Day 2025 - UX at a CrossroadsWorld Information Architecture Day 2025 - UX at a Crossroads
World Information Architecture Day 2025 - UX at a Crossroads
Joshua Randall
?
Transform Your Future with Front-End Development Training
Transform Your Future with Front-End Development TrainingTransform Your Future with Front-End Development Training
Transform Your Future with Front-End Development Training
Vtechlabs
?
Gojek Clone Multi-Service Super App.pptx
Gojek Clone Multi-Service Super App.pptxGojek Clone Multi-Service Super App.pptx
Gojek Clone Multi-Service Super App.pptx
V3cube
?
UiPath Agentic Automation Capabilities and Opportunities
UiPath Agentic Automation Capabilities and OpportunitiesUiPath Agentic Automation Capabilities and Opportunities
UiPath Agentic Automation Capabilities and Opportunities
DianaGray10
?
Fl studio crack version 12.9 Free Download
Fl studio crack version 12.9 Free DownloadFl studio crack version 12.9 Free Download
Fl studio crack version 12.9 Free Download
kherorpacca127
?
Unlock AI Creativity: Image Generation with DALL¡¤E
Unlock AI Creativity: Image Generation with DALL¡¤EUnlock AI Creativity: Image Generation with DALL¡¤E
Unlock AI Creativity: Image Generation with DALL¡¤E
Expeed Software
?
Deno ...................................
Deno ...................................Deno ...................................
Deno ...................................
Robert MacLean
?
FinTech - US Annual Funding Report - 2024.pptx
FinTech - US Annual Funding Report - 2024.pptxFinTech - US Annual Funding Report - 2024.pptx
FinTech - US Annual Funding Report - 2024.pptx
Tracxn
?
Wondershare Dr.Fone Crack Free Download 2025
Wondershare Dr.Fone Crack Free Download 2025Wondershare Dr.Fone Crack Free Download 2025
Wondershare Dr.Fone Crack Free Download 2025
maharajput103
?
SMART SENTRY CYBER THREAT INTELLIGENCE IN IIOT
SMART SENTRY CYBER THREAT INTELLIGENCE IN IIOTSMART SENTRY CYBER THREAT INTELLIGENCE IN IIOT
SMART SENTRY CYBER THREAT INTELLIGENCE IN IIOT
TanmaiArni
?
TrustArc Webinar - Building your DPIA/PIA Program: Best Practices & Tips
TrustArc Webinar - Building your DPIA/PIA Program: Best Practices & TipsTrustArc Webinar - Building your DPIA/PIA Program: Best Practices & Tips
TrustArc Webinar - Building your DPIA/PIA Program: Best Practices & Tips
TrustArc
?
THE BIG TEN BIOPHARMACEUTICAL MNCs: GLOBAL CAPABILITY CENTERS IN INDIA
THE BIG TEN BIOPHARMACEUTICAL MNCs: GLOBAL CAPABILITY CENTERS IN INDIATHE BIG TEN BIOPHARMACEUTICAL MNCs: GLOBAL CAPABILITY CENTERS IN INDIA
THE BIG TEN BIOPHARMACEUTICAL MNCs: GLOBAL CAPABILITY CENTERS IN INDIA
Srivaanchi Nathan
?
Brave Browser Crack 1.45.133 Activated 2025
Brave Browser Crack 1.45.133 Activated 2025Brave Browser Crack 1.45.133 Activated 2025
Brave Browser Crack 1.45.133 Activated 2025
kherorpacca00126
?
MIND Revenue Release Quarter 4 2024 - Finacial Presentation
MIND Revenue Release Quarter 4 2024 - Finacial PresentationMIND Revenue Release Quarter 4 2024 - Finacial Presentation
MIND Revenue Release Quarter 4 2024 - Finacial Presentation
MIND CTI
?
Unlocking DevOps Secuirty :Vault & Keylock
Unlocking DevOps Secuirty :Vault & KeylockUnlocking DevOps Secuirty :Vault & Keylock
Unlocking DevOps Secuirty :Vault & Keylock
HusseinMalikMammadli
?
Stronger Together: Combining Data Quality and Governance for Confident AI & A...
Stronger Together: Combining Data Quality and Governance for Confident AI & A...Stronger Together: Combining Data Quality and Governance for Confident AI & A...
Stronger Together: Combining Data Quality and Governance for Confident AI & A...
Precisely
?
Wondershare Filmora Crack 14.3.2.11147 Latest
Wondershare Filmora Crack 14.3.2.11147 LatestWondershare Filmora Crack 14.3.2.11147 Latest
Wondershare Filmora Crack 14.3.2.11147 Latest
udkg888
?
Field Device Management Market Report 2030 - TechSci Research
Field Device Management Market Report 2030 - TechSci ResearchField Device Management Market Report 2030 - TechSci Research
Field Device Management Market Report 2030 - TechSci Research
Vipin Mishra
?
How Discord Indexes Trillions of Messages: Scaling Search Infrastructure by V...
How Discord Indexes Trillions of Messages: Scaling Search Infrastructure by V...How Discord Indexes Trillions of Messages: Scaling Search Infrastructure by V...
How Discord Indexes Trillions of Messages: Scaling Search Infrastructure by V...
ScyllaDB
?
Cloud of everything Tech of the 21 century in Aviation
Cloud of everything Tech of the 21 century in AviationCloud of everything Tech of the 21 century in Aviation
Cloud of everything Tech of the 21 century in Aviation
Assem mousa
?

An Introduction to PHP... and Why It's Yucky!

  • 1. <?php ?> echo `An introduction to PHP`;
  • 2. <?php ?> echo `An introduction to PHP`; echo `7 reasons why it¡¯s yucky`;
  • 3. <?php ?> echo `First, the good parts`; var_dump([ `Web¡¯s most popular server lang`, `Incredibly easy to deploy`, `WordPress, uber popular framework`, `Templating is built-in` ]);
  • 4. <?php ?> echo `Problem #1`; echo `Templating is built-in`; foreach($arr as $el) { echo `<p>`; echo doSomeMysteriousThing($el); echo `</p>`; }
  • 5. <?php ?> echo `Problem #2`; echo `It can be very inconsistent`; echo 'hello nworld'; // hello nworld echo "hello nworld"; // hello // world
  • 6. <?php ?> echo `Problem #3`; echo `Everything is a function!!!`; array_push($arr, `abc`); // 5.3 array_key_exists($arr, `abc`); // bool $r = array_merge($arr, [`abc`]); $r = array_map(`func`, $arr); $r = count($arr);
  • 7. <?php ?> echo `Problem #4`; echo `Equality is unequal`; `6` == ` 6` // true `133` == `0133` && 133 != 0133; // true `foo` == 0 && `foo` == true; // true NULL < -1 && NULL == 0; // true
  • 8. <?php ?> echo `Problem #5`; echo `Scope is weird...`; if (1 === 1) { $v = `if`; } function a() { $v = `a`; } function b() { global $v; $v = `b`; } a(); echo $v; // `if` b(); echo $v; // `b`
  • 9. <?php ?> echo `Problem #6`; echo `Debugging is terrible!`; echo $arr; // `Array` print_r($arr); // Array ( [0] => 1 [1] var_dump($arr); // array(4) { [0]=> int( var_dump(debug_backtrace());
  • 10. <?php ?> echo `Problem #7`; echo `Documentation is terrible`; echo ($documentation == $forum); // 1
  • 11. <?php ?> echo `In the end...`;
  • 12. <?php ?> echo `In the end...`; echo `...it doesn¡¯t matter that much`; $u = `http://blog.codinghorror.com/`; $u .= `php-sucks-but-it-doesnt-matter`; echo $u;