Main
Index
Search
Posts
Who's
Online
Log
In

Home: Discontinued/Classic Products: Article Manager 2:
hiding attachments placeholder

 

 


davecope
New User

Jun 25, 2009, 2:47 PM

Post #1 of 2 (842 views)
Shortcut
hiding attachments placeholder Can't Post

Hi gang,

I am using the single page option for AM (thanks for the tutorial!).

In my category index file, how do i hide the attachments placeholder in my page (if users have not uploaded any attached files) i.e.'Click to download the attached file' on the category page.

Code:

<p><!-- templateIf : $category.attachments$ ne "" -->
<br style="clear: both;" />
<ul>
<li style="list-style-type:none;"><b>Click to download the attached file(s):</b></li>
<!--templateInsert : $category.attachments$ -->
</ul>
<!-- templatecell : category.attachments.row -->
<li><a href="$file.weburl$">$file.title$</a></li>
<!-- /templatecell : category.attachments.row --></p>

example page (to the replicate the problem):

http://cope-interactive.co.uk/artman2/publish/productrange/index.shtml

Kind regards

Dave

I'm beat..G'night :-)


Donna
Staff / Moderator


Jun 26, 2009, 2:14 PM

Post #2 of 2 (835 views)
Shortcut
Re: [davecope] hiding attachments placeholder [In reply to] Can't Post

Hi Dave,

What you've got should work, although it's missing the end templateIf -- I'm not sure if that was left off of the copy & paste, or if it's just not there.

The end result should look something like this:

<!-- templateIf : $category.attachments$ ne "" -->
<br style="clear: both;" />
<ul>
<li style="list-style-type:none;"><b>Click to download the attached file(s):</b></li>
<!--templateInsert : $category.attachments$ -->
</ul>
<!-- /templateIf -->

<!-- templatecell : category.attachments.row -->
<li><a href="$file.weburl$">$file.title$</a></li>
<!-- /templatecell : category.attachments.row -->

Let me know if that works for you. :)

Donna


Hire me!
Save time by getting our experts to help with your project. Template changes, advanced features, full integration, whatever you need. Whether you need one hour or fifty, get it done fast with Priority Consulting.