This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1. Comme pour les étapes précédentes, teste toutes les expressions régulières du challenge sur le site http://regexr.com/, | |
sur le même texte d'exemple, disponible pour rappel sur le Gist suivant : | |
Matrix (31/03/1999) - 130 minutes | |
IMDB note 9/10 (https://www.imdb.com/title/tt0133093) | |
Thomas A. Anderson (Keanu Reeves), un jeune informaticien connu dans le monde du hacking sous le pseudonyme de Neo, | |
est contacté via son ordinateur par ce qu’il pense être un groupe de hackers. | |
Ils lui font découvrir que le monde dans lequel il vit n’est qu’un monde virtuel, la matrice, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
if(!empty($_FILES)) { | |
for( $i = 0 ; $i < count($_FILES['fichier']['name']) ; $i++){ | |
// vérification de la capacité et de l'extension des fichiers | |
if ($_FILES['fichier']['size'][$i] < 1000000 && ($_FILES['fichier']['type'][$i] == "image/jpg" || $_FILES['fichier']['type'][$i] == "image/jpeg" || $_FILES['fichier']['type'][$i] == "image/png" || $_FILES['fichier']['type'][$i] == "image/gif")) { | |
// chemin vers un dossier sur le serveur qui va recevoir les fichiers uploadés | |
$uploadDir = 'upload/'; | |
// on récupère l'extension, par exemple "jpg" | |
$extension = pathinfo($_FILES['fichier']['name'][$i], PATHINFO_EXTENSION); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class TimeTravel | |
{ | |
private $start; | |
private $end; | |
public function __construct(DateTime $start, DateTime $end) | |
{ | |
$this->setStart($start); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="fr"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Hello Wilder</title> | |
</head> | |
<body> | |
<script src="solution-quete.js"></script> | |
</body> | |
</html> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Bicycle.php | |
require_once 'Vehicle.php'; | |
require_once 'LightableInterface.php'; | |
class Bicycle extends Vehicle implements LightableInterface | |
{ | |
public function switchOn(): bool |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mysql> SELECT name, COUNT(player.id) AS nb_joueur | |
-> FROM team | |
-> JOIN player ON team.id = player.team_id | |
-> GROUP BY name | |
-> ORDER BY nb_joueur DESC; | |
+------------+-----------+ | |
| name | nb_joueur | | |
+------------+-----------+ | |
| Gryffindor | 36 | | |
| Slytherin | 21 | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name='viewport' content='width=device-width, initial-scale=1.0, maximum-scale=1.0' /> | |
<title>Find the precious!</title> | |
<link rel="stylesheet" href="style.css"> | |
</head> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mysql> SELECT w.lastname, w.firstname, p.role, t.name team | |
-> FROM player p | |
-> JOIN wizard w ON p.wizard_id = w.id | |
-> JOIN team t ON p.team_id = t.id | |
-> ORDER BY t.name, p.role, w.lastname, w.firstname ASC; | |
+-----------------+-------------+--------+------------+ | |
| lastname | firstname | role | team | | |
+-----------------+-------------+--------+------------+ | |
| Black | Sirius | beater | Gryffindor | | |
| Brown | Lavender | beater | Gryffindor | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Bicycle.php | |
require_once 'Vehicle.php'; | |
class Bicycle extends Vehicle | |
{ | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" | |
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0"> | |
<meta http-equiv="X-UA-Compatible" content="ie=edge"> | |
<title>Grand Oeil Sauron</title> |
NewerOlder