Keyword

Item Counter K2

  • Benjamin Neubauer
  • Benjamin Neubauer's Avatar Topic Author
  • Offline
  • New Member
More
12 years 9 months ago #60446 by Benjamin Neubauer
Item Counter K2 was created by Benjamin Neubauer
Hi there,

I searched the internet quite a while now, found some other with the same issue but with no solution yet.

I´m searching for the code snippet the gives me the number of items of a category so I can put it into a text of another item.

For example:

I´m writing an article about something. In the text, i want to mention, that in the category xyz there are already xxx articles. Where do I get this code that dynamically display the number of items in category xyz? I bet this is absolutely simple but I´m just too much of a rooky.

I would so much appreciate if anybody could help me on this!

Kind Regards,

Ben

Please Log in or Create an account to join the conversation.

More
12 years 9 months ago #60447 by william white
Replied by william white on topic Re: Item Counter K2
You will need to create an override
Next you will need to query the table for what you want with code like
docs.joomla.org/How_to_use_the_database_classes_in_your_script
After getting the select statement correct you will need to use the php count command putting the result into a variable and then displaying it in the override where you want it.

Please Log in or Create an account to join the conversation.

  • Benjamin Neubauer
  • Benjamin Neubauer's Avatar Topic Author
  • Offline
  • New Member
More
12 years 8 months ago #60448 by Benjamin Neubauer
Replied by Benjamin Neubauer on topic Re: Item Counter K2
Dear William,

thanks for the quick reply! Due to Christmas and New Year I only found the time now to answer.

To be honest, I think I´m a bit overstrained with your instructions as I´m not so much into php and mysql.

Are there any further tutorials on this issue?

Thanks again,

Ben

Please Log in or Create an account to join the conversation.

More
12 years 8 months ago #60449 by Horváth László
Replied by Horváth László on topic Re: Item Counter K2
BUMP!

I want this too. But I'am not be able to code this myself.
Somebody to help us with this out?
Thank you forwards!

Please Log in or Create an account to join the conversation.


Powered by Kunena Forum