Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#181 2015-10-09 17:47:25

uli
Moderator
From: Cologne
Registered: 2006-08-15
Posts: 4,310

Re: stm_article_order: Arbitrary sort order for your articles

Thanks, Claire.
Although I can read PHP to a certain degree of complexity, I can’t code myself and so have to run tests against each new line.


In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links

Offline

#182 2015-10-09 18:59:21

CeBe
Plugin Author
From: Caen - Fr
Registered: 2010-06-25
Posts: 345
Website

Re: stm_article_order: Arbitrary sort order for your articles

uli wrote #295556:

Thanks, Claire.

You’re welcome.

Although I can read PHP to a certain degree of complexity, I can’t code myself and so have to run tests against each new line.

Let’s call it learning process :)

Offline

#183 2016-05-07 14:36:36

uli
Moderator
From: Cologne
Registered: 2006-08-15
Posts: 4,310

Re: stm_article_order: Arbitrary sort order for your articles

This plugin is broken in TXP 4.6. For more details see this post.


In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links

Offline

#184 2016-06-06 14:32:05

uli
Moderator
From: Cologne
Registered: 2006-08-15
Posts: 4,310

Re: stm_article_order: Arbitrary sort order for your articles

GugUser wrote #299529:

Do you work on this?

The repairs and (re-)integrations I mentioned here and in the other thread are done. I had to postpone one small thing that accidentally got lost: Articles dropped beneath the list aren’t labeled any longer with a text notice (warning color remained, though). But as it has become difficult to miss the lists I can as well publish the plugin for testing before that repair.

The plugin now supports textpacks (German and English comprised already). As a consequence the installation has become a two steps process.

The layout has become wider which gives the opportunity to show article status labels (live, hidden etc). And yes, no restrictions on article status: I’ve found it important to sort articles before going public. Articles other than live and sticky ones are displayed with dimmed opacity to make them distinguishable from published ones.

