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

  • SEARCH
  • Home
  • 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 8496319
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T23:49:11+00:00 2026-06-10T23:49:11+00:00

I have custom template – to translate autogenerated views. There is for example a

  • 0

I have custom template – to translate autogenerated views. There is for example a line:

echo "<?php echo \$this->Html->link(__('Lista " . $pluralHumanName . "'), array('action' => 'index')); ?>";

My models have english names (as cake’s convention wants) but I want to use translated model names in auto created views. For example in Title Model I was trying to declare:

$pluralHumanName = 'Stanowiska';

but generated view files always have english name… and I have to translate each file manually. Is there a way to translate/change $singularHumanName and $pluralHumanName ?

  • 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-10T23:49:12+00:00Added an answer on June 10, 2026 at 11:49 pm

    why are you double-translating then?

     __('Lista " . $pluralHumanName . "')
    

    the __() already translates. So you try to translate your translated string a second time (without having the translated strings in your po then of course).

    You should stick with the english words in your __() and then put your “Lista” and other translated strings in your po file.

    Or just:

    'Lista " . __($pluralHumanName) . "'
    

    without the __() around. The __() for $pluralHumanName, though, translates right away in your template and will become the your desired name (hardcoded). But as I mentioned above, you usually don’t go that way!

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

Sidebar

Related Questions

I have made a custom suface button according this example: <Button> <Button.Template> <ControlTemplate TargetType=Button>
Is there a way to add custom template inside Telerik MVC Combobox.? I have
I'm newbie at TYPO3, trying to install my custom template. I have HTML/CSS/IMAGES files,
I have created a custom editor template for DateTimeOffset: @model DateTimeOffset <div> @Html.LabelFor(m =>
For example, let's say there is a custom template tag {% custom_tag parameter %}
I have a custom control template for a ListView that puts an extra line
I have been using a custom template file called user-profile.tpl.php for a while. But
I currently have my Django custom template filter like this: from django import template
So I have a page called latest news and using a custom template t_latest_news.php
I have custom Rythm template tag (sayHi.html) which I want to call from parent

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.