Hi all,
I need to make a custom block or function to show an specific article (not the last one) information into a category template. Can you help me with this?
Thanks,
Juan.
One workaround would be:
Use "Announced" Article type for such articles. (the article may not be latest article)
Other articles go in Breaking and typical article types.
Then CREATE CUSTOM BLOCK use filtering on article by "Announced" type and detect category automatically. Include this block where ever you want it on category template
One workaround would be:
Use "Announced" Article type for such articles. (the article may not be latest article)
Other articles go in Breaking and typical article types.
Then CREATE CUSTOM BLOCK use filtering on article by "Announced" type and detect category automatically. Include this block where ever you want it on category template
Hi,
Thanks for think in this approach, but I can't do that because I use the Announced type (and breaking too) for another purposes.
I need another way to do it.
Hi all,
I need to make a custom block or function to show an specific article (not the last one) information into a category template. Can you help me with this?
Thanks,
Juan.
You can make a block and filter by author or you can create a sub category where you can put the special articles and then create a block, choose the subcat as source and insert that block into your template.
You can create a subcat for each category you like to have special articles in it and even filter by author to get more control of your articles.
If those options don't fit your needs, you could be more specific on what you want to do so we can help you.
Regards
You can make a block and filter by author or you can create a sub category where you can put the special articles and then create a block, choose the subcat as source and insert that block into your template.
You can create a subcat for each category you like to have special articles in it and even filter by author to get more control of your articles.
If those options don't fit your needs, you could be more specific on what you want to do so we can help you.
Regards
Hi Bobby,
I simply need to display, at any category template, information (title, picture and description) from a specific article; by example the article ID 4654.
I know the Article ID of all the articles I want to show, but I can't figure how can I write a custom function to retrieve the information and use it at a custom block.
I can't use category, sub-category, author or article type to find those articles because I use all that information.
I only know the article ID.
Hey guys....what I've done is use "Breaking" articles for our own articles, "Typical" for other contributors articles, and "Announced" for things like blogs etc.
In the block management, under "Single Block" you can select what each block is for...for one you'll select "Breaking"...with "Any" selected as the category".......We call this our FEATURED ARTICLE........we do the same with another block, and call it "RECENT ARTICLES".....this makes our most recent article show up as FEATURED, and any other articles will show up under the RECENT block......although they are all the same category, the most recent will show up in one, and the next most recent will show up in the other.
If that won't work for you, you can break the block down by category, and only articles listed under that category will show up in that block.
What you want to do may require using the CMS function
Hey guys....what I've done is use "Breaking" articles for our own articles, "Typical" for other contributors articles, and "Announced" for things like blogs etc.
In the block management, under "Single Block" you can select what each block is for...for one you'll select "Breaking"...with "Any" selected as the category".......We call this our FEATURED ARTICLE........we do the same with another block, and call it "RECENT ARTICLES".....this makes our most recent article show up as FEATURED, and any other articles will show up under the RECENT block......although they are all the same category, the most recent will show up in one, and the next most recent will show up in the other.
If that won't work for you, you can break the block down by category, and only articles listed under that category will show up in that block.
What you want to do may require using the CMS function
Hi Capper,
I have organized our articles in the same way you do. But now I need to make a template showing ten specific articles from many authors, article types and categories.
I know the Article IDs, but I don't know how can I write a custom function to retrieve these articles.
hmmm, gotta a link...maybe if i see your site I can visualize what you want and figure this out.
Off hand, I know there is no way to do this without some toying around with categories and such......one feature I'd like to see PHPCOW have is the ability to have "Related Articles" or something of the sort within the article termplate.
Have you thought about just creating an HTML page and linking it in PHPCOW? (Thats what I did with our "Affiliates" page).
Custom Functions cannot be used in CUSTOM BLOCKS for sure.
There's no way out of the box that you can pull a specific article on any given template. Three article types are the only way to play around with content and blocks.
Other than that, write your own php to pull all that you want from database and then include that php as custom function in template. But from what i understand maintaining this sort of a setup will be a nightmare as i am sure you would also be changing the article id to be displayed very frequently.