-
Posts
269 -
Joined
-
Last visited
Everything posted by kaz
-
Reinstall with same database and templates?
kaz replied to modifiedcontent's topic in General Support
This module is from Ryan, you don't have to worry about it. -
Template development is very slow under macOS, MAMP Pro. Every click in the backend takes a lot of time. Is it normal?
-
I have found why it does not work. It only works with the ProFields module Functional Fields.
-
Landing page exclude from prepend and append config entry
kaz replied to kaz's topic in General Support
@zoeck A great and simple solution. Thanks! -
I have a website with a landing page. The layout of the content pages has $config->prependTemplateFile = 'views/partials/_prepend.php'; $config->appendTemplateFile = 'views/partials/_append.php'; The layout of the landing page template is completely different, with a different header and footer structure. Because it's only one template / one page, I don't need an entry in the config. I'm figuring out how to solve this? The entry in the config assigns the prepend and append file to all pages? It would be great if the template landing.php does not have a prepend and append file assigned to it. Is that feasible?
-
Reinstall with same database and templates?
kaz replied to modifiedcontent's topic in General Support
You may save an project with the module ProcessExportProfile for a new installation. Open Export Site Profile under Administration. Create a new profile in the input mask. Copy this /site folder (site-yourprojectname) into the installation folder before a new installation, select your site profile, that's it. Everything is included, only own files like ready.php … are not included, have to be transferred manually. -
I have installed Multi-language, activated the (Multi-Language) fields, added an additional language, and of course an language switcher. All content works fine, all fields are translated. But translatable strings do not work. Here's an example: <?php echo __("Kontakt");?> or <?php echo "<h6>" . $this->_('Kontakt') . "</h6>";?> Under Languages I find the PHP file with the entry "Kontakt", I translate the text "Contact". But the translation is not visible in the frontend. What did I forget?
-
module PrivacyWire - Cookie Management & async external asset loading
kaz replied to joshua's topic in Modules/Plugins
@joshua I have read the documentation. Sorry, no banner is displayed for me after I confirmed it once days ago. Unfortunately, in none of three browsers (macOS). At Klaro there is a possibility to keep the dialog visible via a code https://example.com#klaro-testing. How do I get to see it on PrivacyWire? Functionality: What do I do after installation, how do I add these following Processwire modules / functions: OpenStreetMap (FieldtypeLeafletMapMarker, InputfieldLeafletMapMarker, MarkupLeafletMap) Video embed for YouTube (and Vimeo) (TextformatterVideoEmbed) In the documentation I read: "When you want to load specific scripts ( like Google Analytics, Google Maps, ...) only after the user's content … add 'data-category="statistics"'" The module for OpenStreetMap is integrated like this: <?php $map = wire('modules')->get('MarkupLeafletMap'); ?> <?php echo $map->getLeafletMapHeaderLines(); ?> I can't add anything, if I haven't overseen something? In the TextformatterVideoEmbed options I have this GDPR option: [ ] GDPR: Use the no-cookie / do-not-track version of video URLs but no possibility to extend the module code as shown in the documentation. I am probably completely wrong with my assumption that this is the way to connect things to PrivacyWire? Sorry if I oversaw something, the more I read the more it confuses me. Maybe it will work sometime, to enable installed things like TextformatterVideoEmbed in PrivacyWire, and done ? Thanks for the module, I'm just struggling a bit with the functionality. -
if I do two installations: what do I do with the "root – selection-page"? With each installation the selection in page ID1? That would be an internal, and an external link to the second URL.
-
@zoeck No, not necessarily. I have no experience with it. I also think (as you write) that is too much?
-
I have a company that is divided into two parts. I'm thinking about how to set up the site. My present idea is: The landing page (ID 1) with a landing template / page which links to two sub-pages. Subpage 1 is Part 1 of the company, Subpage 2 is Part 2 of the company. Each part has a separate root page / template, with its own menu. I then have to align the menu to the template? Each part has its own URL, but I don't have a solution. I think I will simply redirect one of the URLs via 301. How would you setup this situation? A sketch for better understanding:
-
Now it works. I had to think about what 'value' is. I take the ID, maybe it was the same lake the values, and it works. $w1=intval($item->colwidth->id) My Options are 1=1 2=2 3=3
-
@DV-JF The value then is passed with NULL, when 1 is selected: w1 = uk-width-0-4@m w2 = uk-width-4-4@m
-
sorry, I don't understand? w1 = $item->colwidth; the value is passed, $w2 = 4 - $w1; needs to change something on this line?
-
@gebeer I have sadly an error message with the minus operator, the passing of w2: Notice: Object of class ProcessWire\SelectableOptionArray could not be converted to number in /Users/Sites/localhost/domain.com/site/templates/fields/matrix.php on line 26 Line 26 is $w2 = 4 - $w1; The operator is correct, the error is probably in the position of the lines? It's part within a repeater matrix, here's the full code: if($item->type == 'twocols_content') { $w1 = $item->colwidth; $w2 = 4 - $w1; echo "<article uk-grid> <div class='uk-width-{$w1}-4@m uk-width-1-1@s'> … </div> <div class='uk-width-{$w2}-4@m uk-width-1-1@s'> $item->content </div> </article>"; } w1 is passed correctly after selection, the Options/Select field colwidth is passed. I have applied it this way (InputfieldRadios): 1=1 2=2 3=3 4 I don't need, 4 results in zero, when the minus operator works ?
-
@gebeer I will try that, it looks easy. Thanks!
-
I would like to give an editor the ability to specify the width of columns in a section. The template may have 2 columns, which have now the with of quarter spacing. How do I set it up to make the most sense? If the editor sets the left column to 4, the right column should automatically be 8. Is there a way to do such a setting. I have no idea which field is best suitable for this? I had a look at FieldtypeOptions, but I don't think that's right? maybe InputfieldFloatRange, but then I have only one width. Has anyone implemented something like this before and can give a tip? It would be great if the editor could change the widths uk-width-1-*@m. Here an example of how I do it statically at the moment. <div uk-grid> <div class='uk-width-1-4@m uk-width-1-1@s'> <figure> <img src='{$page->image->url}' alt=''> </figure> </div> <div class='uk-width-3-4@m uk-width-1-1@s'> $page->body </div> </div>
-
Exactly, that was my goal, to do it in the base template. Thanks that works!
-
@netcarver thanks netcarver, this helped a lot. echo "<ul id='side-menu' class='uk-list uk-margin-remove uk-padding-remove'>"; foreach($pages->get(1044)->children as $child) { $active = wire('page') == $child ? "current" : ""; echo "<li class='$active'><a href='$child->url' title='$child->title'>" . $child->get('menutext|title') . "</a></li>"; } echo "</ul>"; I call the list pages in my base template with the page ID of the parent page: <?php if ($page->id == 1044): ?> <?php include('views/partials/menu-aside.php'); ?> <?php endif; ?> However, the list should also be displayed in all children's pages. ID is therefore wrong? Is there another option which includes the children's sites?
-
sorry, a typing error: mengtest = menutext ('menutext|title')
-
I need to list subpages by mengtest and title of a mother page as a simple foreach ul list. Is there a way, similar to a menu, to list child pages? I couldn't find anything about this in the docs. Maybe you can give me a hint what to look for?
-
When I use echo $page->httpUrl; I get the config url's, for example: domain.com,www.domain.com, what is just included in the config How do I get only one complete root URL incl. https:// maybe for <base href="<?php echo $urls->…; ?>" />
-
It doesn't work, probably it's just too much 'if' in too many files? The modal window is not displayed, but exists in the source code of the browser. It is hard to describe, why it does not show up. So I just leave the error message, because it works with these error, although not clean. I removed the space before .show(), it makes no difference. PS: It's hard to test, because the popup appears only once :) that's why my reply took so long.
-
I load the UIkit scrips before UIkit.modal. Perhaps I'm misunderstanding something, have a look at the post from September 3. The error message appears only if the field settings_modalwindow has no entry. If the field has an entry, it works. That's why I thought it would be necessary to query both?
-
I have a little error (code inspector) message due to the double if query: Uncaught TypeError: UIkit.modal(...) is undefined <anonymous> https://localhost:8890/:240 In the prepend / append files I have these code: prepend: <?php if ($global->settings_modalwindow): ?> <div id="modal-center" class="uk-flex-top" uk-modal> <?php echo $global->settings_modalwindow; ?> </div> <?php endif; ?> append: <?php if ($page->id == 1): ?> <script> let infoShown = localStorage.getItem('infoPopup'); if(!infoShown) { UIkit.modal('#modal-center') .show(); localStorage.setItem('infoPopup', 1); } </script> <?php endif; ?> The error message is generated by the code in the append file when the settings_modalwindow field has no content, but the code is still loaded. I would need to query both ID1 and whether the field has content. Is it possible to query both at once?