Larupload
  • 🏁Getting Started
    • Introduction
    • Installation
    • Laravel Nova integration
    • Support Us
    • License
  • 🚀Basic Usage
    • Database Preparation
    • Model Preparation
    • Upload
  • ⚙️Advanced Usage
    • Concepts
    • Configuration
      • Disk
      • Local Disk
      • Mode
      • SecureIds
      • With Meta
      • Camel Case Response
      • Hide Table Columns
      • Naming Method
      • Lang
      • Image Processing Library
      • Generate Cover
      • Cover Style
      • Dominant Color
      • Dominant Color Quality
      • Keep Old Files
      • Preserve Files
      • Store Original File Name
      • Optimize Image
      • FFMpeg
        • FFMpeg Binaries
        • FFMpeg Threads
        • FFMpeg Capture Frame
        • FFMpeg Queue
        • FFMpeg Max Queue Number
        • FFMpeg Timeout
        • FFMPEG Log Channel
    • Attachment
      • Disk
      • With Meta
      • Naming Method
      • Lang
      • Image Processing Library
      • Generate Cover
      • Cover Style
      • Dominant Color
      • Dominant Color Quality
      • Keep Old Files
      • Preserve Files
      • Store Original File Name
      • SecureIds Method
      • Optimize Image
      • Media Styles
      • Complete Example
    • Migrations
      • Heavy Columns
      • Light Columns
      • Add Original File Name to Existing Tables
  • Upload
  • Delete
  • Cover
    • Upload Cover
    • Update Cover
    • Delete Cover
  • Download
    • Generate Download Link
      • Generate URL for particular style
      • Generate URL for all styles
    • Generate Download Response
  • Meta
  • Get Attachments
  • API Resources
  • Image Optimization
  • SecureIds
  • Queue FFMpeg Processes
    • Job Completion Event
    • FFMpeg Queue Relationships
  • 🧱Standalone Uploader
    • Introduction
    • Upload
    • Delete
    • Cover
      • Update Cover
      • Delete Cover
    • Customization
  • ⚪OTHER
    • Migration
Powered by GitBook
On this page
Edit on GitHub
  1. Standalone Uploader

Customization

Larupload's standalone uploader provides the flexibility to customize the upload process by allowing users to configure various aspects of the uploader.

Some of the customization options available in the standalone uploader are:

  1. Adding custom styles: Users can define their own styles to be used for the uploaded files. They can define multiple styles with different dimensions and formats to suit their needs.

  2. Changing disk: By default, the standalone uploader uses the pre-defined disk from config/larupload.php to store the uploaded files. However, users can choose to use a different disk by specifying the disk name in the configuration.

  3. Changing naming-method: Users can customize the naming method for the uploaded files by defining their own naming convention.

  4. ...

Overall, these customization options make the standalone uploader highly flexible and adaptable to different use cases. Users can easily tailor the uploader to their specific needs, ensuring that their uploaded files are handled exactly as they want.

Basic Example
$file = $request->file('file');
$cover = $request->file('cover');

$upload = Larupload::init('path')
            ->disk('s3')
            ->namingMethod(LaruploadNamingMethod::HASH_FILE)
            ->image('thumbnail', 1000, 750, LaruploadMediaStyle::CROP)
            ->video('thumbnail', 1000, 750, LaruploadMediaStyle::CROP)
            ->audio('wav', new Wav())
            ->stream(
                name: '480p',
                width: 640,
                height: 480,
                format: (new X264)
                    ->setKiloBitrate(3000)
                    ->setAudioKiloBitrate(64)
                )
            )
            ->upload($file, $cover);
PreviousDelete CoverNextMigration

Last updated 4 months ago

🧱