Jump to content

Zeka

Members
  • Posts

    1,065
  • Joined

  • Last visited

  • Days Won

    11

Everything posted by Zeka

  1. Hi. I have page tree like that: Product Types ( name: catalog_filters ) disinfectants-and-hygiene antibiotics-injectable antibiotics-oral Products ( name: products ) product1 product2 Also I have hook in my ready.php function productCategoriesAndTypes(HookEvent $event){ $page = $event->object; if($page->template == 'product-category' || $page->template == 'product-type') $event->return = "/products/$page->name/"; } $wire->addHookAfter("Page::path", "productCategoriesAndTypes"); It works as expeted and I get modified urls in PageTree, PagePreview and in ProcessPageEdit: But after page save I get not hooked page url It looks like ProcessPageEdit does not respect hook in ready.php. Is it a bug or I'm missing some setting or it is not right place for hook or I have hook also some other method? As further investigation I have found that problem comes from Link abstraction option in textarea field settings
  2. Zeka

    Padloper showcase

    Maybe @apeisa could share some projects?
  3. Yes, it fixes. I will post an issue to new PW repo. Ohh. Thanks for the expanation. Line-trought style is generated by an Chrome extention. It mark all links with rel="nofollow" with line-trought style.
  4. Hi. I don`t know is it bug or just my little knowledge of php, but I will post it here because it is relative to strict mode of Tracy. PW 3.0.33 Tracy 3.0.3 While Im trying to change field type from TextareaLanguage to Textarea i get notice Also it creates table in DB named like "field_name_pwtmp". If to turn off strict mode in Tracy settings and after removing of newly created temporary table, changing of field type could be done normally
  5. @blynx Ohh.. okey I have options (radio) field with these values: 1=Green 2=Yellow 3=Black 4=Pink ... I have template - "product" which contains this field. I need to output list of products (pages with "product" template), but ordered by some specific order -> black (3), pink (4), green(1), yello(1). Hope that it is clear now $sorted_array = new PageArray(); foreach($order_map as $pos) { // Find pages with some value (e.q. black) $temp_array = $pages->find("radio_field=$pos"); // import pages to new array $sorted_array->import($temp_array); }
  6. @blynx Thanks for suggestion. But i did not fully understood it. Do you mean something like that? $order_map = array( 1 => 3, 2 => 2, 3 => 1, 4 => 4 ); $sorted_array = new PageArray(); foreach($order_map as $pos) { $temp_array = $pages->find("radio_field=$pos"); $sorted_array->improt($temp_array); }
  7. Hi. I have radio buttons with values from 1 to 10 and i need to sort page array with these values, but not ascending/descending ordering, but with custom ordering. For example: At first go pages where value of this field set to 3, then 2, then 1, then 4 and so on. Ho to accomplish it? Thanks
  8. Hi. Was trying to install JquerySelectize with latest PW 3.0.33. Got this error Undefined index: JquerySelectize
  9. Multialguage discription works great if you have the same images for all languages. But when you need to show different images in defferent languages you could use language alternate fields. In this case you will have some fields like images images_english images_ukrainian And you don`t need possibility to enter different discription per language, because different fields will be shown per language. So I think that it would be nice to have this option overidable by template.
  10. The question about behavior is still actual, but for to change it i use this code in init.php $currentLang = $user->language; $pageLanguages = $page->getLanguages(); if(!$pageLanguages->has($currentLang)) { throw new Wire404Exception(); }
  11. Hi. I have some pages wich do not have translation for second language. So i uncheck checkbox for this laguage. Language switcher shows that there is no translation for english, but if i access url site.com/en/about manualy it shows page with deafault language. Is it right behavior? I think that it shoud throw 404 error instead of default language page, because there is no translation = no right content = no page for this url So the question is: does it work like this or Im missing some settings or options? Thank. Best community.
  12. @szabesz Yes, of course, if I uncheck to show in frontend it will be not shown, but i was thinking that if debug is set to false and Im not logged in as superuser it should be not shown.
  13. Im sorry if my question was already answered somewhere, but there is 25 pages to read and i can`t find it. Here is my config of Tracy: I work on localhost. Debug mode is set to false, I am logged out from admin panel, but Tracy is still showing on frontend. I can`t figurate out is it normal behavior for Tracy, because earlier, if Im not mistaken, with the same options it was not showing? Im using latest Tracy version and PW 3.0.30.
  14. Yes, you are right. Very often only few pages have translation to all languages. ( Ukraine is not english speaking country and almost all blogs have only about 10% of posts translated to other languages ). It should be checked by default, IMHO.
  15. I think that it is the best option
  16. Hi PWers. I need to implement filter of products catalog for one of my project. The most difficult part of that is SEF (Search engine friendly) and maybe you can suggest or advice some ways how to do that? So i have this structure: Animal categories: cattle pigs dogs cats Product type categories cat1 cat2 cat3 Product can be assigned to all categories or just to a part of them. There is no problems with that at all. Besides of that structure i need to build search form with two section of checkboxes ( animals categories / types categoreis ); For example if i choose cattle, pigs, cat1, cat2 in this form I have to be redirected to url like that: site.com/catalog/cattle/pigs/cat1/cat2 As you can see there is every url segment represents one checkbox selection. Depending on selection of checkboxes i need to change search result, title, some body text of a page and so on. So i see one way to do that: URL segments and session redirects to url depending of get query. But i don`t know how to hold user selection throught redirect. And what pitfalls can be in this implementation? And maybe you have any other suggetions? Thanks for any info
  17. Zeka

    Padloper showcase

    Hi @Mats Thank you for attention to this thread. Is it your project? I found some bugs.
  18. Zeka

    Padloper showcase

    Hi everybody. I found only one site in showcase section which uses Padloper. https://www.the-weekender.com/ Are there some other known examples of using Padloper?
  19. @LostKobrakai @Ivan Gretsky Thanks for suggestions. @BitPoet
  20. Hi. I am really sorry if my question was answered somewhere already, but i can not find this place) Is there some selector like " template_file_exists" which will indicate that I am looking only for pages without template file?
  21. Hi. Since PW 3.0.9 we have very useful long-click functionality in Lister. As small UI enhancement i would like to propose additional actions as "Save + Exit" while editing some page in modal. Now you have to make two clicks. First click "Save" and then click "Close", with "Save + Exit" it will be just one click.
  22. The same with me. Is it some reading about that feature?
×
×
  • Create New...