Installation Problem in SonataMediaBundle

1,912 views
Skip to first unread message

Md Mostafizur Rahman milon

unread,
Feb 14, 2012, 5:03:57 AM2/14/12
to sonata-users
Hello Users


i ma try to install SonataMediaBundle in my symfony 2 project but it's
show error

InvalidConfigurationException: The child node "default_context" at
path "sonata_media" must be configured.


i try to use only SonataMediaBundle not SonataAdminBundle.

my config.yml file look likes:


# Doctrine Configuration
doctrine:
dbal:
driver: %database_driver%
host: %database_host%
port: %database_port%
dbname: %database_name%
user: %database_user%
password: %database_password%
charset: UTF8

orm:
# auto_mapping: true
# # the standard distribution overrides this to be true in
debug, false otherwise
# auto_generate_proxy_classes: false
# proxy_namespace: Proxies
# proxy_dir: %kernel.cache_dir%/doctrine/orm/Proxies
# default_entity_manager: default
# metadata_cache_driver: array
# query_cache_driver: array
# result_cache_driver: array
entity_managers:
default:
mappings:
SonataMediaBundle: ~




#admingenerator_user:
# login_template:
AdmingeneratorGeneratorBundle::base_login_assetic_less.html.twig



sonata_media:
db_driver: doctrine_orm # or doctrine_mongodb
contexts:
default: # the default context is mandatory
providers:
- sonata.media.provider.dailymotion
- sonata.media.provider.youtube
- sonata.media.provider.image
- sonata.media.provider.file

formats:
small: { width: 100 , quality: 70}
big: { width: 500 , quality: 70}

cdn:
server:
path: /uploads/media # http://media.sonata-project.org/

filesystem:
local:
directory: %kernel.root_dir%/../web/uploads/media
create: false


providers:
image:
resizer: sonata.media.resizer.square


Anyone can help me ?

sadoknet

unread,
Feb 15, 2012, 4:33:52 AM2/15/12
to sonata-users
Hi
I have to same problem :( you find how fix it ?

thanks

On Feb 14, 11:03 am, Md Mostafizur Rahman milon <cse...@gmail.com>
wrote:
>             path: /uploads/media #http://media.sonata-project.org/

Thomas Rabaix

unread,
Feb 15, 2012, 4:37:04 AM2/15/12
to sonata...@googlegroups.com
Have a look to http://sonata-project.org/bundles/media/master/doc/reference/advanced_configuration.html

The installation page seems to be outdated ...

--
You received this message because you are subscribed to the Google Groups "sonata-users" group.
To post to this group, send email to sonata...@googlegroups.com.
To unsubscribe from this group, send email to sonata-users...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/sonata-users?hl=en.




--
Thomas Rabaix
http://rabaix.net | http://sonata-project.org

sadoknet

unread,
Feb 15, 2012, 4:58:02 AM2/15/12
to sonata-users
It's work by adding this line before the `contexts` child node:
default_context: default

the config.yml now is :
# Sonata Media Bundle
sonata_media:
db_driver: doctrine_orm
default_context: default
contexts:
default: # the default context is mandatory
providers:
- sonata.media.provider.dailymotion
- sonata.media.provider.youtube
- sonata.media.provider.image
- sonata.media.provider.file
...

Thanks Thomas ;)

On Feb 15, 10:37 am, Thomas Rabaix <tho...@rabaix.net> wrote:
> Have a look tohttp://sonata-project.org/bundles/media/master/doc/reference/advanced...

Dan Dvoracek

unread,
Aug 28, 2013, 8:38:34 AM8/28/13
to sonata...@googlegroups.com
Still not working for me. Any other idea?

Sebastian Krebs

unread,
Aug 28, 2013, 10:32:28 AM8/28/13
to sonata...@googlegroups.com



2013/8/28 Dan Dvoracek <dndvo...@gmail.com>

Still not working for me. Any other idea?

On Tuesday, 14 February 2012 10:03:57 UTC, Md Mostafizur Rahman milon wrote:
Hello Users


i ma try to install SonataMediaBundle in my symfony 2 project but it's
show error

InvalidConfigurationException: The child node "default_context" at
path "sonata_media" must be configured.

That usually means, that you shoudl something like

sonata_media:
    default_context: .....


 

--
You received this message because you are subscribed to the Google Groups "sonata-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sonata-users...@googlegroups.com.

To post to this group, send email to sonata...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages