Main
Index
Search
Posts
Who's
Online
Log
In

Home: Discontinued/Classic Products: Article Manager 2:
Templates - removing attachments?

 

 


dimeco
User

Jan 4, 2010, 5:33 PM

Post #1 of 4 (3011 views)
Shortcut
Templates - removing attachments? Can't Post

In the category index templates themselves, it contains the following code:

<!-- template insert : $articleList$ -->
<!-- templatecell : articleRow -->
<div class="summary">
<span class="summary_breadcrumb"><!--#include virtual="$published.categoryBreadcrumb.webpath$" -->
</span><br>

<a href="$published.articlePage.url$" class="summary_title">$article.title$</a> - <span class="summary_date">$article.date$</span><br>

$article.summary$

<div class="summary_link">
<!-- templateIf : $article.attachments$ ne "" -->
<div class="summary_attachments"> <b style="color: #666666;">Download attachment(s):</b> $article.attachments$</div>
<!-- /templateIf -->

[ <a href="$published.articlePage.url$">Read More...</a> ]

<br clear="all"></div>
</div>
<!-- /templatecell : articleRow -->


<!-- templateIf : $articleList$ eq "" -->
<div class="summary">Sorry, no articles were found.</div>
<!-- /templateIf -->




<!-- templatecell : article.attachments.row -->
[ <a href="$file.webUrl$">$file.title$</a> ]
<!-- /templatecell : article.attachments.row -->


Do I "have" to leave the article attachments stuff?

I never use it, and especially won't be using it on category pages, so can I just remove it without problems?

Amber


Donna
Staff / Moderator


Jan 4, 2010, 5:46 PM

Post #2 of 4 (3009 views)
Shortcut
Re: [dimeco] Templates - removing attachments? [In reply to] Can't Post

Hi Amber!

If you're never going to use it, remove the field itself from the back end of Article Manager, as well as the template references. You can do this by going into Admin -> Database -> Modify (on the "Articles" table). Delete the "attachments" field.

Or, if you want to leave that field in the back end, then you'll need to have at least the templatecell in the template, but can remove the other references with the templateIf. :)

Donna

--
support@interactivetools.com


dimeco
User

Jan 4, 2010, 6:35 PM

Post #3 of 4 (3008 views)
Shortcut
Re: [Donna] Templates - removing attachments? [In reply to] Can't Post

Hi Donna - thanks for the quick reply!

Quick question/verification:

Does images count as attachments or is it specifically for like files/pdfs etc?

(I do have a different image file in case people want to put that into their articles but its rarely used - and not on the category pages).

Amber


Donna
Staff / Moderator


Jan 6, 2010, 3:00 PM

Post #4 of 4 (2974 views)
Shortcut
Re: [dimeco] Templates - removing attachments? [In reply to] Can't Post

Depends. Which field are you using to upload your images? If it's the "Attachments" field, then yes. If you have another field for those, then no. :)

Donna

--
support@interactivetools.com