O slideshow foi denunciado.
Utilizamos seu perfil e dados de atividades no LinkedIn para personalizar e exibir anúncios mais relevantes. Altere suas preferências de anúncios quando desejar.
Globalcode – Open4education
Trilha – PHP
Vá para o próximo nível - Dicas e truques para a
certificação PHP
marabesi
@MatheusMarabesi
ZENDSC10X
10/jun
HELP
WANTED !
http://phingbrasil.com.br
Who doesn’t
want to be
certified ?
????????
$coração = 'Hello';
echo $coração;
class Cächaça
{
}
$cachaça = new Cächaça();
BITWISE
a bitwise operation operates on one or more
bit patterns or binary numerals at the level of
their individual bits.
It is a...
& AND
| OR
^ XOR
>> RIGHT
<< LEFT
Bits that are set in
both $a AND $b
are set.
http://php.net/manual/en/language.operators.bitwise.php
& - AND
0 & 0 = 0
0 & 1 = 0
1 & 0 = 0
1 & 1 = 1
print (4 & 8);
Bits that are set in
either $a OR $b
are set.
http://php.net/manual/en/language.operators.bitwise.php
| - OR
0 | 0 = 0
0 | 1 = 1
1 | 0 = 1
1 | 1 = 1
print (2 | 7);
Bits that are set in
$a OR $b but not
BOTH are set.
http://php.net/manual/en/language.operators.bitwise.php
| - XOR
0 ^ 0 = 0
0 ^ 1 = 1
1 ^ 0 = 1
1 ^ 1 = 0
print (3 ^ 9);
128 64 32 16 8 4 2 1
1 1 1 1 1 1 1 1 255
128 64 32 16 8 4 2 1
0 0 0 0 0 1 0 0 4
0 0 0 0 1 0 0 0 8
print (4 & 8);
& - AND
128 64 32 16 8 4 2 1
0 0 0 0 0 0 1 0 2
0 0 0 0 0 1 1 1 7
print (2 | 7);
| - OR
128 64 32 16 8 4 2 1
0 0 0 0 0 0 1 1 3
0 0 0 0 1 0 0 1 9
print (3 ^ 9);
^ - XOR
& AND
| OR
^ XOR
>> RIGHT
<< LEFT
Shift the bits of $a
$b steps to the right
(each step means
"divide by two")
http://php.net/manual/en/language.operators.b...
bit leftmost / 2 ^ bit rightmost
>> - Shift right
print (4 >> 6);
4 / 2 ^ 6 = 0
Shift the bits of $a $b
steps to the left (each
step means "multiply
by two")
http://php.net/manual/en/language.operators....
bit leftmost * 2 ^ bit rightmost
<< - Shift left
print (7 << 9);
7 * 2 ^ 9 = 3584
& AND
| OR
^ XOR
>> RIGHT
<< LEFT
Bits that are set in
$a are not set, and
vice versa.
http://php.net/manual/en/language.operators.bitwise.php
~ - Not
~x = -x -1
print (~9);
~9 = -9 -1 = -10
exit(253);
php execute.php
http://www.phpinternalsbook.com/
STREAMS
$context = stream_context_create([
'http' => [
'method' => 'GET'
]
]);
print file_get_contents(
'http://api.phpconference....
$context = stream_context_create([
'http' => [
'method' => 'POST',
'header' => 'Content-Type: application/x-www-form-urlen...
O.O.PObject . Oriented . Programming
LATE STATIC BINDING
X
SELF
class A {
public static function who() {
echo __CLASS__;
}
public static function test() {
self::who();
}
}
class B extend...
class A {
public static function who() {
echo __CLASS__;
}
public static function test() {
static::who();
}
}
class B exte...
OBJECT CLONING
class A {
public $name;
}
$a = new A();
$b = clone $a;
var_dump($a == $b);
class A {
public $name;
}
$a = new A();
$a->name = 'Ana';
$b = clone $a;
$b->name = 'Clark';
var_dump($a == $b);
class B {
public $lastName;
}
class A {
public $name;
public $lastName;
public function __construct()
{
$this->lastName = ...
ARRAY
sort();
rsort();
asort();
ksort();
krsort();
usort();
A
K
U
R
ASSOCIATIVE
KEY
USER
REVERSE
sort();
rsort();
asort();
ksort();
krsort();
usort();
array_diff_ukey
array_diff_uassoc
array_​intersect_​assoc
array_​intersect_​uassoc
array_​intersect_​ukey
DON’T
FORGET !
marabesi
@MatheusMarabesi
TDC 2016 (Florianópolis) - Vá para o próximo nível - Dicas e truques para a certificação PHP (PT-BR)
TDC 2016 (Florianópolis) - Vá para o próximo nível - Dicas e truques para a certificação PHP (PT-BR)
TDC 2016 (Florianópolis) - Vá para o próximo nível - Dicas e truques para a certificação PHP (PT-BR)
TDC 2016 (Florianópolis) - Vá para o próximo nível - Dicas e truques para a certificação PHP (PT-BR)
TDC 2016 (Florianópolis) - Vá para o próximo nível - Dicas e truques para a certificação PHP (PT-BR)
TDC 2016 (Florianópolis) - Vá para o próximo nível - Dicas e truques para a certificação PHP (PT-BR)
TDC 2016 (Florianópolis) - Vá para o próximo nível - Dicas e truques para a certificação PHP (PT-BR)
TDC 2016 (Florianópolis) - Vá para o próximo nível - Dicas e truques para a certificação PHP (PT-BR)
TDC 2016 (Florianópolis) - Vá para o próximo nível - Dicas e truques para a certificação PHP (PT-BR)
TDC 2016 (Florianópolis) - Vá para o próximo nível - Dicas e truques para a certificação PHP (PT-BR)
TDC 2016 (Florianópolis) - Vá para o próximo nível - Dicas e truques para a certificação PHP (PT-BR)
TDC 2016 (Florianópolis) - Vá para o próximo nível - Dicas e truques para a certificação PHP (PT-BR)
TDC 2016 (Florianópolis) - Vá para o próximo nível - Dicas e truques para a certificação PHP (PT-BR)
TDC 2016 (Florianópolis) - Vá para o próximo nível - Dicas e truques para a certificação PHP (PT-BR)
TDC 2016 (Florianópolis) - Vá para o próximo nível - Dicas e truques para a certificação PHP (PT-BR)
TDC 2016 (Florianópolis) - Vá para o próximo nível - Dicas e truques para a certificação PHP (PT-BR)
TDC 2016 (Florianópolis) - Vá para o próximo nível - Dicas e truques para a certificação PHP (PT-BR)
Próximos SlideShares
Carregando em…5
×

TDC 2016 (Florianópolis) - Vá para o próximo nível - Dicas e truques para a certificação PHP (PT-BR)

601 visualizações

Publicada em

In this talk I tried to make the Zend Certification easy for those who doesn't have passed the exam yet. This talk was presented in the TDC 2016 in Florianópolis, Brasil

Publicada em: Internet
  • DOWNLOAD THE BOOK INTO AVAILABLE FORMAT (New Update) ......................................................................................................................... ......................................................................................................................... Download Full PDF EBOOK here { https://soo.gd/irt2 } ......................................................................................................................... Download Full EPUB Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download Full doc Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download PDF EBOOK here { https://soo.gd/irt2 } ......................................................................................................................... Download EPUB Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download doc Ebook here { https://soo.gd/irt2 } ......................................................................................................................... ......................................................................................................................... ................................................................................................................................... eBook is an electronic version of a traditional print book THE can be read by using a personal computer or by using an eBook reader. (An eBook reader can be a software application for use on a computer such as Microsoft's free Reader application, or a book-sized computer THE is used solely as a reading device such as Nuvomedia's Rocket eBook.) Users can purchase an eBook on diskette or CD, but the most popular method of getting an eBook is to purchase a downloadable file of the eBook (or other reading material) from a Web site (such as Barnes and Noble) to be read from the user's computer or reading device. Generally, an eBook can be downloaded in five minutes or less ......................................................................................................................... .............. Browse by Genre Available eBOOK .............................................................................................................................. Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, CookBOOK, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult, Crime, EBOOK, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, ......................................................................................................................... ......................................................................................................................... .....BEST SELLER FOR EBOOK RECOMMEND............................................................. ......................................................................................................................... Blowout: Corrupted Democracy, Rogue State Russia, and the Richest, Most Destructive Industry on Earth,-- The Ride of a Lifetime: Lessons Learned from 15 Years as CEO of the Walt Disney Company,-- Call Sign Chaos: Learning to Lead,-- StrengthsFinder 2.0,-- Stillness Is the Key,-- She Said: Breaking the Sexual Harassment Story THE Helped Ignite a Movement,-- Atomic Habits: An Easy &amp; Proven Way to Build Good Habits &amp; Break Bad Ones,-- Everything Is Figureoutable,-- What It Takes: Lessons in the Pursuit of Excellence,-- Rich Dad Poor Dad: What the Rich Teach Their Kids About Money THE the Poor and Middle Class Do Not!,-- The Total Money Makeover: Classic Edition: A Proven Plan for Financial Fitness,-- Shut Up and Listen!: Hard Business Truths THE Will Help You Succeed, ......................................................................................................................... .........................................................................................................................
       Responder 
    Tem certeza que deseja  Sim  Não
    Insira sua mensagem aqui
  • DOWNLOAD THIS BOOKS INTO AVAILABLE FORMAT (Unlimited) ......................................................................................................................... ......................................................................................................................... Download Full PDF EBOOK here { https://soo.gd/qURD } ......................................................................................................................... Download Full EPUB Ebook here { https://soo.gd/qURD } ......................................................................................................................... Download Full doc Ebook here { https://soo.gd/qURD } ......................................................................................................................... Download PDF EBOOK here { https://soo.gd/qURD } ......................................................................................................................... Download EPUB Ebook here { https://soo.gd/qURD } ......................................................................................................................... Download doc Ebook here { https://soo.gd/qURD } ......................................................................................................................... ......................................................................................................................... ................................................................................................................................... eBook is an electronic version of a traditional print book THIS can be read by using a personal computer or by using an eBook reader. (An eBook reader can be a software application for use on a computer such as Microsoft's free Reader application, or a book-sized computer THIS is used solely as a reading device such as Nuvomedia's Rocket eBook.) Users can purchase an eBook on diskette or CD, but the most popular method of getting an eBook is to purchase a downloadable file of the eBook (or other reading material) from a Web site (such as Barnes and Noble) to be read from the user's computer or reading device. Generally, an eBook can be downloaded in five minutes or less ......................................................................................................................... .............. Browse by Genre Available eBooks .............................................................................................................................. Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, Cookbooks, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult, Crime, Ebooks, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, ......................................................................................................................... ......................................................................................................................... .....BEST SELLER FOR EBOOK RECOMMEND............................................................. ......................................................................................................................... Blowout: Corrupted Democracy, Rogue State Russia, and the Richest, Most Destructive Industry on Earth,-- The Ride of a Lifetime: Lessons Learned from 15 Years as CEO of the Walt Disney Company,-- Call Sign Chaos: Learning to Lead,-- StrengthsFinder 2.0,-- Stillness Is the Key,-- She Said: Breaking the Sexual Harassment Story THIS Helped Ignite a Movement,-- Atomic Habits: An Easy &amp; Proven Way to Build Good Habits &amp; Break Bad Ones,-- Everything Is Figureoutable,-- What It Takes: Lessons in the Pursuit of Excellence,-- Rich Dad Poor Dad: What the Rich Teach Their Kids About Money THIS the Poor and Middle Class Do Not!,-- The Total Money Makeover: Classic Edition: A Proven Plan for Financial Fitness,-- Shut Up and Listen!: Hard Business Truths THIS Will Help You Succeed, ......................................................................................................................... .........................................................................................................................
       Responder 
    Tem certeza que deseja  Sim  Não
    Insira sua mensagem aqui
  • DOWNLOAD THIS BOOKS INTO AVAILABLE FORMAT (2019 Update) ......................................................................................................................... ......................................................................................................................... Download Full PDF EBOOK here { https://soo.gd/irt2 } ......................................................................................................................... Download Full EPUB Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download Full doc Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download PDF EBOOK here { https://soo.gd/irt2 } ......................................................................................................................... Download EPUB Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download doc Ebook here { https://soo.gd/irt2 } ......................................................................................................................... ......................................................................................................................... ................................................................................................................................... eBook is an electronic version of a traditional print book THIS can be read by using a personal computer or by using an eBook reader. (An eBook reader can be a software application for use on a computer such as Microsoft's free Reader application, or a book-sized computer THIS is used solely as a reading device such as Nuvomedia's Rocket eBook.) Users can purchase an eBook on diskette or CD, but the most popular method of getting an eBook is to purchase a downloadable file of the eBook (or other reading material) from a Web site (such as Barnes and Noble) to be read from the user's computer or reading device. Generally, an eBook can be downloaded in five minutes or less ......................................................................................................................... .............. Browse by Genre Available eBooks .............................................................................................................................. Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, Cookbooks, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult, Crime, Ebooks, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, ......................................................................................................................... ......................................................................................................................... .....BEST SELLER FOR EBOOK RECOMMEND............................................................. ......................................................................................................................... Blowout: Corrupted Democracy, Rogue State Russia, and the Richest, Most Destructive Industry on Earth,-- The Ride of a Lifetime: Lessons Learned from 15 Years as CEO of the Walt Disney Company,-- Call Sign Chaos: Learning to Lead,-- StrengthsFinder 2.0,-- Stillness Is the Key,-- She Said: Breaking the Sexual Harassment Story THIS Helped Ignite a Movement,-- Atomic Habits: An Easy &amp; Proven Way to Build Good Habits &amp; Break Bad Ones,-- Everything Is Figureoutable,-- What It Takes: Lessons in the Pursuit of Excellence,-- Rich Dad Poor Dad: What the Rich Teach Their Kids About Money THIS the Poor and Middle Class Do Not!,-- The Total Money Makeover: Classic Edition: A Proven Plan for Financial Fitness,-- Shut Up and Listen!: Hard Business Truths THIS Will Help You Succeed, ......................................................................................................................... .........................................................................................................................
       Responder 
    Tem certeza que deseja  Sim  Não
    Insira sua mensagem aqui
  • DOWNLOAD THIS BOOKS INTO AVAILABLE FORMAT (Unlimited) ......................................................................................................................... ......................................................................................................................... Download Full PDF EBOOK here { https://soo.gd/qURD } ......................................................................................................................... Download Full EPUB Ebook here { https://soo.gd/qURD } ......................................................................................................................... Download Full doc Ebook here { https://soo.gd/qURD } ......................................................................................................................... Download PDF EBOOK here { https://soo.gd/qURD } ......................................................................................................................... Download EPUB Ebook here { https://soo.gd/qURD } ......................................................................................................................... Download doc Ebook here { https://soo.gd/qURD } ......................................................................................................................... ......................................................................................................................... ................................................................................................................................... eBook is an electronic version of a traditional print book THIS can be read by using a personal computer or by using an eBook reader. (An eBook reader can be a software application for use on a computer such as Microsoft's free Reader application, or a book-sized computer THIS is used solely as a reading device such as Nuvomedia's Rocket eBook.) Users can purchase an eBook on diskette or CD, but the most popular method of getting an eBook is to purchase a downloadable file of the eBook (or other reading material) from a Web site (such as Barnes and Noble) to be read from the user's computer or reading device. Generally, an eBook can be downloaded in five minutes or less ......................................................................................................................... .............. Browse by Genre Available eBooks .............................................................................................................................. Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, Cookbooks, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult, Crime, Ebooks, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, ......................................................................................................................... ......................................................................................................................... .....BEST SELLER FOR EBOOK RECOMMEND............................................................. ......................................................................................................................... Blowout: Corrupted Democracy, Rogue State Russia, and the Richest, Most Destructive Industry on Earth,-- The Ride of a Lifetime: Lessons Learned from 15 Years as CEO of the Walt Disney Company,-- Call Sign Chaos: Learning to Lead,-- StrengthsFinder 2.0,-- Stillness Is the Key,-- She Said: Breaking the Sexual Harassment Story THIS Helped Ignite a Movement,-- Atomic Habits: An Easy &amp; Proven Way to Build Good Habits &amp; Break Bad Ones,-- Everything Is Figureoutable,-- What It Takes: Lessons in the Pursuit of Excellence,-- Rich Dad Poor Dad: What the Rich Teach Their Kids About Money THIS the Poor and Middle Class Do Not!,-- The Total Money Makeover: Classic Edition: A Proven Plan for Financial Fitness,-- Shut Up and Listen!: Hard Business Truths THIS Will Help You Succeed, ......................................................................................................................... .........................................................................................................................
       Responder 
    Tem certeza que deseja  Sim  Não
    Insira sua mensagem aqui
  • DOWNLOAD THIS BOOKS INTO AVAILABLE FORMAT (2019 Update) ......................................................................................................................... ......................................................................................................................... Download Full PDF EBOOK here { https://soo.gd/irt2 } ......................................................................................................................... Download Full EPUB Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download Full doc Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download PDF EBOOK here { https://soo.gd/irt2 } ......................................................................................................................... Download EPUB Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download doc Ebook here { https://soo.gd/irt2 } ......................................................................................................................... ......................................................................................................................... ................................................................................................................................... eBook is an electronic version of a traditional print book THIS can be read by using a personal computer or by using an eBook reader. (An eBook reader can be a software application for use on a computer such as Microsoft's free Reader application, or a book-sized computer THIS is used solely as a reading device such as Nuvomedia's Rocket eBook.) Users can purchase an eBook on diskette or CD, but the most popular method of getting an eBook is to purchase a downloadable file of the eBook (or other reading material) from a Web site (such as Barnes and Noble) to be read from the user's computer or reading device. Generally, an eBook can be downloaded in five minutes or less ......................................................................................................................... .............. Browse by Genre Available eBooks .............................................................................................................................. Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, Cookbooks, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult, Crime, Ebooks, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, ......................................................................................................................... ......................................................................................................................... .....BEST SELLER FOR EBOOK RECOMMEND............................................................. ......................................................................................................................... Blowout: Corrupted Democracy, Rogue State Russia, and the Richest, Most Destructive Industry on Earth,-- The Ride of a Lifetime: Lessons Learned from 15 Years as CEO of the Walt Disney Company,-- Call Sign Chaos: Learning to Lead,-- StrengthsFinder 2.0,-- Stillness Is the Key,-- She Said: Breaking the Sexual Harassment Story THIS Helped Ignite a Movement,-- Atomic Habits: An Easy &amp; Proven Way to Build Good Habits &amp; Break Bad Ones,-- Everything Is Figureoutable,-- What It Takes: Lessons in the Pursuit of Excellence,-- Rich Dad Poor Dad: What the Rich Teach Their Kids About Money THIS the Poor and Middle Class Do Not!,-- The Total Money Makeover: Classic Edition: A Proven Plan for Financial Fitness,-- Shut Up and Listen!: Hard Business Truths THIS Will Help You Succeed, ......................................................................................................................... .........................................................................................................................
       Responder 
    Tem certeza que deseja  Sim  Não
    Insira sua mensagem aqui
  • Seja a primeira pessoa a gostar disto

TDC 2016 (Florianópolis) - Vá para o próximo nível - Dicas e truques para a certificação PHP (PT-BR)

  1. 1. Globalcode – Open4education Trilha – PHP Vá para o próximo nível - Dicas e truques para a certificação PHP
  2. 2. marabesi @MatheusMarabesi
  3. 3. ZENDSC10X 10/jun
  4. 4. HELP WANTED !
  5. 5. http://phingbrasil.com.br
  6. 6. Who doesn’t want to be certified ?
  7. 7. ????????
  8. 8. $coração = 'Hello'; echo $coração;
  9. 9. class Cächaça { } $cachaça = new Cächaça();
  10. 10. BITWISE
  11. 11. a bitwise operation operates on one or more bit patterns or binary numerals at the level of their individual bits. It is a fast, primitive action directly supported by the processor, and is used to manipulate values for comparisons and calculations
  12. 12. & AND | OR ^ XOR >> RIGHT << LEFT
  13. 13. Bits that are set in both $a AND $b are set. http://php.net/manual/en/language.operators.bitwise.php
  14. 14. & - AND 0 & 0 = 0 0 & 1 = 0 1 & 0 = 0 1 & 1 = 1 print (4 & 8);
  15. 15. Bits that are set in either $a OR $b are set. http://php.net/manual/en/language.operators.bitwise.php
  16. 16. | - OR 0 | 0 = 0 0 | 1 = 1 1 | 0 = 1 1 | 1 = 1 print (2 | 7);
  17. 17. Bits that are set in $a OR $b but not BOTH are set. http://php.net/manual/en/language.operators.bitwise.php
  18. 18. | - XOR 0 ^ 0 = 0 0 ^ 1 = 1 1 ^ 0 = 1 1 ^ 1 = 0 print (3 ^ 9);
  19. 19. 128 64 32 16 8 4 2 1 1 1 1 1 1 1 1 1 255
  20. 20. 128 64 32 16 8 4 2 1 0 0 0 0 0 1 0 0 4 0 0 0 0 1 0 0 0 8 print (4 & 8); & - AND
  21. 21. 128 64 32 16 8 4 2 1 0 0 0 0 0 0 1 0 2 0 0 0 0 0 1 1 1 7 print (2 | 7); | - OR
  22. 22. 128 64 32 16 8 4 2 1 0 0 0 0 0 0 1 1 3 0 0 0 0 1 0 0 1 9 print (3 ^ 9); ^ - XOR
  23. 23. & AND | OR ^ XOR >> RIGHT << LEFT
  24. 24. Shift the bits of $a $b steps to the right (each step means "divide by two") http://php.net/manual/en/language.operators.bitwise.php
  25. 25. bit leftmost / 2 ^ bit rightmost >> - Shift right print (4 >> 6); 4 / 2 ^ 6 = 0
  26. 26. Shift the bits of $a $b steps to the left (each step means "multiply by two") http://php.net/manual/en/language.operators.bitwise.php
  27. 27. bit leftmost * 2 ^ bit rightmost << - Shift left print (7 << 9); 7 * 2 ^ 9 = 3584
  28. 28. & AND | OR ^ XOR >> RIGHT << LEFT
  29. 29. Bits that are set in $a are not set, and vice versa. http://php.net/manual/en/language.operators.bitwise.php
  30. 30. ~ - Not ~x = -x -1 print (~9); ~9 = -9 -1 = -10
  31. 31. exit(253); php execute.php
  32. 32. http://www.phpinternalsbook.com/
  33. 33. STREAMS
  34. 34. $context = stream_context_create([ 'http' => [ 'method' => 'GET' ] ]); print file_get_contents( 'http://api.phpconference.com.br', false, $context );
  35. 35. $context = stream_context_create([ 'http' => [ 'method' => 'POST', 'header' => 'Content-Type: application/x-www-form-urlencoded', 'content' => 'field=value' ] ]); print file_get_contents( 'http://api.tdc2016floripa.com.br', false, $context );
  36. 36. O.O.PObject . Oriented . Programming
  37. 37. LATE STATIC BINDING X SELF
  38. 38. class A { public static function who() { echo __CLASS__; } public static function test() { self::who(); } } class B extends A { public static function who() { echo __CLASS__; } } B::test();
  39. 39. class A { public static function who() { echo __CLASS__; } public static function test() { static::who(); } } class B extends A { public static function who() { echo __CLASS__; } } B::test();
  40. 40. OBJECT CLONING
  41. 41. class A { public $name; } $a = new A(); $b = clone $a; var_dump($a == $b);
  42. 42. class A { public $name; } $a = new A(); $a->name = 'Ana'; $b = clone $a; $b->name = 'Clark'; var_dump($a == $b);
  43. 43. class B { public $lastName; } class A { public $name; public $lastName; public function __construct() { $this->lastName = new B(); } } $a = new A(); $a->lastName->lastName = 'River'; $b = clone $a; $b->lastName->lastName = 'Dom'; var_dump($a == $b);
  44. 44. ARRAY
  45. 45. sort(); rsort(); asort(); ksort(); krsort(); usort();
  46. 46. A K U R ASSOCIATIVE KEY USER REVERSE
  47. 47. sort(); rsort(); asort(); ksort(); krsort(); usort();
  48. 48. array_diff_ukey array_diff_uassoc array_​intersect_​assoc array_​intersect_​uassoc array_​intersect_​ukey
  49. 49. DON’T FORGET !
  50. 50. marabesi @MatheusMarabesi

×