PHP code example of hypejunction / proxy

1. Go to this page and download the library: Download hypejunction/proxy library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

hypejunction / proxy example snippets



// Get a link to download a file
// By default, link's validity is limited to 2 hours and restricted to current user session

$file = get_entity($file_guid);
$download_link = elgg_get_download_url($file);


// Get a link to display an icon
// By default, link's validity is limited to 1 year and can be reused outside of the current user session

$icon = new ElggFile();
$icon->owner_guid = $owner_guid;
$icon->setFilename("path/to/icon.jpg");

$icon_link = elgg_get_inline_url($icon);