Jump to content
ryan

PW 3.0.107 – Core updates

Recommended Posts

This week we've got a lot of updates on our core dev branch, including new features, issue resolutions and more. For starters, we've added support for making the Trash and Restore features available to non-superusers, along with related improvements. Plus we've got several new useful and interesting page traversal methods and properties added to our $page API.

https://processwire.com/blog/posts/processwire-3.0.107-core-updates/

  • Like 15

Share this post


Link to post
Share on other sites

Thank you! The new "What pages point to this one?" feature looks really useful.

Share this post


Link to post
Share on other sites

$page->references() is a great addition - I can immediately see it being use for tagging systems.

I would like to now if it is, or maybe will eventually be, possible to use 'references' within a selector.

For example:

// Find all the tags and sort them by the number of references to each tag.
// When looping through the results, the tags are in order of the most references (ie, most used tags) first.
$all_tags = $pages->find('template=tag, sort=-references.count');

 

  • Like 1

Share this post


Link to post
Share on other sites

repost of my comment from the blogpost:

Great additions! Thank you!
One question for $page->references():
If a page is referenced from a repeater or similar fields, does it return the repeater page or the the „for page“ (the page where the repeater is used)?

Thanks!

Share this post


Link to post
Share on other sites
On 7/1/2018 at 11:36 AM, LMD said:

I would like to now if it is, or maybe will eventually be, possible to use 'references' within a selector.

I would like to know this too. For example in my case I would like to sort pages by the number of their references. 🙂

It would be great, if you could to that or has somebody please a hint for me how to do this otherwise?

Regards, Andreas

Share this post


Link to post
Share on other sites
14 hours ago, AndZyk said:

For example in my case I would like to sort pages by the number of their references.

A recent answer to a similar question:

 

  • Like 2

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...