wishbone
Members-
Posts
183 -
Joined
-
Last visited
Everything posted by wishbone
-
I was so happy to have everything together now ;-) new problem Installed a basic install on a running environment, via .install.php. Database connection fine, tables are there. Install.php destroyed "itself" (couldn't find it any more after installation process). Install Folder deleted. I now can see the index.php ok, but any local site link gives (example:about) "Not Found. The requested URL /about/ was not found on this server." Where could I search? There was a problem during setup. the .htaccess wasn't recognized as "processwire", though it was the renamed htaccess.txt .I skipped that point.
-
with the trees, I had the problem how to make the menus only use the tree items of their language tree... well, could have been done with different nav templates for each language, excluding part of the tree. But I worked myself into LLU, it's nice, because it switches each site to its respective language pendant. Does it mean, this LLU will be deprecated? I didn't have time to wait for April.
-
one same value across pages for each language. As "company" is a textLanguage field, I filled in the values on the home page, and your suggestion works... sry ;-))))))) omg ... still a lot to learn... thx for private lessons!!! But after one month, I have now almost everything together for a small site with nice gimmicks. When finished I'll write a short report, maybe encourages other users with little coding expirience to use this smart CMS!!!
-
It's got different name in different languages... last suggestion works!! now only need a solution for the direct link to a language page as described above...
-
sry I wasn't clear. i created a new field, "company", which appears on every page and should have always the same value. Without language fields this would be no problem by setting the company's name as the value $page->set("company", $value). But how to set the value for the other languages? New language problem. I want to link certain global menu items to specific pages like so: <li><a href="<?php echo $pages->get(1051) ?>">Kontakt</a></li> gives me 404 error... url shown is http://localhost/company/tr/1051
-
now, I want the headline to be the same on every page (Name of company). No problem using $page->set("field", $value) But how to put the other languages?
-
yes, really, they're not easy to find but for beginners, like me ;-) very useful. You only get them via google search; from the main page http://processwire.com/tutorials/quick-start/ they aren't linked...
-
ah thx you updated it ? Got it! I actually did use it sry I was not clear. Only I didn't understand the part with the current class - now works! Great thnks, as always!
-
I managed to get the LLU to work, to change the linktext - but I'm lost how to assign the current language the class "current"... <li class="current"><a$class href='$page->url'>$gateway->LangLinkName</a></li> of course, outputs all links with class="current"...
-
I have a simple site which should be in two languages. no language support in admin needed. Which is the easiest way to achive this? I don't mind two trees, but don't know how to deal with it. Is the LanguageLocalizedURL module the one which does it? I've read on Ryan's new implementation of mulitlingual site support in the 2.3 version http://processwire.com/talk/topic/2979-multi-language-page-names-urls/ - is it already advisable to use it?
-
is it already advisable to use this new core? I'm a bit confused about the documents on multilingual sites, older and newer, I don't know which approach is the easiest at the moment. Separate trees? multilanguage fields? I only need a normal site in two languages (no backend languages), and if separate trees, how to manage. Maybe LanguageLocalizedURL.module is the easiest way? (looks complicated to me, anyway...)
-
thx!!!!!!!!!!!
-
great! thx! Is it enough to write if(count($page->field_name)) { or do we need if(count($page->field_name)>0) { Actually, in my first attempt I referred to this explanation: http://processwire.com/tutorials/quick-start/images/ if ($page->sidebar_image) { where he checked for if an image had been uploaded...
-
I want to check if there are elements uploaded in a field. why does this simple code: <?php if ($page->field_name){ echo "<img src='{$config->urls->templates}ditib-img/dummy.gif' width='1200' height='600'>"; } else{ echo "<img src='{$config->urls->templates}ditib-img/dummy.gif' width='800' height='240'>"; } ?> only throw me the first choice? No matter if there are images uploaded to the (images type) field or not.
-
how to retrieve repeater Id and export it to JS (gallery)
wishbone replied to wishbone's topic in Getting Started
ahhh... concatenate, of course... thx a lot! -
how to retrieve repeater Id and export it to JS (gallery)
wishbone replied to wishbone's topic in Getting Started
omg is it that simple?? (Once one knows....) but why didn't it want to use my variable var repeaterPageId = '<?php echo $repeaterPageId; ?>'; as id in the jquery call? well that's only for learning I don't want to take your time for lessons ;-) Thanksa lot! In this forum, up to now, I have never been left without a solution!!! modX community is very good, too - but no comparison to here!! -
how to retrieve repeater Id and export it to JS (gallery)
wishbone replied to wishbone's topic in Getting Started
that's exactly what I came up with ;-) thx!!! -
I can manage normal tasks I have been using modX which I don't find so very different. Except if it get's more in depth ^^ I have learned (have been learning?) a little php and JS to get the syntax, but...
-
how to retrieve repeater Id and export it to JS (gallery)
wishbone replied to wishbone's topic in Getting Started
thx for struggling through my "intuitive" code... since I'm a non coder I can only try to adapt examples to my needs... I changed to var repeaterPageId = '<?php echo $repeaterPageId; ?>'; // <- the quotation marks were missing here console.log(repeaterPageId); // <-with or without quotations it now logs the id as a number... var options = {}; $("#repeaterPageId a").photoSwipe(options); to be used in the above call echo "<div id='$repeaterPageId' class='gallery'>"; but how do I use the JS variable to let Jquery call the id of the element with that selector? in other words, how can I feed the repeaterPageId into the #'repeaterPageId' ? (I already tried quotations...) Anyway, I found another solution without passing the Id... but I'd like to learn how to do this! Yes, it's not processwire problem... -
I feel with this guy... I like this system it's so clever and smooth! But for non-coders, it's very very difficult. Which is a pitty, because it's so worth for more people to like and use it!
-
how to retrieve repeater Id and export it to JS (gallery)
wishbone replied to wishbone's topic in Getting Started
sounds so really easy... but I can#t bring it to function... <script language="javascript" type="text/javascript"> (function(window, $, PhotoSwipe){ $(document).ready(function(){ var galleryId = <?php echo $repeaterPageId; ?>; console.log(repeaterPageId); var options = {}; $("#galleryId a").photoSwipe(options); }); }(window, window.jQuery, window.Code.PhotoSwipe)); </script> throws me The JS is in the same template -
how to retrieve repeater Id and export it to JS (gallery)
wishbone replied to wishbone's topic in Getting Started
that was it!! thx!! The "first()" had confused me... Now, can I pass this variable (repeaterPageId) to a jquery script? -
how to retrieve repeater Id and export it to JS (gallery)
wishbone replied to wishbone's topic in Getting Started
The name of the repeater field I was trying to get the ID of the repeater as an identifier for the gallery. Now "0" for the repeaterPageId is thrown... -
how to retrieve repeater Id and export it to JS (gallery)
wishbone replied to wishbone's topic in Getting Started
it's this page... $repeaterPage = $page->get($name_of_repeaterfield); $repeaterPageId = $repeaterPage->id; echo "<div id='$repeaterPageId' class='gallery'>"; doesn't work (( -
how to retrieve repeater Id and export it to JS (gallery)
wishbone posted a topic in Getting Started
Hi, I'm struggling with the syntax... multiple galleries, created as repeaters, need an ID to export to JS - to call a gallery script. Everything works so far except the repeater Id, which I don't know how to concatenate to form the #galleryId. This is my hopeless attempt: $repeaterId = $pages->get($repeaterPageID); $galleryId = gallery.$repeaterId; echo "<div id='$galleryId'>"; foreach ... ...