'surround' template localization

11 views
Skip to first unread message

Soteric

unread,
Mar 23, 2013, 5:35:54 AM3/23/13
to lif...@googlegroups.com
Hello,

I'm trying to add localization support to my site. I have the following file structure

/templates-hidden/default.html
_resources_index.html
index.html

where index.html is

<div class="lift:surround?with=default;at=content">
    <p><span class="lift:Loc.message">Localized content message must be here</span></p>
</div>

and default.html is

    <head>
        <meta http-equiv="content-type" content="text/html; charset=UTF-8"/>
    </head>
    <body>
        <p><span class="lift:Loc.header">Localized header</span></p>
        <div id="content"></div>
    </body>
</html>

The text in index.html is successfully localized. I can see messages specified in _resources_index.html. But default.html is a problem. If I add 'header' entry to _resources_index.html or _resources.html I can see it. But if I add to /templates-hidden/_resources_default.html 'header' is not localized. Where should I put _resources_default.html file to make it work?

Thanks!

Matt Farmer

unread,
Mar 23, 2013, 2:42:13 PM3/23/13
to lif...@googlegroups.com
Hey Soteric,

So this is a bit odd because the behavior you describe is usually what would happen if you had...

lift:content_id="content"

..specified somewhere, but I don't see it in your example anywhere. Is there any chance at all you accidentally left out a line containing that code somewhere?

Константин

unread,
Mar 23, 2013, 3:29:05 PM3/23/13
to lif...@googlegroups.com
Sorry Matt, I’m not sure I understand what this line for. Could you clarify?
--
--
Lift, the simply functional web framework: http://liftweb.net
Code: http://github.com/lift
Discussion: http://groups.google.com/group/liftweb
Stuck? Help us help you: https://www.assembla.com/wiki/show/liftweb/Posting_example_code
 
---
You received this message because you are subscribed to a topic in the Google Groups "Lift" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/liftweb/ib9oqQ1XsFc/unsubscribe?hl=en-US.
To unsubscribe from this group and all its topics, send an email to liftweb+u...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 
Reply all
Reply to author
Forward
0 new messages