Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
#157 2014-08-09 23:27:14
- els
- Moderator
- From: The Netherlands
- Registered: 2004-06-06
- Posts: 7,458
Re: stm_article_order: Arbitrary sort order for your articles
RedFox wrote #282769:
I don’t think so, Els. I just wondered if it would be possible to rearrange (drag and drop) articles in a specific categorie …
Ah, misunderstood ;)
Offline
#158 2014-12-15 11:15:56
Re: stm_article_order: Arbitrary sort order for your articles
On this site (under contruction) > mariaberkhout.nl/new … the plug-in does its job nicely on ’2006-2014’ (section). There the order of articles is the same as the order of the thumbnails on the landing page.
<txp:if_individual_article>
<section class="row narrow" role="main">
<div class="large-12 columns">
<txp:article form="single_notitle" limit="1" />
</div>
</section>
<txp:else />
<section class="row wide" role="main">
<div class="large-12 columns">
<txp:article form="single_onlyimage" wraptag="ul" class="small-block-grid-2 medium-block-grid-3 large-block-grid-4" break="li" limit="24" sort="position asc" />
</div>
</section>
</txp:if_individual_article>
The strange thing is that the plugin doesn’t work on the other two sections (‘1984-1993’, ’1994-2005’). Same code, same forms, etc. My brains are boiling. Any help is appreciated.
[edit]
Section ’1994-2005’ is now working too … !? … I’ve done nothing … I suppose it’s server/plugin magic.
[edit]
It’s almost Christmas … let it snow … :)
Last edited by RedFox (2014-12-15 21:19:06)
Offline
#159 2014-12-15 22:02:59
- uli
- Moderator
- From: Cologne
- Registered: 2006-08-15
- Posts: 4,311
Re: stm_article_order: Arbitrary sort order for your articles
You will have thought of caches, and you will have checked the “section x uses page y” settings. Have you checked the results of a sorting step in phpmysql or the like? Also think of the cache there, BTW.
Edit: Ah, you seem to have edited several times, and now they’re all working, right?
Last edited by uli (2014-12-15 22:05:56)
In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links
Offline
#160 2014-12-15 23:24:08
Re: stm_article_order: Arbitrary sort order for your articles
uli wrote #286604:
Edit: Ah, you seem to have edited several times, and now they’re all working, right?
No @uli … section “1984-1993” isn’t working properly … I will check tomorrow again … maybe there are some gnomes helping me when I’m asleep … ;-)
Last edited by RedFox (2014-12-15 23:24:57)
Offline
#161 2014-12-16 15:21:34
Re: stm_article_order: Arbitrary sort order for your articles
uli wrote #286604:
Have you checked the results of a sorting step in phpmysql or the like? Also think of the cache there, BTW.
I do know how to repair the tables of a (the) database … what I’ve done … but that’s all. ‘Sorting’ … ‘Cache’ … !?
Offline
#162 2014-12-16 15:44:47
- uli
- Moderator
- From: Cologne
- Registered: 2006-08-15
- Posts: 4,311
Re: stm_article_order: Arbitrary sort order for your articles
RedFox wrote #286637:
‘Sorting’
In phpMyAdmin you open the textpattern table in order to see the values for position. Leave it open. Switch over to the stm panel, do some sorting/ordering/arranging there (preferably in the section that doesn’t seem to work), save the altered order. Now open a new browser tab, visit the textpattern table in phpMyAdmin again and compare the values for position of the articles you worked on previously. If they’re still the same you might still look at the cached version of the page.
‘Cache’
Firefox: When you re-visit the textpattern table, press cmd/ctrl/strg-shift-R or, often better, hold down the shift key while clicking the reload button. For browsers other that FF: please google the procedure. If there are still the same values I’m officially out of ideas.
Last edited by uli (2014-12-16 15:47:47)
In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links
Offline
#163 2014-12-16 18:33:25
Re: stm_article_order: Arbitrary sort order for your articles
Thanks @uli. Did everything you’ve suggested (learned a thing or two … :)) … but at the end it didn’t help. The order of the thumbnails (articles) and the database are the same. The individual articles (prev en next) are not. Pitty.
Maybe I (we) have to look at my tag soup …
On page:
<txp:if_individual_article>
<section class="row narrow" role="main">
<div class="large-12 columns">
<txp:article form="single_notitle" limit="1" />
</div>
</section>
<txp:else />
<section class="row wide" role="main">
<div class="large-12 columns">
<txp:article form="single_onlyimage" wraptag="ul" class="small-block-grid-2 medium-block-grid-3 large-block-grid-4" break="li" limit="24" sort="position asc" />
</div>
</section>
</txp:if_individual_article>
Module “single_notitle”:
<article role="article" itemscope itemtype="http://schema.org/Article">
<div itemprop="articleBody">
<txp:body />
<p class="navigatie"><txp:link_to_prev showalways="1">PREV</txp:link_to_prev> <span>|</span> <a href="<txp:site_url /><txp:section />" title=""><txp:section /></a> <span>|</span> <txp:link_to_next showalways="1">NEXT</txp:link_to_next></p>
</div>
</article>
Module “single_onlyimage”:
<article role="article" itemscope itemtype="http://schema.org/Article">
<div itemprop="articleBody">
<!-- Read me > http://txptips.com/using-images-in-adaptive-design -->
<txp:images><txp:permlink><txp:smd_thumbnail type="thumbnail" /></txp:permlink></txp:images>
</div>
</article>
Last edited by RedFox (2014-12-16 19:03:48)
Offline
#164 2014-12-16 18:49:55
- uli
- Moderator
- From: Cologne
- Registered: 2006-08-15
- Posts: 4,311
Re: stm_article_order: Arbitrary sort order for your articles
RedFox wrote #286647:
The individual articles (prev en next) are not.
Wait. Is the faulty behaviour indicated there, in the quote? Then that’s for the first time you do. And then I’ve yet one more idea, as you’ll need the sorting values in your single article tag for the nav to work.
In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links
Offline
#165 2014-12-16 19:18:01
Re: stm_article_order: Arbitrary sort order for your articles
You mean to do this: <txp:article form="single_notitle" limit="1" sort="position asc" />
?
Sorry, I indeed didn’t mentioned it because I tried it several times before with no result. Eh … wait … let me show what happens then … a random individual page > mariaberkhout.nl/new/1984-1993/39
All pages (nav’s) are the same … all next’s are unlinked and all prev’s work but they don’t follow the order of the thumbnails.
[edit]
Sorry … now (20:26) it’s working like I mentioned above.
Last edited by RedFox (2014-12-16 19:26:50)
Offline
#166 2014-12-16 21:09:40
- uli
- Moderator
- From: Cologne
- Registered: 2006-08-15
- Posts: 4,311
Re: stm_article_order: Arbitrary sort order for your articles
The page linked has no prev/next nav. Is that the problem with the page that you wanted to demonstrate? Not the ordering of articles or the sequence of the articles accessible via the prev/next nav?
RedFox wrote #286650:
Sorry … now (20:26) it’s working like I mentioned above.
Umm, you see me puzzled: Is it working or not? Which “above”? Is your problem the section page or the individual page? Or both? Is your problem still related to the plugin? Totally clueless.
In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links
Offline
#167 2014-12-16 22:19:31
Re: stm_article_order: Arbitrary sort order for your articles
Both. The thumbnails on the landingpage are article images. They have the same order as within the plugin. So far so good. But … the individual articles (with larger images) should have the same order (via prev and next) … but that’s not the case … so you can see. The problem only occurs with section “1984-1993”. The other sections are ok. Totally clueless … ;-)
Offline
#168 2014-12-17 17:38:25
- uli
- Moderator
- From: Cologne
- Registered: 2006-08-15
- Posts: 4,311
Re: stm_article_order: Arbitrary sort order for your articles
1. In order to get to the bottom of the faulty behaviour of that section page: Please add the position value of the articles to the source code by placing <txp:custom_field name="position" />
somewhere inside your list form, either visible or <!--
invisible -->
. I vaguely remember that I once saw articles having the same values for position in one of my websites.
2. As to your prev/next nav: The wiki page for link_to_next says:
[…] can be used […] to return the permanent URL of the next article by posting date.
You might perhaps find the right tool in Oleg’s etc_link_to. And keep the sort="position asc"
part for your single articles.
In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links
Offline