Как отправить POST-запрос с помощью file_get_contents()?

Вот так:
$postdata = http_build_query(
    array(
        'var1' => 'value1',
        'var2' => 'value2'
    )
);

$opts = array('http' =>
    array(
        'method'  => 'POST',
        'header'  => 'Content-type: application/x-www-form-urlencoded',
        'content' => $postdata
    )
);

$context  = stream_context_create($opts);
$result = file_get_contents('http://www.domain.tld/submit.php', false, $context);