PHP 8.6.0RC7 available for testing

Garbage Collection

Table of Contents

This section explains the merits of the new Garbage Collection (also known as GC) mechanism that is part of PHP 5.3.

+add a note

User Contributed Notes 1 note

up
0
toto at tata dot com
10 days ago
Which line of code will generate an HTML list of numbers from 1 to 10? (One correct answer)

for($i = 1; $i <= 10; $i++) { echo '<li>' . $i . '</li>'; }

/////////////////////////////////////////////////////////

What is the correct way to check if a URL parameter named 'id' is set? (One correct answer)

if(isset($_GET['id'])) { ... }

/////////////////////////////////////////////////////////

How to send a form field named 'email' to a PHP script using the POST method? (One correct answer)

<form method='post'><input type='text' name='email'></form>

/////////////////////////////////////////////////////////

What is the purpose of the `execute` method in a PDO statement?

To execute a SQL query

/////////////////////////////////////////////////////////

How do you change the color of an element with the id 'demo' in JavaScript? (One correct answer)

document.getElementById('demo').style.color = 'red'

/////////////////////////////////////////////////////////

How do you set an event listener to run a function named 'myFunction' when the cursor enters an element with the id 'myElement'? (One correct answer)

document.getElementById('myElement').addEventListener('mouseenter', myFunction)

/////////////////////////////////////////////////////////

What is the purpose of the `.then` method in JavaScript?

To handle the result of an asynchronous operation

/////////////////////////////////////////////////////////
To Top