Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /* _____ _____ _ _____ _____ _____ _____ _____ _____
- ___| | __ |_| _ |_ _|___ ___|_ _| __| _ | |
- |_ -| --| -| | __| | | |- _|___| | | | __| | | | |
- |___|_____|__|__|_|__| |_| |___| |_| |_____|__|__|_|_|_|
- |s C R i P T z - T E A M . i N F O|----------------------------
- [PHP] ENVATO MARKETPLACES APi iTEM DOWNLOADER
- */
- if (isset($_GET['username']) && $_GET['username'] != "") {
- $url = "http://marketplace.envato.com/api/v3/" . $_GET['username'] . '/' . $_GET['api-key'] . '/download-purchase:' . $_GET['licence_code'] . '.json';
- $url = htmlspecialchars($url);
- $ch = curl_init($url);
- curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
- curl_setopt($ch, CURLOPT_HEADER, false);
- $data = curl_exec($ch);
- $json = json_decode($data, true);
- if (isset($json['download-purchase'])) {
- if (isset($json['download-purchase']['download_url'])) {
- $url = $json['download-purchase']['download_url'];
- ?>
- [Downloading]
- <script>window.location.href="<?php
- echo $url;
- ?>";</script>
- <?php
- exit;
- }
- }
- echo "Failed. API or Licence code incorrect";
- }
- ?>
- <form action="" method="GET">
- USERNAME: <input type="text" name="username"> <br /><br />
- API-KEY: <input type="text" name="api-key"> <br /><br />
- LiCENCE CODE: <input type="text" name="licence_code"> <br /><br />
- <input type="submit" value="DOWNLOAD">
- </form>
Add Comment
Please, Sign In to add comment