Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2004-08-20 16:19:47

osei
Plugin Author
From: Stockholm, Sweden
Registered: 2004-07-01
Posts: 178
Website

[archived] glx_num_images

Notice: This thread is archived, this plugin is no longer available.

**********************************************************

A simple plugin that counts how many images there is in an article or an category or just total number of images uploaded to TXP.

Download: glx_image_count
Version: 0.2

More info here

glx_image_count
Counts images in an article or category

Parameters

  • category

If no category is set it return all images in the current article (Use this in a form).
<code>
<txp:glx_image_count />
<txp:glx_image_count category=“foo” />
</code>

glx_image_count_total
Counts all images uploaded to Textpattern

<code><txp:glx_image_count_total /></code>

Note: this plugin has been renamed to glx_image_count

Last edited by osei (2005-01-14 08:50:32)


Johan Nilsson

Offline

#2 2005-01-14 08:53:08

osei
Plugin Author
From: Stockholm, Sweden
Registered: 2004-07-01
Posts: 178
Website

Re: [archived] glx_num_images

New version 0.2

  • Rewrote the whole plugin
  • Renamed the plugin to glx_image_count
  • The plugin now works with image plugins too like the glx_image plugin.
  • works better

Last edited by osei (2005-01-14 08:54:38)


Johan Nilsson

Offline

#3 2005-09-02 13:37:28

june
Member
Registered: 2005-06-02
Posts: 47

Re: [archived] glx_num_images

Hi,

I am using the set up a thumbnail gallery tutorial. It says to put your tag:
<code>
<txp:glx_image_count />
</code>

…in the form that formats how all the galleries are listed. Well, like you said,
if I don’t specify a category it counts the images in that article. Well the article the tag is in is a list of galleries, so it of course says zero images. But I
can’t add a category to the tag because each gallery listed has a different image category.

In other words I want each gallery listed to display its unique number of pictures. So could you possibly modify the plugin to grab the name in category one instead of having to type the category name?

for instance:
<code>
<txp:category1 />
</code>

…grabs the name of the category.

…or maybe I’m just missing something from code. Any help would be great.

thanks.

june

Offline

#4 2006-01-07 00:59:04

alexm
New Member
Registered: 2005-11-27
Posts: 7

Re: [archived] glx_num_images

The link is no longer working. Is it because there is something that now replaces this plugin?

Offline

#5 2006-01-07 03:29:05

thebombsite
Plugin Author
From: Exmouth, England
Registered: 2004-08-24
Posts: 3,251
Website

Re: [archived] glx_num_images

Click the “here” link. Johan is no longer working on TXP so I don’t know that you will receive an answer to any questions unless someone has adopted this plug-in.


Stuart – The BombsiteProText ThemesTextgarden

In a Time of Universal Deceit
Telling the Truth is Revolutionary.

Offline

#6 2006-01-11 21:19:41

rloaderro
Plugin Author
From: Costa Rica
Registered: 2006-01-05
Posts: 190
Website

Re: [archived] glx_num_images

I ran into this same problem – old I know, but couldn’t find the fix anywhere so here it is:

Admin > Plugins > glx_image_count > Edit

1. Find the line: $where = (empty($category)) ? “” : “category = ‘”.$category.”’”;
2. Replace with: $where = “category = ‘article-”.$thisarticle[“thisid”].”’”;

This will work now if you are using the gallery tutorial here

june wrote:
I am using the set up a thumbnail gallery tutorial. It says to put your tag:

&#60;code>
&#60;txp:glx_image_count />
&#60;/code>

In other words I want each gallery listed to display its unique number of pictures. So could you possibly modify the plugin to grab the name in category one instead of having to type the category name?


Travel Atlas * Org | Start Somewhere

Offline

#7 2006-02-19 05:14:21

DespairsWindow
New Member
Registered: 2005-05-22
Posts: 6

Re: [archived] glx_num_images

Does anyone have a backup of this plugin, the link/website is completely gone.

thanks

Offline

#8 2006-02-19 06:24:57

nardo
Member
From: tuvalahiti
Registered: 2004-04-22
Posts: 741

Re: [archived] glx_num_images

was looking for this one too – a good counting plugin might be one that counted all articles, all images and all authors on a site…

Offline

#9 2006-02-19 10:08:08

Skubidu
Plugin Author
Registered: 2004-10-23
Posts: 611
Website

Re: [archived] glx_num_images

Offline

#10 2006-02-19 17:08:37

DespairsWindow
New Member
Registered: 2005-05-22
Posts: 6

Re: [archived] glx_num_images

Thanks :D, that was so not working last night!

Offline

Board footer

Powered by FluxBB