Jump to content


  • Posts

  • Joined

  • Last visited

Everything posted by Bacelo

  1. Thank you @MoritzLost ? If I got it right, named groups are actually more then a OR selector, because (in my case) both selectoras will work. So it's more like a OR-AND selector.
  2. Thank you. Yeah, that's what I did now, as I do understand the "named groups" now correctly... my code looks finally now: if ($standort == '') { $termine = $page->children("sort=date, limit=10, date=(date>=today, enddate=''), date=(enddate>=today)"); } else { $termine = $page->children("standort=(standort_reference~=$standort), standort=(standort_alle=1), date=(date>=today, enddate=''), date=(date!='', enddate>=today), sort=date, limit=10"); } So I grouped by 2x date() and 2x by standort(). Is that correct coded now? Just to know, that I did understand it right.
  3. I think I got it... It works now by the following: $termine = $page->children("standort=(standort_reference~=$standort), standort=(standort_alle=1), date=(date>=today, enddate=''), date=(date!='', enddate>=today), sort=date, limit=10"); At least It looks like the output is correct!?
  4. Thank you @MoritzLost for your reply ?. I had a look at the OR-groups before, but I don't get it. As I understand by now - as you mentioned, if one OR fits, the other selectors then don't matter. So, my logic is wrong... When I remove as mentioned the parenthesis for "standort_reference" and "standort_alle", I don't get any output anymore. ? Actually I need to filter "$termine" twice: -> standort_reference OR standort_alle (standort_reference~=$standort), (standort_alle=1) One of both above has to match - and additionally then -> filter for both (date>=today, enddate=''), (date!='', enddate>=today) get all single day entries where "date" is only in the future AND additionally also all multi day events which are still present running ("date" in past and "enddate" in the future). The part of "named groups" I do currently not understand how to get use of it in my part of code ?: foo=(selector1), bar=(selector2), foo=(selector3), bar=(selector4)
  5. Hi there, I have a bit of trouble on filtering correctly some event pages by some selectors... I do have the following 2 date fields: - start date (fieldname = date) - end date (fieldname = enddate) Some events are a single day event (only start date) - some are a multi day event (end date). Past single day events should not show up. Current multi day events should show up (even if start day is in the past, but end date is future). So I have the following selector: if ($standort == '') { $termine = $page->children("sort=date, limit=10, (date>=today, enddate=''), (enddate>=today)"); } else { $termine = $page->children( "(standort_reference~=$standort), (standort_alle=1), (date>=today, enddate=''), (enddate>=today), sort=date, limit=10"); } This selector $termine = $page->children("sort=date, limit=10, (date>=today, enddate=''), (enddate>=today)"); works fine, but the follwing does not work (all past entries are also shown): $termine = $page->children( "(standort_reference~=$standort), (standort_alle=1), (date>=today, enddate=''), (enddate>=today), sort=date, limit=10"); I have no clue what I'm missing - any ideas?
  6. Hi @montero4, thank you for your reply and and all your infos. SEO is not that relevant regarding the picture part / main gallery page on this project. Besides, I will handle the HTML document structure correctly. Maybe I will go with a detail picture page and have the possibility to do some SEO stuff there then (if needed). As with your site, I will also need to provide several public an internal infos for each picture and also a request pool for paintings via form. I was just thinking on the technical side, how to setup the structure the best way. So I started yesterday having the following structure now for the picure part in the backend: Home Pictures (for the masonry gallery with isotope filter, picture lightbox modal with infos ) Picture page 1 Picture page 2 etc. ... Topics (for Pictures) Topic 1 Topic 2 Topic 3 (which is actually both - topic 1 & 2) So I do have now an field called "topics" in my picture template as a "page reference" type (single page select) and radio button select. I can select now the topics and also the isotope filtering is working already. Regards
  7. Hi there ?, I'm currently working on a new site project and doing a bit hard on finding the right site construct... ? The site will be an artist page displaying paintings. Those paintings are categorized / assigned to 2 categories - either one or both On the home page there will be an intro showing the 3 categories (1 | both | 2) displayed with an image and title with a link to each category Framework: Bootstrap V4.4.1 Gallery page with isotope filter function by https://isotope.metafizzy.co/filtering.html Lazy load function as there will be 100+ up to 500 paintings... Let's say I do the following: Page pool "paintings" containing all paintings (each painting as a page) having some fields like "title", "picture", etc. and also a "category" field as a multiple selection via checkboxes "category 1" and "category 2") Home page showing as intro the 3 categories linked to the gallery page with a hashFilter URL So, do you think this could be the right way (or should I work f.e. with category pages and limit the output for each page with the amount of X or XY paintings)? I'm not sure if the page load even with lazyload could get too heavy as there will be more functionality showing text informations for each painting on modal. So it's maybe better to link then to each painting page and showing the infos there(?). Any ideas for a different construct? Cheers and many thanks in advance ?
  8. Hi there, I'm with @Neeraz - it would be great to have the possibility to also add a class to the link element (for what reason ever). Maybe @kongondo it is not a big deal for you to add that functionality to the module? That would be great ?. Have a nice Friday ?
  9. @Robin S you made my day ?! That works like a charm!!!?? I tried to combine that somehow, but didn't find the right way... (and also didn't find the right selectors ? as mentioned in your posted link). I thought, that this could be combined, but so I tried to go the other way as posted in my question. Perfect - many thanks for your help - learned again something new ??
  10. Thank you @elabx for your help, but unfortunately that didn't worked.
  11. Hi there, I need a little help of the community as I'm walking a bit in the dark at the moment...??? I have the following code and need to add some selectors to the merged array: $termine_1 = $page->children("standort_reference~=$standort"); $termine_2 = $page->children("standort_alle=1"); $termine = $termine_1->and($termine_2); I would like to add the following selectors to merged array $termine: ("sort=date, limit=10, date>=today") How can I achive this? ??
  12. Hello, I just added this module (on ProcessWire 2.8.62), but somehow it ony shows up on the config page of the module. I can't get it display at the front-end. Is there anything else then installing it? Hope someone can help me on this. Regards Bacelo
  13. Aaaah, didn't know that - thank you for your help!
  14. Hi @kongondo, thanks a lot for you answer PW upgrade to V 3.X is not an option currently, so how / where can I download Menu Builder V 0.2.1 ? Regards Bacelo
  15. Hello, does anybody know, if there is a possibility to only output a certain menu level or certain siblings in the menu? Like the begin of a start-level? F.e. start the output at level "sub": - parent item 1 - parent item 2 (don't output this) - - sub item 2.1 (only show / output this) - parent item 3 Currently used version is V 0.1.3 with ProcessWire 2.7.2 Regards Bacelo
  16. Actually I can't unistall the module "TemplateEngineFactory" as the template relies on this I'll continue having a deeper look into and try to cut it down.
  17. Thank you Roope for supporting. Actually I have the following site modules installed at the project: AllInOneMinify DiagnoseDatabase DiagnoseFiles DiagnoseImagehandling DiagnoseModules DiagnosePhp DiagnoseWebserver EmailObfuscation FormBuilder ImageExtra InputfieldFormBuilderFile JqueryDataTables MarkupMenuBuilder MarkupSEO ProCache (not active) ProcessDatabaseBackups ProcessDiagnostics ProcessFormBuilder ProcessMenuBuilder ProcessPageListerPro ProcessProCache ProcessWireUpgrade ProcessWireUpgradeCheck TemplateEngineFactory TemplateEngineProcesswire
  18. I think you meant this : <?php echo '<script src="' . $config->urls->siteModules . 'EmailObfuscation/emo.min.js"></script>'; ?> This works fine as before - the script gets included just fine. But, none of the included E-Mails addresses are replaced with any text and elements at all. They are still untouched present in plain text. So I guess, that the module is "stuck" somehow or not recognized / executed at all during page rendering. Could another module might interfere? (of course caching is not active ) (Processwire V 2.7.2)
  19. Thank you tpr. Closing body tag </body> is present in the html output. -> this is empty / none template is applied to exclusion.
  20. Nope, no emo_addr array is present I guess you mean this part of the module: // create addresses script block $addrScript = "\n<!-- emo -->\n<script>\n var emo_addr = new Array();\n"; $addrScript .= "{$this->addrScript} addLoadEvent(emo_replace());\n</script>\n" It looks to me as if the module is not active. Either the emo_addr array nor the addLoadEvent are implemented. *weird*
  21. Hi tpr, thanks for your reply. I added this as suggested to document ready. Firebug gives me now a ReferenceError: emo_addr is not defined
  22. Thank you Roope for the great module! But unfortunately I can't get to work installed propper placed the script in the head section manually: <?php echo '<script src="/site/modules/EmailObfuscation/emo.min.js"></script>'; ?> script file loading method is set to "manually" script loads propper in head but, the e-mail addresses are not converted within span elements It looks like the module does not interfere at all. Any suggestions???
  23. Thank you, LostKobraKai . I think I'm getting a bit closer, but as I'm still a newbie to processwire (and also not a php programmer), I'm doing not easy to comprehend/understand and get it done. <?php foreach($pages->find("template=category") as $category) { if (count($page->children("template=gallery, category=" . $category))) { $catgal = $category->name; echo $catgal; // category is the current page //$catgal = $pages->get("template=category, category=" . $page); // $pages->get() returns a NullPage if it doesn't find anything, // therefore the check for the id. // if($catgal->id) $session->redirect($catgal->url); } } ?> So I included (for testing) to checked with $catgal = $category->name; echo $catgal; to see, if there are children found with assigned categories below the parent-page and it works - so I get all the existing categories. -> But now, I need to redirect the parent to the very first found category (only of that parent) so that it's children assigned to that category are shown. Maybe I should better explain my backend page setup: - parent 1 (template "main") -> want to redirect to the first found/existing category - Child 1.1 (template "gallery") ... - parent 2 (template "main") -> want to redirect to the first found/existing category - Child 2.1 (template "gallery") ... - Categories (hidden, template "structure") - Category 1 (template "category") ... I configured a field "category" of type page (which I included in the gallery template) - so within an child page I can select the categories. Sorry, If I might explain everything to complicated (actually, now I guess my topic is named wrong)
  24. Thank you LostKobrakai. I'm aware of both possibilities. First idea was to change the navigation, but then SiNNuT came up with the idea with the first child redirect snippet. This should work, the only thing is, that my childs in the navigation are categories and not the "real childs". The childs are filtered by the categories. So, I need to find a way how to change if($page->numChildren) $session->redirect($page->child()->url); to fit with my category-setup. Right now, when I try the code line, of ccourse the real first child gets called and this works. But I need to forward to the first found filter-category so all childs with the first found filter-category are called. hmmm...
  25. Nope, not yet ... still trying to figure it out ... Well, I try to discribe the code I posted: That's how my navigation is: Parent 1 (Child 1 | Child 2 | ...) Parent 2 (Child 1 | Child 2 | ...) Would like to change it to: Parent 1 -> has link of its Child 1 (Child 1 | Child 2 | ...) Parent 2 -> has link of Child 1 (Child 1 | Child 2 | ...) etc. The children are shown on hover and I would like to set the link of the parents to the link of their very first child. In my case the children are categories. So, if there is a category found -> link to first one found.
  • Create New...