Download the PHP package migliori/visual-diff-merge without Composer

On this page you can find all versions of the php package migliori/visual-diff-merge. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package visual-diff-merge

Visual Diff Merge Tool

Version Packagist Version Packagist Downloads License Commits Contributors Issues

Visual Diff-Merge is a web-based tool for comparing, selecting, and merging code changes. With a split-view interface, it lets you view two versions side by side for easy diffing and merging. Built with PHP and JavaScript, it supports automatic language detection and syntax highlighting for over 180 programming languages, including HTML, Twig, PHP, JavaScript, JSON, TypeScript, Python, Ruby, Java, C#, CSS, XML, YAML, Markdown, SQL, and many more.

🔥 Try it online at visual-diff-merge.miglisoft.com - No installation required!

🚀 Features

🏁 Quick Start

Option 1: Use Online Version

Visit visual-diff-merge.miglisoft.com to use the tool immediately:

Option 2: Install with Composer (recommended)

The fastest way to use Visual Diff Merge in your own PHP project:

This installs the PHP classes (VisualDiffMerge\ namespace, PSR-4) and the ready-to-use frontend assets under vendor/migliori/visual-diff-merge/dist/.

Minimal integration example:

Then load the assets from the vendor directory and initialize the JS component, e.g. in File Browser mode (only api/ and dist/ need to be web-accessible):

Note: since api/config.php lives inside vendor/ and is not editable, use Config::loadArray() (or Config::setConfigPath() pointing to a host-managed file) to supply your settings. Host values passed to Config::loadArray() always win over defaults.

Option 3: Self-hosted from Source

Visual Diff Merge is a client-server application that requires both PHP backend and JavaScript frontend:

  1. Download or clone the repository
  2. Configure your PHP environment (see Installation)
  3. Copy api/config.example.php to api/config.php and adjust settings
  4. Access one of the example files through a web server:
    • diff-viewer/file-browser.php - Browse and compare server files
    • diff-viewer/file-upload.html - Upload local files to compare
    • diff-viewer/text-compare.html - Compare text/code snippets
    • diff-viewer/url-compare.html - Compare content from URLs

📸 Screenshots

File Browser Mode

File Upload Mode

Text Compare Mode

URL Compare Mode

🔧 Installation

Prerequisites

Server Setup

  1. Clone the repository:

  2. Install PHP dependencies:

  3. Configure the project:

    • Copy api/config.example.php to api/config.php
    • Modify configuration options as needed (see Configuration)
  4. Set up your web server to serve the project directory
    • Ensure PHP is properly configured
    • Make sure the api directory is accessible

📋 Usage Modes

Visual Diff Merge offers four distinct usage modes, each requiring specific files and setup:

1. File Browser Mode

2. File Upload Mode

3. Text Compare Mode

4. URL Compare Mode

Each mode uses a specific manager component to handle its unique workflow before initializing the core DiffViewer component.

⚙️ Configuration

Visual Diff Merge uses a PHP configuration file to control both server and client behavior:

Main Configuration File

Key Configuration Options

PHP Settings

JavaScript Settings

For complete configuration options, see the Configuration Documentation.

🏗️ Architecture

Visual Diff Merge follows a client-server architecture:

  1. Backend (PHP):

    • Processes diff calculations via the DiffViewer PHP class
    • Provides API endpoints for file access and diff processing
    • Manages security and file system access
  2. Frontend (JavaScript):
    • Mode-specific manager components handle UI interactions
    • Core DiffViewer component displays and manages diffs
    • Theme system provides syntax highlighting and UI theme options

See the Architecture Documentation for more details.

👨‍💻 Development

Building from Source

If you want to modify the source code:

  1. Install Node.js dependencies:

  2. Development mode with auto-rebuild:

  3. Build for production:

Directory Structure

🤝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

📱 Browser Compatibility

📄 License

This project is licensed under the GNU General Public License v3.0 or later - see the LICENSE file for details.

👏 Acknowledgements


📚 Documentation: visual-diff-merge.miglisoft.com/docs/ 🌐 Website: visual-diff-merge.miglisoft.com 💬 Issues: GitHub Issues


All versions of visual-diff-merge with dependencies

PHP Build Version
Package Version
Requires php Version >=7.2 || ^8.0
sebastian/diff Version ^4.0
matthiasmullie/minify Version ^1.3
ext-json Version *
league/mime-type-detection Version ^1.16
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package migliori/visual-diff-merge contains the following files

Loading the files please wait ...