Search found 234 matches
- Thu May 23, 2024 11:31 am
- Forum: Modules/Add-Ons
- Topic: NEWS MODULE - different output based on category
- Replies: 15
- Views: 12333
Re: NEWS MODULE - different output based on category
Hello webform, again! Everything works like a charm and your solution is exactly what I was looking for! The only difference in output is minor - text block was aligned left or right, depending on the attached category but it really doesn't matter. Everything looks good and works. Maybe later, when ...
- Thu May 23, 2024 9:53 am
- Forum: Modules/Add-Ons
- Topic: NEWS MODULE - different output based on category
- Replies: 15
- Views: 12333
Re: NEWS MODULE - different output based on category
Hello webform! Thank you for your suggestion. I've been out of town and off grid for awhile and now I'm back so I'll check it out and get back to you with the result. Best regards!
- Fri May 10, 2024 7:57 am
- Forum: Modules/Add-Ons
- Topic: NEWS MODULE - different output based on category
- Replies: 15
- Views: 12333
Re: NEWS MODULE - different output based on category
After many tries and fails I came up with the conclusion I'm not up to this task. It takes deeper knowledge of smarty to get more elegant code. However, my impression is it could be done in template itself without altering CSS. But the only solution I came up with is the one I posted earlier, the on...
- Thu May 09, 2024 1:48 pm
- Forum: Modules/Add-Ons
- Topic: NEWS MODULE - different output based on category
- Replies: 15
- Views: 12333
Re: NEWS MODULE - different output based on category
Hello Dr.CSS!
I have tried but it took a little bit more than that to achieve the same output. I'll give it a few more tries and get back to you. Hopefully, I'll get to more elegant code!
I have tried but it took a little bit more than that to achieve the same output. I'll give it a few more tries and get back to you. Hopefully, I'll get to more elegant code!
- Tue May 07, 2024 1:46 pm
- Forum: Modules/Add-Ons
- Topic: NEWS MODULE - different output based on category
- Replies: 15
- Views: 12333
[SOLVED!] Re: NEWS MODULE - different output based on category
This works! Not the most elegant solution but it works! <!-- Start News Display Template --> {foreach from=$items item=entry} {if $entry->category == 'PressLeft'} <div class="row justify-content-center no-gutters press-black mb-5 mb-lg-0"> <div class="col-lg-6"> {if isset($entry-...
- Tue May 07, 2024 11:53 am
- Forum: Modules/Add-Ons
- Topic: NEWS MODULE - different output based on category
- Replies: 15
- Views: 12333
Re: NEWS MODULE - different output based on category
This is what I came up with and it produced nothing in output but also didn't broke the page... ;D <!-- Start News Display Template --> {foreach from=$items item=entry} {if $category == 'PressLeft'} <div class="row justify-content-center no-gutters press-black mb-5 mb-lg-0"> <div class=&qu...
- Tue May 07, 2024 11:23 am
- Forum: Modules/Add-Ons
- Topic: NEWS MODULE - different output based on category
- Replies: 15
- Views: 12333
Re: NEWS MODULE - different output based on category
Yes, I agree on using less repetitive code but i posted that code snippet only to illustrate the general idea. On the other hand, the more I look at it, the more I think it could actually be very useful even if some extra css work is required later. But if that's correct, I think category should be ...
- Tue May 07, 2024 8:42 am
- Forum: Modules/Add-Ons
- Topic: NEWS MODULE - different output based on category
- Replies: 15
- Views: 12333
Re: NEWS MODULE - different output based on category
Hello Velden! Your suggestion will do just fine too but I can't figure out how to make it work. This is what I have in my Press content page: {news summarytemplate='00_sacb_PRESS_NEWS' category="PressLeft,PressRight"} I have tried and failed to add the second template and it took me to the...
- Tue May 07, 2024 7:28 am
- Forum: Modules/Add-Ons
- Topic: NEWS MODULE - different output based on category
- Replies: 15
- Views: 12333
NEWS MODULE - different output based on category
Hello everyone! I have a question regarding the use of templates and categories in News module. Is it possible to call different templates for different categories? For example: - first news summary post appears in following order: photo on the left, text on the right, category is "PressLeft&qu...
- Tue Nov 15, 2022 8:58 am
- Forum: Modules/Add-Ons
- Topic: News module custom field document format
- Replies: 9
- Views: 2350
Re: News module custom field document format [SOLVED]
Solved the icon problem! Stupid me... I placed "assets" folder in "uploads" instead of "root" so only the path to icon was wrong and I have overseen it!!!
Thank you all for help and advices and best regards!
Thank you all for help and advices and best regards!
- Fri Nov 11, 2022 7:55 pm
- Forum: Modules/Add-Ons
- Topic: News module custom field document format
- Replies: 9
- Views: 2350
Re: News module custom field document format
I was playing around with suggested code and I don't know if this helps but at some point I came up with output as in attached file... So far hovering on text link shows proper path to document and download itself works too. Same thing if one hovers on question mark. It only doesn't show the icon.
- Fri Nov 11, 2022 4:14 pm
- Forum: Modules/Add-Ons
- Topic: News module custom field document format
- Replies: 9
- Views: 2350
Re: News module custom field document format
Should I add this to existing code at some place or replace the part of the code that controls extra fields?
- Fri Nov 11, 2022 2:36 pm
- Forum: Modules/Add-Ons
- Topic: News module custom field document format
- Replies: 9
- Views: 2350
Re: News module custom field document format
Thank you Velden! I have tried your solution and that's exactly what I was looking for! However, there is one tiny problem I wasn't able to solve (guess it's Smarty related): - in frontend there is a question mark instead of icon and output generates "icon_.gif" path (like {$extension} is ...
- Fri Nov 11, 2022 8:14 am
- Forum: Modules/Add-Ons
- Topic: News module custom field document format
- Replies: 9
- Views: 2350
Re: News module custom field document format
Yes, I have noticed that comment but unfortunately I'm not good in Smarty and stuff like that... But I did try to replace "file" with "linkedfile" and came up with - nothing! :-[ And now, as you mentioned, an icon for corresponding document format and text "Download file&quo...
- Thu Nov 10, 2022 2:38 pm
- Forum: Modules/Add-Ons
- Topic: News module custom field document format
- Replies: 9
- Views: 2350
News module custom field document format
Hello everyone! I'd like to ask you if it's possible to add custom fields in News module to contain downloadable documents in doc, xls or pdf format? So far I was able to find out News module does not distinguish different document formats, assuming everything is some kind of image but I'm really no...