Jump to content

sreeb

Members
  • Posts

    26
  • Joined

  • Last visited

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

sreeb's Achievements

Jr. Member

Jr. Member (3/6)

3

Reputation

  1. One more question. We have Pro Cache enabled on our website. Expect for the treefilter, because this is send trought Ajax Post. Is it possible to use procache when there is a post request?
  2. Hi @adrian the one to generate an sql query form a pw selector
  3. hi @adrian, how can i run that snippet?
  4. No if it makes the speed much faster, the countlabels can go away. I will ask to our developers to look at this. Maby this give them some information. Is Varnish caching a good sollution?
  5. Thanks @bernhard. I just send you an PM.
  6. Unfortunately, php7 does not give the desired speed gain. Do you have experience with Varnish Cache and PW? Also extra server capacity did not do the job. It looks like its a code technical problem. As i can see, all search query's are set as an URL, like: https://www.vdberk.com/trees/?soil-type=1147&sort=0 https://www.vdberk.com/trees/?soil-type=1147&soil-moisture=1157&sort=0 https://www.vdberk.com/trees/?soil-type=1147&soil-moisture=1157&resistance=1189&sort=0 Etc.etc. The page will not be change very often. they are quite static. It looks like below. But i'am not sure. Unfortainly our developers cant find a sollution, so this is my last hope;) public function getTreesSelector($filterParams){ $selector = array('template=tree-detail'); foreach ($filterParams as $key => $value) { if(trim($value) != ""){ $key = $this->getFilterKey($key); switch ($key) { case "key": $selector[] = "title|tree_specific_name|tree_family|tree_subfamily%=".urldecode($value); break;
  7. This looks very cool. thanks, i will check it.
  8. Wow, thanks a lot for al the suggets. I will send this to our developers, so they can expertmate with it. @Zeka, do you have an example website so i can see the search?
  9. Cool thanks @abdus, Is processwire and the modules like procache and formbuilder etc ready for PHP 7. Or is this a heel of a job to make it work on php7? We have processwire 3.0. Are there any other sollution to make this huge database faster?
  10. Hi Everyone, Since a couple of months, we have our new website live with processwire as CMS system. In this website there is a huge database (1900+ trees), wich can be found with different filters. Take a look at www.vdberk.com/trees. The website does not to be seen very fast when you select a couple of filters. Every time there is a delay between 3-5 seconds. Now we are migrate the website to another sever, with more preformance. So we hope this give us some timeprofits. Does anyone have any kind of suggest, to make this filter faster. Now the website is on PHP5.6, is php7 better? Can this make a different? We used ProCache already. Thanks in advance
  11. Thanks, is this something i can setup in procache or processwire? Or must i do this in the HTaccess? Edit: i found it on Setup > template
  12. Hi, when i visited an non existing page on my website i get a response code 200 instead of 404. For example https://www.tbgs.nl/schoorsteen/hfskdhfksjdf -> page not excist but he loads https://www.tbgs.nl/schoorsteen and gives an 200 responscode https://www.tbgs.nl/ldsjflasjdfs -> Page not excist and gives 404 code. Does anyone know whats wrong with the childern URL? Why is he not sending a 404 code? Thanks a lot
  13. @Robin S Thanks a lot, this works for me. So i learned somthing on a mondayevening:) Thanks!!!
  14. Hi, I have a very strange problem. I want to use a inline css background, so i made this code: <?php foreach ($page->home_kennisbank as $block) { echo "<div class='col-md-".$block->front_block_class."'>"; echo "<a href='".$block->url."' style='background: url('".$block->front_block_img->url."') no-repeat bottom center; background-size: cover;'>"; echo "<div class='vertical-middle dark center' style='position: absolute; top: 50%; width: 100%; padding-top: 0px; padding-bottom: 0px; margin-top: -34px;'>"; echo "<div class='heading-block nomargin noborder'>"; echo "<h3 class='capitalize t500'>".$block->title."</h3>"; echo "<span style='margin-top: 5px; font-size: 17px;'>".$block->front_block_subtitle."</span></div></div></a></div>"; } ?> For a strange reason the background url will be displayed like this: (chrome developers tool) <a href="/daken/dak-lekkage/" style="background: url(" site="" assets="" files="" 1056="" 03-lekkage-dakkapel-02.jpg')="" no-repeat="" bottom="" center;="" background-size:="" cover;'=""> i looks like he didn't displayed the slashed. Another strange thing. When i look in the source it is displayed correct: <a href='/daken/dak-lekkage/' style='background: url('/site/assets/files/1056/03-lekkage-dakkapel-02.jpg') no-repeat bottom center; background-size: cover;'> Does anyone understand this why this is happening. The URL contains also "slashes". And this one is displayed correct. Why not the background image url?? Thanks in advance.
  15. Hi everyone, I have a question, i'm building a mega menu and i have one little question about ow to use the foreach function for the childeren of the childeren of the root. As in Home Sollution Submenu 1 Link 1 Link 2 Submenu 2 Link 1 Link 2 Etc etc.. I have used the folowing code as a hook. The foreach function does not do the job:( The foreach function must be set for the childeren of the child of the root. Can anyone help me? function customNavItems(HookEvent $event){ $item = $event->arguments('page'); $item2 = $event->arguments('Werkzaamheden'); if($item->title == 'Werkzaamheden'){ $out .= '<li class="mega-menu sub-menu"><a href="#" class="sf-with-ul"><div>'.$item->get("title|name").'</div></a>'; $out .= ' <div class="mega-menu-content style-2 clearfix" style="display: none; width: 1628px;">'; foreach ($rootPage as $children) { $out .= ' <ul class="mega-menu-column col-md-3"> <li class="mega-menu-title"> <div style="text-transform: uppercase!important;font-size:1.1em; margin:20px 0;"> <strong>Test 1</strong> </div> <ul>'; $out .= ' <li><a href="#"><div>sub1</div></a></li>'; $out .= ' <li><a href="#"><div>sub2</div></a></li>'; $out .= ' <li><a href="#"><div>sub3</div></a></li>'; $out .= ' </ul>'; $out .= ' </li>'; $out .= ' </ul>'; } $out .= ' </div>'; $out .= '</li>'; //build the normal li item output or change the item with id 1068 to your needs //add new items that aren't in the normal pagetree or add megamenu items //....do what you want! //$out = '<a href="'.$item->get("url").'">'.$item->get("title|name").'</a>'; $event->return = $out; } } Just found the solution with "foreach($item->children as $child) {"
×
×
  • Create New...