Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/KRI55H/RedditSaver
Reddit post saving library
https://github.com/KRI55H/RedditSaver
2024 reddit reddit-downloader reddit-post reddit-saver reddit-video reddit-video-downloader
Last synced: 4 months ago
JSON representation
Reddit post saving library
- Host: GitHub
- URL: https://github.com/KRI55H/RedditSaver
- Owner: KRI55H
- License: mit
- Created: 2023-11-14T10:40:50.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2023-12-24T09:01:01.000Z (about 1 year ago)
- Last Synced: 2024-10-05T06:04:51.190Z (4 months ago)
- Topics: 2024, reddit, reddit-downloader, reddit-post, reddit-saver, reddit-video, reddit-video-downloader
- Language: PHP
- Homepage:
- Size: 24.4 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
![Packagist Version](https://img.shields.io/packagist/v/kri55h/redditsaver.svg)
![Latest Version](https://img.shields.io/github/v/release/kri55h/redditsaver)
![Packagist Downloads](https://img.shields.io/packagist/dt/kri55h/redditsaver)
![PHP Version](https://img.shields.io/badge/PHP-^8.0-mediumslateblue)
![License](https://img.shields.io/github/license/KRI55H/RedditSaver)### Installation
To install this package, follow these steps:
```bash
composer require kri55h/redditsaver
```
## Usage
Here's an example demonstrating how to use the `RedditSaver` class from this package:
```php
use kri55h\redditsaver\RedditSaver;try {
$reddit = new RedditSaver();
$reddit->setPostURL('');
$videoSaved = $reddit->saveVIDEO();if ($videoSaved) {
// Video saved successfully
return 'Video saved!';
} else {
// Handle if video saving failed
return 'Failed to save video.';
}
} catch (Exception $e) {
// Handle any exceptions or errors that occurred during the process
return 'An error occurred: ' . $e->getMessage();
}
```
Replace `` with the actual URL of the Reddit post you want to save as a video.