What best practices should developers follow when seeking help for PHP coding issues on forums?

When seeking help for PHP coding issues on forums, developers should follow these best practices: 1. Clearly explain the issue or ask a specific question in a concise manner. 2. Provide relevant context or background information to help others understand the problem. 3. Include a complete PHP code snippet that demonstrates the issue or implements the fix. Example: I am trying to connect to a MySQL database using PHP but I keep getting a "Connection failed" error. Can someone help me troubleshoot this issue?

<?php
$servername = "localhost";
$username = "username";
$password = "password";
$dbname = "database";

// Create connection
$conn = new mysqli($servername, $username, $password, $dbname);

// Check connection
if ($conn->connect_error) {
    die("Connection failed: " . $conn->connect_error);
}
echo "Connected successfully";
?>