Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#16 2018-04-13 18:50:42

etc
Developer
Registered: 2010-11-11
Posts: 5,677
Website GitHub

Re: Sticky article does not show content

I understand that putting two <txp:article /> tags for individual articles can be counter intuitive. Should we patch it, or are there situations when you don’t want to show individual sticky articles content?

Offline

#17 2018-04-13 20:07:24

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 5,202
Website GitHub

Re: Sticky article does not show content

etc wrote #311029:

I understand that putting two <txp:article /> tags for individual articles can be counter intuitive. Should we patch it, or are there situations when you don’t want to show individual sticky articles content?

It has (almost) always been that way and we’ve grown used to it. It looks counterintuitive but does actually make sense.

At some point – many years ago – you used to be able to do status="live, sticky" or status="4,5" but it was taken out. I don’t think any other statuses/statii were allowed, so plugins emerged to list pending or draft articles. I forget why but there was a reason why the devs at the time were unwilling to reinstate it. I think it had to do with people like me not using sticky articles for what they meant to be used ;-) But there were times, like in search results, when it was useful to have the results from live and sticky articles all in one query together.


TXP Builders – finely-crafted code, design and txp

Offline

#18 2018-04-13 20:25:03

etc
Developer
Registered: 2010-11-11
Posts: 5,677
Website GitHub

Re: Sticky article does not show content

jakob wrote #311031:

It has (almost) always been that way and we’ve grown used to it. It looks counterintuitive but does actually make sense.

I agree.

But there were times, like in search results, when it was useful to have the results from live and sticky articles all in one query together.

You still can if searchsticky preference is true.

Offline

#19 2018-04-14 02:02:44

Summer
Member
Registered: 2018-01-29
Posts: 60

Re: Sticky article does not show content

jakob wrote #311031:
etc wrote #311032:
colak wrote #311019:

ummm… What I mean is how to display the entire content of the sticky article in the default article details page.
This default article details page:/forms/article/default.txp

<article class="article" itemprop="blogPost" itemscope itemtype="https://schema.org/BlogPosting">
   <meta itemprop="mainEntityOfPage" content="<txp:permlink />">
   <txp:if_individual_article>
       <h1 itemprop="headline">
            <txp:title />
        </h1>
    <txp:else />
       ...
       ...
</article>...

Edited: Textile — uli

Last edited by Summer (2018-04-14 02:31:25)

Offline

#20 2018-04-14 10:14:04

etc
Developer
Registered: 2010-11-11
Posts: 5,677
Website GitHub

Re: Sticky article does not show content

Summer wrote #311033:

What I mean is how to display the entire content of the sticky article in the default article details page.
This default article details page:/forms/article/default.txp

In the “official” 4.7 theme you need to modify archive page, appending

<txp:article status="sticky" />

just before <txp:article /> in the else part of <txp:if_article_list /> tag. The theme itself does not use sticky articles, so the first question to ask is how you want to use them?

Offline

#21 2018-04-14 10:45:51

Summer
Member
Registered: 2018-01-29
Posts: 60

Re: Sticky article does not show content

etc wrote #311037:
jakob wrote #311031:
colak wrote #311019:

Thanks everyone, I understand how to solve it.

Offline

#22 2018-04-14 21:27:59

gaekwad
Server grease monkey
From: People's Republic of Cornwall
Registered: 2005-11-19
Posts: 4,731
GitHub

Re: Sticky article does not show content

jakob wrote #311031:

At some point – many years ago – you used to be able to do status="live, sticky" or status="4,5" but it was taken out.

Some more background on that – github.com/textpattern/textpattern/issues/177#issuecomment-356296263

Offline

#23 2018-04-15 13:36:28

etc
Developer
Registered: 2010-11-11
Posts: 5,677
Website GitHub

Re: Sticky article does not show content

gaekwad wrote #311047:

Some more background on that – github.com/textpattern/textpattern/issues/177#issuecomment-356296263

Thanks for the recall, will take a look.

Offline

Board footer

Powered by FluxBB