Jump to content

Roych

Members
  • Posts

    383
  • Joined

  • Last visited

Everything posted by Roych

  1. I need to translate the a "1 to 10 of 50" string, TO and OF words, can this be done, if so where I looked everywhere? (I'm filtering like in skyscraper profile) Thank you R
  2. I know I deleted the server paths before I posted it (I hope). Now I deleted it from the post too. ? Thank you for all the help and your time kongondo and dragan? R
  3. Omg, that easy, lol. Works perfect only had to change the url to httpUrl and everything is the way it should be. Already had file with complete makup ready. Useful for other stuff also. Thank you very much saved me a lot of time with this. ? R
  4. Thank you dragan but still not working, same error again. Not sure what to do here
  5. not sure how to enabe/disable API functions... ? Both sites are PW version 3.0.165 PHP Version 7.2.33 Both sites Multilingual but second language disabled for the moment (using multilingual fields) environment PHP, MySQL Thank you R
  6. I tried to follow the RESTful API in PW? but it is to complicated for me I guess. Then I tried with https://processwire.com/blog/posts/multi-instance-pw3/ again but it's not working even on this tutorial site. Was this ever fixed or am I doing something wrong. I would just like to show events from the main site on the second site on the same server. Similar to rss. Events are maintained only on the main site. Second site would just show the upcoming events I tried with: (testing) <?php namespace ProcessWire; // Server path to the PW installation $path = '/home/myserver/mydomain.com/'; // The root URL for the PW installation $url = 'http://mydomain.com/'; // Create a new ProcessWire instance $site = new ProcessWire($path, $url); // Find the 5 newest items in modules directory $items = $site->pages->find("parent=/modules/, limit=5, sort=-created"); // output list foreach($items as $item) { echo " <p> <a href='$item->httpUrl'>$item->title</a><br /> </p> "; } But tracy gives me error Any idea how to fix this? Do I have to do anything else than just put the code in my template or do I have to create an extra template for this like with (rss) or.... (Im new new to this) Thank you very much R
  7. Hello Need some help "again" ? Never done this before ... I have three PW sites with different domains all three on the same server (each with it's own database not multisite), I would like to bring 5 latests posts from one PW sites and show them on other two sites. what would be the simplest way to do this. I tried to follow this but just won't work it gives me blank page or 404. https://processwire.com/blog/posts/multi-instance-pw3/#how-to-create-a-new-instance Not sure if I want to use RSS feeds... Thank you R
  8. Yes, thank you very much, it's working great now. ? R
  9. Hello, Im having two weird problems on my PW installation (site almost done). When I enable TracyDebugger I can't acces the HomePage (all other pages work normaly) when loged in (I get 404) and there is a lot of code from tracy backend below my site on frontend. When Im not loged in the Homepage is normaly accesible or if I disable tracy. this is how it looks: And another problem is I have a field called scripts but I cant edit the field or view it's settings. Although it works fine on frontend and when editing a field on pages. This is the error when I try to edit the field in Admin->Setup->fields->scripts (Textarea - AceExtended) Any Ideas? Thank you for your time R Thank you
  10. It was Capital first letter so the page2 URL was different from first page. Expl: // added skupine // if a skupine is specified, then we limit the results to having that skupina (skupine_page_select field in those pages) if($input->get->skupina) { $skupina = $pages->get("/skupine/" . $sanitizer->pageName($input->get->skupina)); if($skupina->id) { $selector .= "skupine_page_select=$skupina, ";//CHANGE YOUR SELECTOR AS SHOWN HERE // $summary["Skupina:"] = $skupina->title; $input->whitelist('skupina', $skupina->name); } } the $input->whitelist('skupina', $skupina->name); I had the capital letter S it was my mistake. ? But I do have one question is it possible to output search summary somewhere else than above search results. Not sure how to take it out of the search.php an maybe put it in some includes maybe or ... Right now I commented it out as it is not really necesary but it would be nice to maybe put it somewhere so user can see what they were searching. I mean this --> Thank you R
  11. I got it, I found the problem in search.php I got my first site with filtering between multiple pagereference field working, jeeey. So no need for outsourcing, PW is great. ? Thank you kongondo R
  12. Hello Finaly I have managed to make everything work as I want, the only thing is that now the pagination wont work as it should for filtered results. When you filter the results and if you klick on page2 it shows all of the articles not just the rest of the filtered ones. The results are filtered between two page-reference fields in one post. pagination is enabled on all templates. Is there a way to tell pagination to paginate only those filtered results? I tried to look for possibilities on the forum but could't find anything like that. Thank you in advance R
  13. Ok I'm lost here and decided I'm actualy willing to pay someone (reasonable price ofc.) to create some working very simple site_profile so it can be reusable if I come to this problem again in the future. ? Profile with _prepend, _append strategy simple without func. I need articles page (similar to blog) with two or three page_reference fields inside each article for creating and selecting different categories (each article can belong to more than one category). And with dropdown filtering of all articles on frontend similar to skyscraper profile (filtering between page-reference fields), and with keywords search. Maybe also with navigation to each category article list. page tree: (can be about anything, just made this up) BLOG - article 1 (including 3 pagereference fields with multiple checkboxes(choices)) - article 2 (including 3 pagereference fields with multiple checkboxes(choices)) - article 3 (including 3 pagereference fields with multiple checkboxes(choices)) CATEGORY 1 (Page reference field1) - cats - dogs - birds CATEGORY 2 (Page reference field2) - fury - Feather - Furr & Feather - other CATEGORY 3(Page reference field3) - something else - and another that is all ? Anyone? ? R
  14. Yes I'm using this skyscraper profile. and somehow not sure how to work with those regions I read about them but still confused about this. And I have differenet template layouts for pages so it would be easyer for me to work like I'm used to so I can continue my work. fetching includes to those regions is still a mistery for me. ? Not so good with those php codes inside so not really even sure what to look for. All I need is this search (filtering) function to work with prepend strategy. Maybe there is some easyer options for making this kind of article filtering between two page reference field (categories) inside articles, but cant find any good solution. Thank you R
  15. Kongondo thank you for your reply. I somehow managed to make it work. I had to put both in search.php to make it work. require_once('./_func.php'); require_once('./_init.php'); and at the end of it I had to put in the echo region('content'); to show me the results. But now Im struggling to style the search results. I guess I have to put all the styling inside of search.php, but not realy sure how to do that. Everything I try gives me errors. I think I need to change the echo region('content'); to echo the html of the template I wish.not sure how to do that. (I guess I won't be needing region after this, or ..?) Thank you R
  16. Hello, Sorry for the title, didn't really know how to address this post. This would also probably look like very stupid question, but anyways. ? So my problem is, that I would like to change strategies from (skyscrapers-profile) init.inc, main.php to direct output strategy (change in config -> prepend.php, append.php) so (without main and func and init files), as I am more familiar without them and don't really need them for my project. I tried to work with it but always get lost in it somehow (not a coder). When I change the config and got everything working, I can't get the search.php output to work. I'm using skyscraper search.php and search-form.php but I cant get the output to work this way, because some of the functions needed are in func.php file as well. I need similar filtering on my site like in skyscraper profile. (two page reference field in one article and filter between them - filtering articles between categories) I like the result summary that skyscraper profile has. My search.php My search-form.php and my func.php Can this be done at all somehow. Or maybe there is a simpler way to achieve this. I tried to play and change the skyscraper profile, but got lost as I never worked this way before. Sorry again if this post looks crazy, I just hope someone will understand this post. Any help is appreciated Roych
  17. Yes, it would be a great feature for the module. Im mostly using MB. ? Thank you for the code I'll try to addapt it to my needs ? Thank you very much R
  18. Here it is: <ul id="mainNav" class="nav nav-pills"> <li class="active"> <a href='/'>Domov</a> </li> <li class="dropdown dropdown-submenu"> <a href='/about/'>Mladi</a> <ul class="dropdown dropdown-menu dropdown-item"> <li class="dropdown dropdown-submenu"> <a href='/site-map/'>Site Map</a> <ul class="dropdown dropdown-menu dropdown-item"> <li class="dropdown dropdown-submenu"> <a href='#'>Test 1</a> <ul class="dropdown dropdown-menu dropdown-item"> <li> <a href='#'>Test 2</a> </li> </ul> </li> </ul> </li> </ul> </li> <li> <a href='#'>Test 3</a> </li> </ul> Thank you R
  19. here is my original html (already posted above) ? <nav class="collapse"> <ul class="nav nav-pills" id="mainNav"> <li class="dropdown"><a class="dropdown-item dropdown-toggle" href="#">Features</a> <ul class="dropdown-menu"> <li class="dropdown-submenu"> <a class="dropdown-item" href="#">Headers</a> <ul class="dropdown-menu"> <li><a class="dropdown-item" href="feature-headers-overview.html">Overview</a></li> </ul> </li> </ul> </li> </ul> </nav> Thank you R
  20. Sorry for beeing so unclear. So the menu doesnt look like it should. The main menu looks ok, but the submenu looks messy. It does not work as in normal html. I guess my classes in code are not in the right place. posting gifs below Looking good: (original HTML) Not looking good (my code) I hope Im making more sense now Thank you R
  21. Hello, Im kinda lost here, can't make it work, what am I doing wrong here. It kinda work but not the way it should it looks messy. HTML: <nav class="collapse"> <ul class="nav nav-pills" id="mainNav"> <li class="dropdown"><a class="dropdown-item dropdown-toggle" href="#">Features</a> <ul class="dropdown-menu"> <li class="dropdown-submenu"> <a class="dropdown-item" href="#">Headers</a> <ul class="dropdown-menu"> <li><a class="dropdown-item" href="feature-headers-overview.html">Overview</a></li> </ul> </li> </ul> </li> </ul> </nav> <?php $menu = $modules->get('MarkupMenuBuilder'); $options = array( 'wrapper_list_type' => 'ul',// ul, ol, nav, div, etc. 'list_type' => 'li',// li, a, span, etc. 'menu_css_id' => 'mainNav',// a CSS ID for the menu 'menu_css_class' => 'nav nav-pills',// a CSS Class for the menu 'submenu_css_class' => 'dropdown dropdown-menu dropdown-item',// CSS Class for sub-menus 'has_children_class' => 'dropdown dropdown-submenu',// CSS Class for any menu item that has children 'first_class'=>'',// CSS Class for the first item in 'last_class' => '', 'current_class' => 'active', 'default_title' => 0,// 0=show saved titles;1=show actual/current titles 'include_children' => 4,// show 'natural' MB non-native descendant items as part of navigation 'm_max_level' => 5,// how deep to fetch 'include_children' 'current_class_level' => 1,// how high up the ancestral tree to apply 'current_class' 'default_class' => '',// a CSS class to apply to all menu items ); echo $menu->render(1022, $options); ?> This is the best combination I could found that doesn't look totaly broken. Any help appreciated thank you R
  22. Hello, Im having some problems importing dates field with csv file. I need to import around 600 events from old drupal 6 site and all the fields are working great eccept date field it won't import it. Not sure what I need to do to make it work here. I tried to change the output format in PW (details tab) and (input tab), but can't make it work. What am I missing here or what am I doing wrong. First two rows of csv looks like this (fields and date field) what do I need to do to make it work. Thank you R
  23. if I remove everything (<a href .... >and <p>) under source it works, but when I paste the same plain URL directly in ckeditor it doesnt, just show url in frontend (it gives the <a href ...> around it).
×
×
  • Create New...