2017 © Pedro Peláez
 

symfony-bundle cors-bundle

Handling CORS requests

image

sokil/cors-bundle

Handling CORS requests

  • Friday, August 4, 2017
  • by sokil
  • Repository
  • 1 Watchers
  • 0 Stars
  • 5 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 1 Open issues
  • 4 Versions
  • 0 % Grown

The README.md

CorsBundle

Handling CORS Requests, (*1)

Total Downloads, (*2)

Installation

Add composer dependency:, (*3)

composer.phar require sokil/cors-bundle

Register bundle in your AppKernel:, (*4)

<?php

class AppKernel extends Kernel
{
    public function registerBundles()
    {
        $bundles = array(
            new Sokil\CorsBundle\CorsBundle(),
        );
    }
}

Configuration

Configure bundle in your /app/config/config.yml:, (*5)

cors:
  allowedOrigins: # list of hosts, allowed to do CORS requests to your app. 
    - https://fb.com
    - https://google.com
  withCredentials: true # allow send cookies to your hosts between requests
  maxAge: 86400 # agte of prefligt request cache

Useage

Listener CorsRequestListener is listened to kernel events of requests and add headers if this is CORS request and CORS allowed for that host., (*6)

The Versions

04/08 2017

dev-master

9999999-dev

Handling CORS requests

  Sources   Download

MIT

The Requires

 

The Development Requires

by Dmytro Sokil

04/07 2017

1.0.0

1.0.0.0

Handling CORS requests

  Sources   Download

MIT

The Requires

 

The Development Requires

by Dmytro Sokil

02/07 2017

0.0.4

0.0.4.0

Handling CORS requests

  Sources   Download

MIT

The Requires

 

The Development Requires

by Dmytro Sokil

01/07 2017

0.0.3

0.0.3.0

Handling CORS requests

  Sources   Download

MIT

The Requires

 

The Development Requires

by Dmytro Sokil