floridaDev Posted November 17, 2016 Share Posted November 17, 2016 Hello I have parent pages that have thousands of child pages (1k-3k pages). On my template page I have 15 query's that look like the following: <ul> <?php $id = $page->id; $pid = $page->parent->id; $locationData = $page->get("LocationData"); $pgType = $page->get("PageType"); $pbPages17 = $pages->find("parent=$id, id!=$id, PageType=E4,start=850,limit=50"); foreach($pbPages17 as $pbPages17) { ?> <li><a href="<?php echo $pbPages17->url; ?>"><?php echo $pbPages17->get("LocationData");?></a></li> <?php } ?> </ul> I'm concerned the way I'm calling these child pages are slowing down the page that their listed on. Is there a better way of doing so? Thanks Link to comment Share on other sites More sharing options...
flydev Posted November 17, 2016 Share Posted November 17, 2016 Hi, in before better answer, check this small thread from yesterday : 2 Link to comment Share on other sites More sharing options...
AndZyk Posted November 17, 2016 Share Posted November 17, 2016 Hello @floridaDev, if you try to find thousands of pages, have a closer look at the findMany-function. Also can PHP7 boost your performance significantly, if its available for you. Regards, Andreas 2 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now