Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8194715
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T04:54:59+00:00 2026-06-07T04:54:59+00:00

In symfony2 I used config yaml below: // config.yml parameters: something: content: price: 2.30

  • 0

In symfony2 I used config yaml below:

// config.yml
parameters:
  something: 
    content: 
      price:  2.30
      mainText: 'Some text here.'
      redText:  'This is a text here plus price: ' %price%

The %price% is wrong and gives me an error but system tells its an array, so how to point to something[‘content’][price]?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T04:55:01+00:00Added an answer on June 7, 2026 at 4:55 am

    Here’s how you can do it

    parameters:
        something.content.price: 2.30
        something:
            content:
                mainText: 'Some text here.'
                redText:  'This is a text here plus price: %something.content.price%'
    

    Here we only have 2 parameters, something.content.price that contains a float, and something that contains an array.

    This means you will only be able to access directly those 2, inside the DI configuration.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

In my Symfony2 config.yml file, I'd like to import some configs that I'd prefer
I want to create a custom ./config/unavailable.php page using the layouts and styling used
So far, the bundles I've used for Symfony2 has been installed modifying the deps
In a multi tenant web application should Symfony2 ACL framework be used for checking
I'm building a small website with Symfony2 (i.e. not Symfony 1.x). I used the
We have a single webinterface in Symfony2 which is used by a number of
What part of Symfony2 needs Swiftmailer? It's not used by the demo-controllers. I am
I'm new in symfony2 , I don't know how to write a below query
Another MVC framework I've used - Symfony2 - uses a dependency injector to carefully
I need to use an yml config file parameter into another yml config file

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.