2017 © Pedro Peláez
 

library cors

Provides a reusable framework-agnostic CORS class.

image

phpnexus/cors

Provides a reusable framework-agnostic CORS class.

  • Wednesday, December 7, 2016
  • by markinjapan
  • Repository
  • 1 Watchers
  • 4 Stars
  • 57 Installations
  • PHP
  • 2 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 5 Versions
  • 4 % Grown

The README.md

CORS

Latest Version Software License, (*1)

Provides a lightweight, extensible, framework-agnostic CORS class., (*2)

You probably want to check these specific implementations for easy installation, (*3)

Installation

It's recommended that you use Composer to install Cors:, (*4)

$ composer require phpnexus/cors

This package requires PHP 8.1., (*5)

Usage

TODO, (*6)

Configuration

Allow-Methods

Default: [], (*7)

An array of allowed HTTP methods. These names are case-sensitive., (*8)

Example: ['GET', 'POST'], (*9)

Allow-Headers

Default: [], (*10)

Example: ['Content-Type'], (*11)

Allow-Origins

Default: [], (*12)

An array of allowed origins, in the form scheme://hostname., (*13)

Example: ['http://example.com', 'https://example.com'], (*14)

This is not a replacement for proper access control measures., (*15)

Note: An asterisk (*) can also be used to allow any origin, but as per the specification the asterisk (*) cannot be used when Allow-Credentials is true., (*16)

Allow-Credentials

Default: false, (*17)

Use true to allow cookies to be sent with the request., (*18)

Note: Cannot be true when the Allow-Origin contains "*"., (*19)

Expose-Headers

Default: [], (*20)

Max-Age

Default: 0 (no cache), (*21)

Number of seconds to cache the preflight response., (*22)

Roadmap

  • Benchmarks

Versioning

The packages adheres to the SemVer specification, and there will be full backward compatibility between minor versions., (*23)

Contributing

Please see CONTRIBUTING for details., (*24)

License

This package is released under the Apache 2.0 License. See the bundled LICENSE file for details., (*25)

The Versions

07/12 2016

dev-master

9999999-dev

Provides a reusable framework-agnostic CORS class.

  Sources   Download

Apache-2.0

The Requires

  • php >=5.5.9

 

The Development Requires

by Mark Prosser

cors

07/12 2016

0.2.1

0.2.1.0

Provides a reusable framework-agnostic CORS class.

  Sources   Download

Apache-2.0

The Requires

  • php >=5.5.9

 

The Development Requires

by Mark Prosser

cors

07/12 2016

dev-develop

dev-develop

Provides a reusable framework-agnostic CORS class.

  Sources   Download

Apache-2.0

The Requires

  • php >=5.5.9

 

The Development Requires

by Mark Prosser

cors

12/05 2016

0.2.0

0.2.0.0

Provides a reusable framework-agnostic CORS class.

  Sources   Download

Apache-2.0

The Requires

  • php >=5.5.9

 

The Development Requires

by Mark Prosser

cors

10/05 2016

0.1.0

0.1.0.0

Provides a reusable framework-agnostic CORS class.

  Sources   Download

Apache-2.0

The Requires

  • php >=5.5.9

 

The Development Requires

by Mark Prosser

cors