-
Posts
326 -
Joined
-
Last visited
Everything posted by Manfred62
-
These are tools for local webdevelopment, including all you need. Easy to handle. Also there are portable versions (no need for installation). http://www.apachefriends.org/en/xampp.html http://www.wampserver.com/en/ http://www.easyphp.org/
-
Experienced the same on a local installation: spell check in TinyMCE doesn't work anymore... Seems like something has changed in the background?
-
<div id="main"><?php echo $page->main; ?> <?php foreach($page->children as $child) : ?> <div class="one_third first column_container"> <div class="portfolio-image-holder"> <div class="portfolio-image"> <a href='<?php echo $child->url; ?>'> <img src='<?php echo $child->images->first()->url; ?>'> </a> </div> </div> <?php $summary = substr($child->text, 0, 100); if(($pos = strrpos($summary, ".")) !== false) { $summary = substr($summary, 0, $pos); } echo "<h1><a href='{$child->url}'>{$child->title}</a></h1>"; echo "{$child->text}"; // displaying text in the field ?> </div> <?php endforeach; ?> </div> not tested
-
retested this. But the title translation from modules doesn't show up in the breadcrumb or heading (without placing this in the default.php)
-
1. found something strange when working with translations (PW 2.3.4): when changing/deleting something in the files, in Language Translator you get the 'abandoned translations' field. Now it's not possible to delete this (checkbox 'delete', then save). Can only delete directly in the language-file. My mistake or a bug? 2. under Access-User-username: the block 'Roles' is not translatable? under Access-Roles-username: the heading of block 'Permissions' is not translatable? had done a search over all files and found these strings in the \wire\core\install.sql
-
concatenate strings for translation
Manfred62 replied to Manfred62's topic in Multi-Language Support
ok, shorter is better.. -
@ryan: is there any timeline for PW 2.4? Because of the bad weather today I have done a lot more updates in translations for PW. But until now not pushed it on GitHub. EDIT: all pull request done. Hopefully no mistakes..
-
concatenate strings for translation
Manfred62 replied to Manfred62's topic in Multi-Language Support
hmm, just another question. What recommended here? Both are doing it. "\n\t\t<label for='selected_image_description'>{$this->_('Description')}</label>" . or this "\n\t\t<label for='selected_image_description'>" . $this->_('Description') . "</label>" . -
concatenate strings for translation
Manfred62 replied to Manfred62's topic in Multi-Language Support
thanks Had to read more in the documentation... -
I'm making some tests with translation in the admin. Tried to concatenate this strings, but it doesn't work? Example: $form->description = __("Translate ", __FILE__) . basename($file, '.module') . __(" to ", __FILE__) . $this->language->title; Only get the first phrase as translatable field. Can anyone explain this?
-
There's no need for a module. Take a look in the example code of the default PW installation. If you only need a simple list: <ul id="menu"> <?php $homepage = $pages->get("/"); $children = $homepage->children; $children->prepend($homepage); foreach($children as $child) { $class = $child === $page->rootParent ? " class='active'" : ''; echo "<li><a$class href='{$child->url}'>{$child->title}</a></li>"; } ?> </ul>
-
thanks a lot for all your explanations... I will fork the complete repo (PW dev) and hopefully contribute something to PW.
-
hmm, no one replied to the question there... so I post it here. Some possible translation updates: /wire/templates-admin/default.php (for complete main menu and heading translations) /* * Dynamic phrases that we want to be automatically translated * * These are in a comment so that they register with the parser, in place of the dynamic __() function calls with page titles. * * __("Pages"); * __("Setup"); * __("Modules"); * __("Access"); * __("Admin"); * __("Languages"); // add * __("Users"); // add * __("Roles"); // add * __("Permissions"); // add * */ /wire/modules/LanguageSupport/ProcessLanguage.module (translatable 'Edit' and 'Translate new File' link) $lastMod = date($this->config->dateFormat, filemtime($pagefile->filename)); $edit = __('Edit', __FILE__); // add $out = "<div class='InputfieldFileLanguageInfo'>" . "<ul class='actions'>" . "<li><a href='{$translationUrl}edit/?language_id={$page->id}&textdomain=$textdomain'>$edit</a></li>" . // change "</ul>" . "<p><span class='InputfieldFileLanguageFilename'>/$file —</span> <span class='notes'>$message</span></p>" . "</div>"; $translationUrl = $this->translationUrl(); $page = $event->arguments[0]->get('page'); $translate = __('Translate New File', __FILE__); // add $out = "<ul class='actions LanguageFilesActions'>" . "<li><a href='{$translationUrl}add/?language_id={$page->id}'>$translate</a></li>" . // change "</ul>";
-
Hi Adam, tested it. But the 'transate new file' link still isn't visible? for translated menu dropdown (class=subnav) I changed this: $nav .= "\n\t\t\t\t<ul class='subnav'>"; foreach ($p->children as $c) { $subclass = strpos($page->path, $c->path) === 0 ? " class='on'" : ''; $title = strip_tags((string)$c->get('title|name')); $title = __($title, dirname(__FILE__) . '/default.php'); $nav .= "\n\t\t\t\t<li><a href='{$c->url}'{$subclass}>$title</a></li>"; } $nav .= "\n\t\t\t\t</ul>"; Works so far, but strange.. the entry 'Fields' is not translated?? For example 'Languages' is translated. Hmm, did I oversee something? In the Teflon2 theme all is translated.
-
This we can fix in the /wire/templates-admin/default.php. That's no theme topic. One more fix to do in Unify theme: the 'Translate New File' link is invisible. At least needs some height (and the other theme styles) ul.LanguageFilesActions { height: 50px; /* example height */ } the last thing to find are the menu-dropdowns (for translations)..?
-
just need an advice from the GitHub pros... Kongondo told me, to submit changes in both forum and GitHub. I already have created an account on GitHub and forked the german language pack from Matthias (yellowled). Also I did my first updates and pull requests there. Now I found some more points to check in the PW dev repo (regarding translations in 2.3.4/2.4). Do I have to fork the full PW dev repo, do the changes and then commit them? Or can I do this only with the files which need the changes? thanks Manfred
-
@Ryan would make sense to include translation strings in the ProcessLanguage.module (\wire\modules\LanguageSupport\ProcessLanguage.module) 'title' => __('Languages', __FILE__), 'summary' => __('Manage system languages', __FILE__), so we get an consistent translation under 'Setup'. BTW: is it ok to post such things here? Or better doing this via GitHub?
-
maybe this discussion is helpful: delivering-module-translations Until now there is no guideline for this?
-
Hi Adam, love your theme. Think, this can be the new PW default theme. Found some points to check/fix (for translations) in default.php (compared with default.php in /wire/templates-admin/) line 11 <html lang="<?php echo __('en', __FILE__); // HTML tag lang attribute /* this intentionally on a separate line */ ?>"><head> line 15 <title><?php echo __(strip_tags($page->get("browser_title|headline|title|name")), __FILE__); ?> › ProcessWire</title> line77 <h1><?php echo __(strip_tags($this->fuel->processHeadline ? $this->fuel->processHeadline : $page->get("title|name")), __FILE__); ?></h1> line 87 $title = __($breadcrumb->title, __FILE__); line 91 <li class="fright"><a target="_blank" id="view-site" href="<?php echo $config->urls->root; ?>"><?php echo __('Site', __FILE__); ?></a></li> line 115 <?php $edit = __('profile', __FILE__); ?> but I don't find the menu drop-downs? Also a little bit strange: with the fixes from above the h1 and breadcrumb work like expected under /Setup/ (Fields --> translated to Felder). Under /Access/ Users, Roles, Permissions will not be translated in the h1 and in the breadcrumb.
-
I'm also a fan of the simple PW layout... without sidebar. On the other side: yes, the look and feel of the default admin theme needs a refreshment. Phillips design demo above looks very very good. Also the idea for simple changing the colorschemes is nice. 3 colors (like above black, blue, green) is enough I think. More should be done via themes. In the moment I mostly use Soma's Teflon-2 theme. It's well done, complete and looks serious (for most people). My second favourite is the Unify theme. Has very nice fresh colors. But there a still some missing translation strings? Unify could imho be a good starting point for a new PW default admin theme.
-
short update: the missing string has to be placed in /wire/templates-admin/default.php. Maybe could be done with installation process of the language support module? /* * Dynamic phrases that we want to be automatically translated * * These are in a comment so that they register with the parser, in place of the dynamic __() function calls with page titles. * * __("Pages"); * __("Setup"); * __("Modules"); * __("Access"); * __("Admin"); * __("Languages"); // the missing phrase * */ after that it's translatable. Also have done some more translations for the german language pack (for 2.3.4). Will send a pull request soon.
-
just try to find some missing strings in the translation (for the dev version). One example: in \wire\modules\LanguageSupport\ProcessLanguage.module there are 2 translation strings for title and summary missing: class ProcessLanguage extends ProcessPageType { static public function getModuleInfo() { return array( 'title' => __('Languages', __FILE__), 'summary' => __('Manage system languages', __FILE__), 'version' => 100, 'author' => 'Ryan Cramer', 'requires' => 'LanguageSupport', ); } now the /setup/ is full translated. After that you have to rename the Languages page in the tree under Admin/Setup to get the heading and breadcrumb translated. Correct? Or should this be done better via translation strings? EDIT: that's not the correct way. Seems, there are missing translation strings in the language modules? Where? in general: where can I post missing things like this (which is in the core)? Is it welcome? Unnecessary? it is hard to find all translatable strings and translate them. There should be a simple overview (new strings in bla.module, blubb.module renamed, bang.module deleted etc.)
-
here are some infos about telephone numbers. There are a lot of formats... http://en.wikipedia.org/wiki/National_conventions_for_writing_telephone_numbers
-
Assets not accessible - sometimes/mobile devices???
Manfred62 replied to r2d2's topic in General Support
Cross-Domain data requests?? Seems to be a problem with cross domain policy. -
Assets not accessible - sometimes/mobile devices???
Manfred62 replied to r2d2's topic in General Support
Even on desktop your images aren't acessible for me. do you really have the absolute url in the path? Normally it's not needed. Could do it like this when the image is in your $page <img alt="<?php echo $page->title; ?>" src="<?php echo $page->heroImage->size(150, 200)->url; ?>" /> or can do this, if image is not placed via your $page (e.g. in template file?) <img src="<?php echo $config->urls->templates?>your/path/to/image.jpg"