Title: Localization function inside conditional placeholder
Last modified: August 21, 2016

---

# Localization function inside conditional placeholder

 *  Resolved [raggiorama](https://wordpress.org/support/users/raggiorama/)
 * (@raggiorama)
 * [12 years, 11 months ago](https://wordpress.org/support/topic/localization-function-inside-conditional-placeholder/)
 * Hi!
    I created a custom template for displaying single events. I have some strings
   inside conditional placeholders that I’d like to translate. Specifically I’d 
   like to wrap them inside a `<?php _e(); ?>` function. Here’s an example of the
   code I have:
 *     ```
       <?php echo $EM_Event->output('
       #_EVENTNOTES
       {has_attribute}
       <article id="event-review">
       <h2 class="review-title">Event review</h2>
       <p>#_ATT{Review}</p>
       </article>
       {/has_attribute}
       '); ?>
       ```
   
 * How can I prepare that “Event review” string for localization?
    Thanks in advance
   to anybody who will take time to reply.
 * [http://wordpress.org/extend/plugins/events-manager/](http://wordpress.org/extend/plugins/events-manager/)

Viewing 3 replies - 1 through 3 (of 3 total)

 *  [agelonwl](https://wordpress.org/support/users/angelonwl/)
 * (@angelonwl)
 * [12 years, 11 months ago](https://wordpress.org/support/topic/localization-function-inside-conditional-placeholder/#post-3928976)
 * you can try something like
 *     ```
       <?php 
   
       echo $EM_Event->output('
       #_EVENTNOTES
       {has_attribute}
       <article id="event-review">
       <h2 class="review-title">'._e("Event review").'</h2>
       <p>#_ATT{Review}</p>
       </article>
       {/has_attribute}
       '); 
   
       ?>
       ```
   
 *  Thread Starter [raggiorama](https://wordpress.org/support/users/raggiorama/)
 * (@raggiorama)
 * [12 years, 11 months ago](https://wordpress.org/support/topic/localization-function-inside-conditional-placeholder/#post-3928977)
 * Thank you, agelonwl.
    Unfortunately that solution doesn’t work. I think conditional
   placeholders don’t let you write php code inside them. But there’s should be 
   a solution for those who want to customize their own template.
 *  Plugin Author [Marcus (aka @msykes)](https://wordpress.org/support/users/netweblogic/)
 * (@netweblogic)
 * [12 years, 11 months ago](https://wordpress.org/support/topic/localization-function-inside-conditional-placeholder/#post-3928982)
 * this isn’t possible out the box, however if you google these forums somewhere
   someone did write some snippets that creates custom ph’s for their attribute.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Localization function inside conditional placeholder’ is closed to new
replies.

 * ![](https://ps.w.org/events-manager/assets/icon-256x256.png?rev=3550347)
 * [Events Manager - Calendar, Bookings, Tickets, and more!](https://wordpress.org/plugins/events-manager/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/events-manager/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/events-manager/)
 * [Active Topics](https://wordpress.org/support/plugin/events-manager/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/events-manager/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/events-manager/reviews/)

## Tags

 * [Localization](https://wordpress.org/support/topic-tag/localization/)

 * 3 replies
 * 3 participants
 * Last reply from: [Marcus (aka @msykes)](https://wordpress.org/support/users/netweblogic/)
 * Last activity: [12 years, 11 months ago](https://wordpress.org/support/topic/localization-function-inside-conditional-placeholder/#post-3928982)
 * Status: resolved