Just finished the header.
It’s hard working out what needs to go in the php file and what needs to go in the template.
Attached are the header template file and a sample German language file using an online translator if you’re interested.
Next up, the rest of index.php. Thankfully you’re able to do foreach loops in the template J
Clark
Yeah, I was just reading up on that at the moment as it happens.
Finally reached the penultimate chapter of the Smarty book I bought J
Having trouble with umlauts and other special characters in the translation files but I’ve posted a question on a forum which should give a response.
Clark
I think I’ll convert all the existing pages first and then think about splitting the header templates etc.
I’m enjoying this. It’s like learning a new programming language all over again. I even made the noobish mistake of spending half an hour trying to work out why some translated text wasn’t showing. I gave up went to bed, woke up the next morning, opened the file and there was a $ missing…..D’oh. We’ve all been there J
As for the problem with the umlauts etc. I got a quick response. I was saving the xml files in the wrong format – they were being saved as ANSI files rather than UTF-8 files.
It’s a shame you just can’t pass some English into a function and it’ll translate it into any language. One day perhaps.
Take care
Got it working. Just checked the help file of the editor I use J
Managed to get the block thing working fine. Templated all the error messages etc. and it’s looking good.
Onto viewforum.php
The toughest bit is going to be the AJAX and Javascript. I’ll cross that bridge when I come to it.
Clark
From:
myupb-de...@googlegroups.com [mailto:myupb-de...@googlegroups.com] On Behalf Of Jerroyd Moore
Sent: 28 August 2008 20:08
To:
myupb-de...@googlegroups.com
Subject: [myupb-developers:53] Re:
Template Progress
Hi Clark,
Hi Rebles,
Yeah that could be done. Hopefully a large chunk of the code will disappear from ajax.php with the templating which should make it easier to move about.
You’re right about the ajax method. There is however a fetch method for smarty which processes the variables and the template but doesn’t display them.
I haven’t had to use it yet but it might be the solution.