-
Posts
687 -
Joined
-
Last visited
Everything posted by Christophe
-
[Moderator(s), can you please remove this post? I've removed its content. Thanks in advance!]
-
ProcessWire is mentioned in at least the first 6 minutes. I had already stumbled upon this video before but hadn't really watched it. Part of the video description: "Benjamin Milde takes some of his favourite CMS’ – ProcessWire – underlying implementations for data querying and storage layout and reimagine those using ecto."
-
I think I had tried it in "Show only if page is matched by selector" but without the parentheses, based on what "Show only if page is matched by custom find" was displaying (but yes it was saying that 0 pages corresponded). With the brackets it works. Thank you!
-
So, I had parent.id=1314 in "Show only if page is matched by custom find", and the editor wants also the video field showing on a specific page not included by the first filter. I can't have it work. So, out of curiosity, I tried again in "Show this field only if". And parent.id=1314 || id=1250 works (parent.id=1314 | id=1250 also). And I don't know why but this time parent_id=1314 alone works (but not parent_id=1314 || id=1250 - with the double or single pipe operator - for the specific page). I don't know if all this is "normal". There is certainly an explanation. Edit: The field appeared for the page (with id 1250) but I had the impression that it wouldn't work and it didn't (the video disappeared after saving the page). Also, it blocked, at least for this specific page and the children of the "parent" page, the "View" link. In fact, I had to just put id=1250 to make it work. Now, I'm back with parent.id=1314 in "Show only if page is matched by custom find". The field is hidden but the video is still there. I might just create another template for this specific page, as the video appears at the bottom after a lot of content in this particular case and should preferably be at the top.
-
Dev ProcessWire could just have a second firstname, Rolling. What about a(n) appointment, booking, scheduling (, calendar) system as a new site profile? Edit: Perhaps integrated as a module(s).
-
For me, parent_id= 1314 or parent.id=1314 in "Show this field only if" doesn't work. It hides the field. It works only as expected in "Show only if page is matched by custom find" or in "Show only if page is matched by selector" where I put this time parent.id=1314 that was given by the "Show only if page is matched by custom find" field when I was using it before. In Visibility, I'm using "Open when filled + Closed when blank". Edit: I didn't deactivate your module when trying it, but I don't think it could have had an impact on the result.
-
Hello Robin, Your module is so helpful/useful. I'm using "Show only if page is matched by custom find" and the parent (page) id. Thank you!
-
Hello, It seems, if I'm not mistaken, that "Show this field only if" still isn't translated correctly after all these years ?. Have a nice week!
-
@Matze and @Pip, I've just had the same problem. Visibility "Open when populated + Closed when blank" works for the fields inside the Fieldset (Page) field, but not for the Fieldset (Page) field itself.
-
Hello @bernhard, I'm about to put in production the website that is using RockFrontend (module and profile). I've updated the module to the latest version (but not the profile). As I want to use ProCache, I wanted to remove the minification of the styles and scripts. But removing both lines in _init.php: ->minify($config->debug ? false : true); ->minify($config->debug ? false : true); causes a ParseError, syntax error, unexpected variable "$rf" So, I've tried by using: ->minify(false); ->minify(false); and it seems to remove the issue. I guess it cannot be removed.
-
[SOLVED] Disable "add" button in Page Reference field
Christophe replied to Pavel Radvan's topic in General Support
Hello Pavel, In your page reference field, in the Input tab, is Allow new pages to be created from field? ... selected? Which Input field type have you chosen? -
I have resolved everything with children pages and a Page Reference field with single select *. I'm also using the PageEditChildren module. And with children pages I can use the VerifiedURLs pro module.
- 1 reply
-
- 2
-
Hello, I have tried several things without any success after reading several pages from different sections of the website. I even tried to use tagsList that I found about with Tracy Debugger but could'nt get very far. I first tried with the Pro Table field and ASM Select *, then, because it seemed impossible or too complicated, I tried the same but with children pages and Text Tags (new to me). Has someone already succeeded in retrieving separately the values and the labels from a Predefined options/tags list (Input tab) in a Text (Type) field with the Text Tags Input mode (Details tab)? Max tags/options is 1. In this case, there is a parent page displaying content from its children pages (I already get the single possible value. I can't get its label (like it was also the case with the Pro Table field). Even though I would have liked to be able to get it I don't need it this time). But in order to filter the children data "cards" displayed on the parent page, I need the value and the label for each Predefined options/tags that I defined in the Text Tags field. I can't manage to have a list of <li uk-filter-control=".{$value}"><a href="#">{$label}</a></li>. In Predefined options/tags list, I have a list of value=label, because in my language I can't have the same for both. Thanks in advance if anyone already faced this need and resolved it.
-
There are also the new URL/path hooks: https://processwire.com/blog/posts/pw-3.0.173/
-
Hi Bernhard, I removed RockFrontend.min.js because it's not needed as RockFrontend.js is already added automatically. The browser says it is related to the following line, certainly the only place where j is mentioned: (j = 0; j < attrs.length; j++) { I was just testing the rf-scrollclass attribute (with the css that is included in the docs): <footer class="tm-prose"> <div class="uk-container"> <div class="uk-text-right"> <a href='#' rf-scrollclass='to-top show-desktop@300 show-mobile@600'>Scroll to top</a> </div> ... I don't know the reason for the error message, so I'm just removing the attribute for the moment. I'll try again another time. Have a nice evening!
-
Hello Bernhard, I updated/upgraded ProcessWire and RockFrontend recently (ProcessWire 3.0.239, RockFrontend 3.15.1, PHP 8.1). I've just noticed 2 error messages in the consoles in Vivaldi and Firefox. (Debug mode is on. It's the same when it's off.) I wanted to try the Scrollclass so I added this in _init.php (RockFrontend profile): ->add('/site/modules/RockFrontend/RockFrontend.min.js', 'defer') I'm not sure if it works as intended as there is one error message related to RockFrontend.min.js. The error message related to RockFrontend.js (so the non minified version) already exists when the above code related to RockFrontend.min.js is not added. I don't remember noticing this error message related to RockFrontend.js before. So now, I see this in Firefox: Uncaught ReferenceError: assignment to undeclared variable j <anonymous> http://domainname.fr/site/modules/RockFrontend/RockFrontend.min.js?m=1716312961:5 <anonymous> http://domainname.fr/site/modules/RockFrontend/RockFrontend.min.js?m=1716312961:5 RockFrontend.min.js:5:278 Uncaught ReferenceError: assignment to undeclared variable j <anonymous> http://domainname.fr/site/modules/RockFrontend/RockFrontend.js?m=1716312961:258 <anonymous> http://domainname.fr/site/modules/RockFrontend/RockFrontend.js?m=1716312961:270 RockFrontend.js:258:10 <anonyme> http://domainname.fr/site/modules/RockFrontend/RockFrontend.js?m=1716312961:258 <anonyme> http://domainname.fr/site/modules/RockFrontend/RockFrontend.js?m=1716312961:270 And this in Vivaldi (chrome-based): RockFrontend.min.js?m=1716312961:5 Uncaught ReferenceError: j is not defined at RockFrontend.min.js?m=1716312961:5:279 at RockFrontend.min.js?m=1716312961:5:534 (anonymous) @ RockFrontend.min.js?m=1716312961:5 (anonymous) @ RockFrontend.min.js?m=1716312961:5 RockFrontend.js?m=1716312961:258 Uncaught ReferenceError: j is not defined at RockFrontend.js?m=1716312961:258:12 at RockFrontend.js?m=1716312961:270:3
-
RockFrontend Site Profile - RockFrontend + UIkit + TailwindCSS
Christophe replied to bernhard's topic in Themes and Profiles
[Deleted content] -
RockFrontend Site Profile - RockFrontend + UIkit + TailwindCSS
Christophe replied to bernhard's topic in Themes and Profiles
Hello Bernhard, A bit of context before the questions below in the message. I want to display a list of children of the parent pages that are using the template "parent-page". So, I have created parent-page.php (empty for the moment) in /site/templates. And ParentPagePage.php in /site/classes in which I have this (where I tested different things): <?php namespace ProcessWire; class ParentPagePage extends Page { public function listchildren() { return "Clickable list of children"; } } I had more elaborate code(s) in the return statement, but things weren't working so I just put a string in it to keep it simple. (I've just noticed that vscode and intelephense are writing "Undefined type 'ProcessWire\Page'." in the PROBLEMS tab.) So I had : Method DefaultPage::listchildren does not exist or is not callable in this context on pages that do not use the parent-page template (and use the basic-page template). Method HomePage::listchildren does not exist or is not callable in this context on the homepage. For the error messages and blank page(s) to disappear it seems that it is mandatory to use this in main.latte: {if $page->template == 'parent-page'} {$page->listchildren()} {/if} and not just {$page->listchildren()}. At one point with custom page classes I think I was hoping it would also remove the need for that if condition. In /site/templates/sections/main.latte I currently have the code that follows - at the end of the message now (we apparently can't escape having to use the |noescape filter). I simplified the code to only define and check $image (the code borrowed from another website was also defining and checking $images, so not only the first image, I don't remember why/if it was needed). SO, my question(s) is how could this code be simplified, in part in order to have cleaner code in this main.latte file? Which parts of the code should be in main.latte, which ones in ParentPagePage.php and which ones perhaps in parent-page.php? How would you organize/separate them in the different files? Also, can $image and $thumb be defined elsewhere? Etc. Thanks again in advance! I tried yesterday with simpler children list codes (without images and uikit markup), but it seemed complicated and not clean. And now it's more complicated. I've tried with code directly inside the return statement, and also with a variable and then returning the variable. $thumb is currently defined if $image exists. If I used <img n:if="..." src="... it would be changed. But perhaps it wouldn't be important if it wasn't defined inside the {if}...{/if}. <main> <div class="uk-container"> <h1>{$page->title}</h1> {$page->body|noescape} {if $page->template == 'parent-page'} {$page->listchildren()} {/if} <div n:if="$page->template == 'parent-page'" class='uk-child-width-1-3@m uk-grid-match uk-margin-small-top uk-margin-medium-bottom uk-text-center' uk-grid> <div n:foreach="$page->children() as $child"> <div class='uk-card uk-card-small uk-card-default uk-card-body'> <a class="h2" href="{$child->url}"> {var $image = $child->images->first()} {if $image} {var $thumb = $image->size(200, 150)} <img src="{$thumb->url}" width="{$thumb->width}" height="{$thumb->height}" alt="{$image->description}" /> {/if} <h2>{$child->title|noescape}</h2> </a> </div> </div> </div> </div> </main> -
RockFrontend Site Profile - RockFrontend + UIkit + TailwindCSS
Christophe replied to bernhard's topic in Themes and Profiles
Hello Bernhard, basic-page.php and home.php are empty template files. Are they only needed (even empty) if custom page class(es) php files that are related to them exist? Because latte files are used here I'm a bit confused about the (possible) role of these template files. In this site profile, in which use case(s) would they not stay empty? Could you please give one (or more) example(s)? Thanks in advance! NB: I don't want to use tailwind, but I'm curious about _tailwind.css, I think it's the first time I see the "_" prefix on a css file name. -
If there is a ruby one there should also be a python one ?: https://wagtail.org/ If ProcessWire didn't exist I probably would have already tried it. (I would also probably have tried a ruby one.)
-
Hello Ivan, Not yet. But unlike other interesting things that I haven't tried yet, I wanted to post the link anyway. I'll try it on another computer than my main one, on an old laptop or desktop, first with the "Mistral" model I think. A few GBs are needed if I remember correctly. During a few seconds I thought about the AIs taking control of our computers without asking permission in the future... They could also help to protect them. But let's not forget data poisoning. Have a nice week Ivan! Have a nice week also @szabesz!
-
https://jan.ai/
-
https://processwire.com/blog/posts/new-rte-for-pw/ (see Toolbar configuration) https://processwire.com/blog/posts/using-tinymce-6-in-processwire/