Skip to content

Commit

Permalink
Fix: Service non-existance in Symfony Flex
Browse files Browse the repository at this point in the history
  • Loading branch information
jorisdugue committed Oct 29, 2020
1 parent 729e046 commit e760175
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 7 deletions.
25 changes: 19 additions & 6 deletions README.MD
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# H5PBundle
Bundle to integrate H5P into Symfony. This bundle is a port of the H5P Drupal module. For more info about H5P see [H5P.org](https://h5p.org)

For Symfony 3.X => [H5PBundle for Symfony 2.X and 3.X](https://github.com/studit/h5p-bundle/tree/193db01f03584a131b011e7ab8ed9973b1496b6d)
For Symfony 3.X => [H5PBundle for Symfony 2.X and 3.X](https://github.com/Emmedy/h5p-bundle)

This bundle was tested on Symfony 4.0 and Symfony 5.0
This bundle was tested on Symfony 4.X and Symfony 5.X

Installation
------------
Expand All @@ -14,7 +14,7 @@ composer require jorisdugue/h5p-bundle
```

Enable the bundle in `AppKernel.php`
``` php
```php
return [
// ...
\Studit\H5PBundle\StuditH5PBundle::class => ['all' => true]
Expand Down Expand Up @@ -43,7 +43,7 @@ php bin/console make:migrations
````

Enable the routing in `routes.yaml`
``` yaml
```yaml
studit_h5p.demo:
resource: "@StuditH5PBundle/Resources/config/routing_demo.yml"
prefix: /
Expand All @@ -58,16 +58,29 @@ studit_h5p.demo is optional. It can be used as an example how to use H5P within
Configuration
-------------

For SF4:
Configure the bundle in `services.yaml`. (Watch for the underscore between h5 and p)
``` yml
```yaml
parameters:
studit_h5_p:
use_permission: true # This is false by default to let the demo work out of the box.
storage_dir: h5p # Location to store all H5P libraries and files
storage_dir: / # Location to store all H5P libraries and files
web_dir: public # Location of the public web directory
export: 3 #for all
embed: 3 #for all
```

For Symfony 5:
Configure the bundle in `packages > h5pBundle.yml`.
```yaml
studit_h5_p:
use_permission: true # This is false by default to let the demo work out of the box.
storage_dir: / # Location to store all H5P libraries and files
web_dir: public # Location of the public web directory
export: 3 #for all
embed: 3 #for all
```

For all configurations see [Configuration.php](DependencyInjection/Configuration.php)

if you are using permissions here is the current list of permissions in the bundle :
Expand Down
3 changes: 2 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@
"symfony/serializer": "~4.0|~5.0",
"twig/extra-bundle": "^3.0",
"doctrine/doctrine-bundle": "^2.0",
"symfony/security-bundle": "~4.0|~5.0"
"symfony/security-bundle": "~4.0|~5.0",
"symfony/asset": "~4.0|~5.0"
},
"autoload": {
"psr-4": { "Studit\\H5PBundle\\": "" }
Expand Down

0 comments on commit e760175

Please sign in to comment.