mel47 Posted November 13, 2016 Share Posted November 13, 2016 Hi Have a problem for searching pages. I have member template with 2 fields : title (example value : Mélanie Tremblay) and alias (example value : Mélanie A. Tremblay) I want to search for either those fields $publi = $pages->find("template=publication, categ_publi=$c, author~={$page->title}|{$page->alias}, sort=-year"); This selector works if both fields are filled. But if I only have title, I get an error: '~=' is not implemented in FieldtypePage. If I put only author={$page->title}|{$page->alias}, it found results only if alias field is empty. What syntax I should use? Thanks! Link to comment Share on other sites More sharing options...
blynx Posted November 13, 2016 Share Posted November 13, 2016 Mh, what kind of field is author? If thats a Page field, try author.title=... Also, what FieldType is alias? I assume Text? 2 Link to comment Share on other sites More sharing options...
mel47 Posted November 14, 2016 Author Share Posted November 14, 2016 Oh, why I don't know things so simple... Thanks! 1 Link to comment Share on other sites More sharing options...
blynx Posted November 14, 2016 Share Posted November 14, 2016 All the time 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