Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2013-02-22 10:05:13

jstubbs
Moderator
From: Hong Kong
Registered: 2004-12-13
Posts: 2,395
Website

txp:popup improvements

Would it be possible to add txp:author support to the <txp:popup /> tag? Currently it only supports categories and sections as far as I can see.

Offline

#2 2013-02-24 09:55:39

jstubbs
Moderator
From: Hong Kong
Registered: 2004-12-13
Posts: 2,395
Website

Re: txp:popup improvements

Additionally, it would be good to be able to pull categories from parent categories instead of just all categories at the moment.

Offline

#3 2013-02-24 12:44:07

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,012
Website GitHub Mastodon Twitter

Re: txp:popup improvements

Although my sites don’t have other author privileges, I can see how this is a good idea

+1


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#4 2013-02-24 13:56:34

jstubbs
Moderator
From: Hong Kong
Registered: 2004-12-13
Posts: 2,395
Website

Re: txp:popup improvements

Crossing my fingers – this is the for updated TXP Tips site which has easy to navigate author selects!

Offline

#5 2013-02-24 14:50:25

Gocom
Developer Emeritus
From: Helsinki, Finland
Registered: 2006-07-14
Posts: 4,533
Website

Re: txp:popup improvements

The popup tag doesn’t really have any real value, it being a limited widtget. It merely generates a select field without any options for customization. You don’t need it for that, and you are better off without using it to be honest. Unless you really want that inline JavaScript and hard-coded markup structure.

I would be inclined to keep it intact for rest of its life, only giving it bug fixes if needed. Instead maybe someday we get a real set of tags that can be used to extra author data. Let’s not bug the old geezer. He is tired. The tag is from the olden days.

jstubbs wrote:

Additionally, it would be good to be able to pull categories from parent categories instead of just all categories at the moment.

Along the lines of:

<select name="c">
	<txp:category_list parent="foobar" break="">
		<option value="<txp:category />"><txp:category title="1" /></option>
	</txp:category_list>
</select>

Last edited by Gocom (2013-02-24 14:52:06)

Offline

#6 2013-02-24 14:56:57

jstubbs
Moderator
From: Hong Kong
Registered: 2004-12-13
Posts: 2,395
Website

Re: txp:popup improvements

Gocom wrote:

Let’s not bug the old geezer. He is tired. The tag is from the olden days.

Ha ha! OK, we leave the old ba**ard on his deathbed…! Thanks for the code example, I’ll just construct a list based on my needs. More love for authors would be good though. I’m giving TXP Tips a small makeover to include author support and it is a bit thin on the ground..

Offline

#7 2013-02-25 01:08:55

jstubbs
Moderator
From: Hong Kong
Registered: 2004-12-13
Posts: 2,395
Website

Re: txp:popup improvements

Jukka, any plans to have an author_list tag? Like for categories/sections etc?

Offline

#8 2013-02-25 02:21:28

Gocom
Developer Emeritus
From: Helsinki, Finland
Registered: 2006-07-14
Posts: 4,533
Website

Re: txp:popup improvements

jstubbs wrote:

Jukka, any plans to have an author_list tag? Like for categories/sections etc?

Yes. <txp:authors/> is part of the core as of r5328. E.g.

<txp:authors group="publisher, managing_editor" wraptag="ul" break="li">
	<txp:author link="1" />
	<txp:author_email />
</txp:authors>

Last edited by Gocom (2013-02-25 02:21:37)

Offline

#9 2013-02-25 03:30:13

jstubbs
Moderator
From: Hong Kong
Registered: 2004-12-13
Posts: 2,395
Website

Re: txp:popup improvements

Thats so cool Jukka! Thanks! Just to clarify – I need something like:

<select name="a">
	<txp:author parent="foobar" break="">
		<option value="<txp:author />"><txp:author link="1" /></option>
	</txp:author>
</select>

Am I to assume that <txp:author /> is the equivalent of <txp:category_list />?

Offline

#10 2013-02-25 03:33:19

jstubbs
Moderator
From: Hong Kong
Registered: 2004-12-13
Posts: 2,395
Website

Re: txp:popup improvements

And – is that changeset in the current nightly? If so I’ll install it now to test.

Offline

#11 2013-02-25 04:36:16

Gocom
Developer Emeritus
From: Helsinki, Finland
Registered: 2006-07-14
Posts: 4,533
Website

Re: txp:popup improvements

jstubbs wrote:

Thats so cool Jukka! Thanks! Just to clarify – I need something like:

Something like that, but with the proper tag name, attributes and a HTTP query parameter. If you want a select field, e.g.

<select name="author">
	<txp:authors sort="realname asc">
		<option value="<txp:author />"><txp:author /></option>
	</txp:authors>
</select>

Am I to assume that <txp:author /> is the equivalent of <txp:category_list />?

Yes. It works same as any other list tag. Will have different attributes and feature set of course.

And – is that changeset in the current nightly? If so I’ll install it now to test.

I suppose it will be included in the tomorrow’s nightly. The nightlies are packaged at every midnight UTC. Assuming that the packaging doesn’t fail on the next packaging event — the repository format doesn’t change or anything.

Last edited by Gocom (2013-02-25 04:39:47)

Offline

Board footer

Powered by FluxBB