When you set up a link on the public side from a single article to stm_article_order (http://YOUR_SITE/textpattern/index.php?event=stm_article_order#article_43), you’ll find closed section panels opened when you arrive and the target article marked.

Nicer animations, a more column-like layout when thumbnails are displayed, a green Textpattern style saving message instead of the top of page bar: that probably completes the list of changes.

See this as a test stage and please report back. Thanks, and have fun!

Plugin

ENGLISH

DEUTSCH

ESPAGNOL

FRANÇAIS

Last edited by uli (2016-06-07 13:27:38)


In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links

Offline

#185 2016-06-06 16:29:49

michaelkpate
Moderator
From: Avon Park, FL
Registered: 2004-02-24
Posts: 1,379
Website GitHub Mastodon

Re: stm_article_order: Arbitrary sort order for your articles

I had never tried this before (and I can’t figure out how to install the Textpack) but I got quite a page of errors when I navigated to Presentation|Artikelreihenfolge

http://pastebin.com/2hNufxVx

The drag & drop portion appears to be working, though.

Offline

#186 2016-06-06 16:50:28

uli
Moderator
From: Cologne
Registered: 2006-08-15
Posts: 4,310

Re: stm_article_order: Arbitrary sort order for your articles

Hi Michael, thanks for trying out the plugin. You install textpacks on Admin > Languages below the list of languages. Just paste the textpack into the textarea and press Upload. Can you try that, please, before anything further? Maybe the errors are induced by my unorthodox coding around gTxt strings. Thanks.


In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links

Offline

#187 2016-06-06 17:14:37

michaelkpate
Moderator
From: Avon Park, FL
Registered: 2004-02-24
Posts: 1,379
Website GitHub Mastodon

Re: stm_article_order: Arbitrary sort order for your articles

Uli,

I uploaded the Textpack and then realized I had to switch to British English. Presentation|Article Order is now correct but under Extensions I see stm_ao-Sektionen. All the text is now in English.

Unfortunately, the errors on “Presentation|Article Order” are still appearing as they did earlier. I checked Content|Images and I haven’t uploaded any. Do you think that might be the issue?

Offline

#188 2016-06-06 17:14:57

GugUser
Member
From: Quito (Ecuador)
Registered: 2007-12-16
Posts: 1,473

Re: stm_article_order: Arbitrary sort order for your articles

uli it’s amazing that you have worked on it. Thank you very much.

Why not call it uli_article_order and give him a new forum topic? It’s a bit like a new beginning.

A little mismatch: The bottom save button don’t work with rah_knots.

I not remember if I changed the following in my own version and become accustomed, or if this is new: Article order is in the Presentation tab, I had it in the Content tab. What is better an why? And how are the rights to the access?

Offline

#189 2016-06-06 17:40:13

GugUser
Member
From: Quito (Ecuador)
Registered: 2007-12-16
Posts: 1,473

Re: stm_article_order: Arbitrary sort order for your articles

Another incorrect behavior: After dragging an article to another position or to an other section and save, the tab navigation no longer works.

Last edited by GugUser (2016-06-06 17:40:54)

Offline

#190 2016-06-06 18:15:50

GugUser
Member
From: Quito (Ecuador)
Registered: 2007-12-16
Posts: 1,473

Re: stm_article_order: Arbitrary sort order for your articles

Textpack for Spanish:

#@stm_ao
#@language es-es
stm_ao_article_order => Orden de artículos
stm_ao_article_order_saved => Orden de artículos guardado.
stm_ao_edit_article => Editar artículo
stm_ao_edit_image => Editar imagen
stm_ao_hide_articles => Ocultar artículos
stm_ao_hide_images => Ocultar imágenes
stm_ao_hints_for_using => Arrastre un artículo hacia una nueva posición y pulse “guardar”.<br/>Al arrastrar a un artículo hacia una nueva sección lo asigna a esa nueva sección.<br/>Puede arrastrar un sólo artículo a la vez.
stm_ao_it_s_the_one_above => ¡ES EL ARTÍCULO DE ARRIBA!
stm_ao_oops_push_it_please => ¡UPS! ¡EMPÚJELO POR FAVOR! ENCONTRARÁ AL ARTÍCULO AL TOPE DE LA PÁGINA.
stm_ao_optional_warnings => En caso de que deje “caer” a un artículo fuera de la lista, lo encontrará al final de la página, resaltado en color naranja.
stm_ao_prefs_h1 => Secciones en stm_article_order
stm_ao_prefs_hint => Marque las secciones que no quiere alistar en el panel “<a href="index.php?event=stm_article_order">Orden de artículos</a>”, por ejemplo ésas<br />que son ordenadas de manera automática de acuerdo a otros criterios y que no pueden<br />ser ordenadas manualmente.
stm_ao_prefs_menuitem => Secciones en stm_ao
stm_ao_prefs_pagetop => Secciones en stm_article_order
stm_ao_save => Guardar
stm_ao_sections_updated => Selección actualizada
stm_ao_show_articles => Mostrar artículos
stm_ao_show_images => Mostrar imágenes
stm_ao_update => Actualizar selección

Last edited by GugUser (2016-06-06 21:04:22)

Offline

#191 2016-06-06 18:17:20

GugUser
Member
From: Quito (Ecuador)
Registered: 2007-12-16
Posts: 1,473

Re: stm_article_order: Arbitrary sort order for your articles

BTW: You should change this line in the Enlish textpack:

stm_ao_prefs_menuitem => stm_ao-Sektionen

Offline

#192 2016-06-06 20:46:34

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 4,734
Website

Re: stm_article_order: Arbitrary sort order for your articles

michaelkpate wrote #299575:

I got quite a page of errors when I navigated to Presentation|Artikelreihenfolge: http://pastebin.com/2hNufxVx

Those all look like the same error happening repeatedly in all cases where there is no article image defined. Find this line:

$noimg = 'no-image ';

and shift it approx. 3 lines further up to before if(is_numeric($article['Image'])){. Currently it is defined in an if clause but is used in the nested else clause, i.e. in mutually exclusive situations.

EDIT: Actually that variable is only ever used once, so you could delete the $noimg… line entirely and instead code the class name straight into the following line (a few lines further on) starting:

$tmp .= '<span class="'.$noimg.'article_title status_'.

by changing it to start:

$tmp .= '<span class="no-image article_title status_'.
uli wrote #299572:

The plugin now supports textpacks (German and English comprised already). As a consequence the installation has become a two steps process.

Hi uli, if I’m not mistaken, you can include the textpacks in the plugin template and avoid the two-step problem. There’s a bit in the php file template that’s produced with a sample text pack commented out:

/** Uncomment me, if you need a textpack
$plugin['textpack'] = <<< EOT
#@admin
#@language en-gb
abc_sample_string => Sample String
abc_one_more => One more
#@language de-de
abc_sample_string => Beispieltext
abc_one_more => Noch einer
EOT;
**/

Insert your textpacks between the EOT elements and remove the comments surrounding them and your textpacks should be included.


TXP Builders – finely-crafted code, design and txp

Offline

Board footer

Powered by FluxBB