Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>I wouldn't build the query string myself like that, but use <a href="http://php.net/manual/en/function.http-build-query.php" rel="nofollow"><code>http_build_query()</code></a> in preference:</p> <pre><code>$url = 'http://77.33.xx.xx/s/addtoqueue.php'; $params = array( 'action' =&gt; 'store', 'filename' =&gt; $filename, 'link' =&gt; $link, ); $link = $url . '?' . http_build_query($params); </code></pre> <p>To actually make a call to the URL you can use a number of techniques, but my favourite in this case would be <a href="http://php.net/curl" rel="nofollow">curl</a>. Here is an adapted version of the <a href="http://php.net/manual/en/curl.examples-basic.php" rel="nofollow">example from the manual</a>:</p> <pre><code>&lt;?php $ch = curl_init($link); curl_setopt($ch, CURLOPT_HEADER, 0); curl_exec($ch); curl_close($ch); </code></pre> <p>Other options include <a href="http://php.net/file_get_contents" rel="nofollow"><code>file_get_contents($link);</code></a> if the <a href="http://php.net/manual/en/filesystem.configuration.php#ini.allow-url-fopen" rel="nofollow">fopen wrappers have been enabled</a>.</p> <h2>Additional response for comments</h2> <pre><code>&lt;?php $ch = curl_init($link); curl_setopt($ch, CURLOPT_HEADER, 0); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $response = curl_exec($ch); curl_close($ch); </code></pre> <p><code>$response</code> now contains the response from the URL. From the <a href="http://php.net/manual/en/function.curl-exec.php" rel="nofollow"><code>curl_exec()</code> manual page</a>:</p> <blockquote> <p>Returns TRUE on success or FALSE on failure. However, if the CURLOPT_RETURNTRANSFER option is set, it will return the result on success, FALSE on failure.</p> </blockquote> <p>For more information on the curl options you can use checkout the <a href="http://php.net/manual/en/function.curl-setopt.php" rel="nofollow"><code>curl_setopt()</code> manual page</a>.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload