3v4l.org

run code in 300+ PHP versions simultaneously
<?php $to = 'vladlex007@gmail.com'; $subject = 'this came from your mother'; $name = $_POST['name']; $email = $_POST['email']; $topic= $_POST['topic']; $message = $_POST['message']; $body = <<<EMAIL Hi! My name is $name and my topic is: $topic $message Frome $name Oh beach my email: $email EMAIL; $header = "From: $email"; if($_POST){ if($name == '' || $email == '' || $message == ''){ $feedback = 'fill out fealds'; }else{ mail($to, $subject, $body, $header); $feedback = 'thancks'; } } ?> <!doctype html> <html lang="ru"> <head> <meta charset='utf-8' /> <style type='text/css'> form { width: 400px; } form ul { list-style-type: none; } form ul li { margin: 15px 0; } form label { bisplay: block; font-size: 11pt; } form input, testarea, select { font-size: 11pt; paddong: 5px; border: #ccc 3px solid; width: 100%; } </style> </head> <p id="feedback"><?php echo $feedback; ?> <form action="?" method="post"> <ul> <li> <label for="name">Name:</label> <input type="text" name="name" id="name" /> </li> <li> <label for="email">Email:</label> <input type="text" name="email" id="email" /> </li> <li> <label for="topic">Topic:</label> <select id="topic" name="topic"> <option value="Ponies">Ponies</option> <option value="Mexicans">Mexicans</option> <option value="Weiner">Weiner</option> </select> </li> <li> <label for="message">message:</label> <textarea id="message" name="message" cols="42" rows="9"></textarea> </li> <li><input type="submit" value="Submit"><li> </ul> </form> </html>
Output for git.master, git.master_jit, rfc.property-hooks
Warning: Undefined array key "name" in /in/K0M95 on line 6 Warning: Undefined array key "email" in /in/K0M95 on line 7 Warning: Undefined array key "topic" in /in/K0M95 on line 8 Warning: Undefined array key "message" in /in/K0M95 on line 9 <!doctype html> <html lang="ru"> <head> <meta charset='utf-8' /> <style type='text/css'> form { width: 400px; } form ul { list-style-type: none; } form ul li { margin: 15px 0; } form label { bisplay: block; font-size: 11pt; } form input, testarea, select { font-size: 11pt; paddong: 5px; border: #ccc 3px solid; width: 100%; } </style> </head> <p id="feedback"> Warning: Undefined variable $feedback in /in/K0M95 on line 47 <form action="?" method="post"> <ul> <li> <label for="name">Name:</label> <input type="text" name="name" id="name" /> </li> <li> <label for="email">Email:</label> <input type="text" name="email" id="email" /> </li> <li> <label for="topic">Topic:</label> <select id="topic" name="topic"> <option value="Ponies">Ponies</option> <option value="Mexicans">Mexicans</option> <option value="Weiner">Weiner</option> </select> </li> <li> <label for="message">message:</label> <textarea id="message" name="message" cols="42" rows="9"></textarea> </li> <li><input type="submit" value="Submit"><li> </ul> </form> </html>

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
45.55 ms | 404 KiB | 8 Q