Skip to content
Grav 2.0 is officially stable. Read the announcement →

Community guidelines

Please keep discussions civil and on-topic. Repeated violations may lead to a temporary ban.

General

Can't start working the Related Pages plug-in

plugins

Started by 01K 6 years ago · 1 replies · 478 views
6 years ago

Hello!
Having troubles trying to make working the Related Pages plug-in.
I want to display related pages on each page, but there is no any information...

The page has been translated to Lithuania language, but this doesn't make sense.
The page is running under Gantry 5 framework.

I've this page's structure:

Main services page

TXT
/paslaugos -> default

    First Service
    /paslaugos/krastovaizdzio-projektavimas -> modular

        Second service
        /paslaugos/krastovaizdzio-projektavimas/_intro -> modular/services

    ... 

    N-th Service
    /paslaugos/nth-service -> modular

        Second service
        /paslaugos/nth-service/_intro -> modular/services               

In services.html.twig template I've put this code:

TWIG
{% if config.plugins.relatedpages.enabled and related_pages|length > 0 %}
    <h4>Related Posts</h4>
    {% include 'partials/relatedpages.html.twig' %}
{% endif %}

Plugin's settings:

YAML
enabled: true           
limit: 5                
show_score: true        
score_threshold: 20     
filter:                 
    items:
        @page: /paslaugos
    order:
        by: date        
        dir: desc       
page_in_filter: true    
explicit_pages:
    process: true       
    score: 100          
taxonomy_match:         
    taxonomy: tag       
    taxonomy_taxonomy:
        process: true   
        score_scale:    
            1: 50
            2: 75
            3: 100
    taxonomy_content:
        process: true   
        score_scale:    
            1: 20
            2: 30
            3: 45
            4: 60
            5: 70
            6: 80
            7: 90
            8: 100
content_match:          
    process: false      

And this is debug info:

JS
Grav v1.6.26
infoEnvironment Name: localhost
infoConfiguration reloaded and cached.
infoGantry theme g5_helium selected
infoCache: [false] Setting: [auto] Driver: [file]
infoRelatedPages Plugin cache miss. Rebuilding...
infoSelecting outline (rules, matches, scores):
info

array:3 [
  "page" => array:1 [
    0 => array:1 [
      "paslaugos/krastovaizdzio-projektavimas" => 3
    ]
  ]
  "language" => array:1 [
    0 => array:1 [
      "lt" => 1
    ]
  ]
  "type" => array:1 [
    0 => array:1 [
      "modular" => 2
    ]
  ]
]

info[]
info[]
infoUsing Gantry outline default
infoRouted to page /services/krastovaizdzio-projektavimas (type: modular)
debugCaching particle logo-9608
debugCaching particle social-3171
debugCaching particle logo-9571
debugCaching particle copyright-1736
debugCaching particle horizontalmenu-9034
debugCaching particle totop-8670
debugCaching particle mobile-menu-5697

Plug-in doesn't acquire any data...

6 years ago

Nobody has tried a similar website structure?

Suggested topics

Topic Participants Replies Views Activity
General · by Jerry Hunt, 4 days ago
2 101 16 hours ago
General · by pamtbaau, 22 hours ago
1 68 21 hours ago
General · by Andy Miller, 1 day ago
0 53 1 day ago
General · by Marcel, 12 months ago
6 361 5 days ago
General · by Duc , 6 days ago
3 49 6 days ago