IPB

Welcome Guest ( Log In | Register )

Movable Type

We're moving to movabletype.org!

At long last, we're moving to forums powered by, well, Movable Type itself. You'll want to bookmark http://forums.movabletype.org/ for future reference, and in the meantime you can view these old forums as a read-only archive of past posts. Thanks for being part of the community!

 
Reply to this topicStart new topic
> Category Display Issues, category tags not working properly
2much
post Jan 19 2004, 07:25 AM
Post #1





Group: Members
Posts: 3
Joined: 19-January 04
Member No.: 19,959



Hello. I would love some help with something that I've been toying with for days (unsuccessfully).

I would like to set up my template so that when a category is created, the category page only displays listings from that same category.

At the moment, every category page displays listings from every category.

Here's an example:
Hispanic Watch

Any ideas what tags I can use so that each category page only links to entries in the same category?
Go to the top of the page
 
+Quote Post
gvtexas
post Jan 19 2004, 08:24 AM
Post #2





Group: Members
Posts: 861
Joined: 30-April 03
From: Texas
Member No.: 10,425



Can you post the MT code on your main page for the section where you list the links to the categories, and then post the MT code from your category archive page, but only the section between the MTEntries and /MTEntries tags. Sounds like it's your choice of category archives tags that's doing it.

To post code, copy it first, then in the post message form here click the CODE button above the entry window, paste in your copy, then click the CODE button again. Do this for each of the code snippets mentioned above.


--------------------
Go to the top of the page
 
+Quote Post
2much
post Jan 19 2004, 09:18 AM
Post #3





Group: Members
Posts: 3
Joined: 19-January 04
Member No.: 19,959



This is from the category archive page:

CODE
<MTCategories show_empty="1"><br>
 
<a href="<$MTCategoryArchiveLink$>"><$MTCategoryLabel$></a><br><br>
 
</div>

<div class="texto">
<MTEntries category="<$MTCategoryLabel$>

<a href="<$MTEntryPermalink$>"> <$MTEntryTitle$></a></span><br /><br>

 </MTEntries>
 <br /><br />


</MTCategories>


This is where I link to the categories:

CODE
<MTCategories>
 <a href="<$MTCategoryArchiveLink$>"><$MTCategoryLabel$></a><br>
 <br /><br />
</MTCategories>


Thanks for your help!
Go to the top of the page
 
+Quote Post
gvtexas
post Jan 19 2004, 09:41 AM
Post #4





Group: Members
Posts: 861
Joined: 30-April 03
From: Texas
Member No.: 10,425



To start with, if this is the copy you lifted, there's typo. This line:

CODE
<MTEntries category="<$MTCategoryLabel$>
...should be
<MTEntries category="<$MTCategoryLabel$>">


See if that helps. There is some other unnecessary code in your archive page (your main index codes are fine) but unfortunately I have to dash and can't type the corrected code here. Just had time to notice the oops above. Will do so when I get back, unless someone else pops in....

smile.gif


--------------------
Go to the top of the page
 
+Quote Post
gvtexas
post Jan 19 2004, 11:34 AM
Post #5





Group: Members
Posts: 861
Joined: 30-April 03
From: Texas
Member No.: 10,425



Sorry, back.

Compare your code to one I use on a blog that shows the category name at the top of the list, and a list of entries in that category showing the entry title and date posted.

Your code in the category archive template:
CODE
<MTCategories show_empty="1"><br>
 
<a href="<$MTCategoryArchiveLink$>"><$MTCategoryLabel$></a><br><br>
 
</div>

<div class="texto">
<MTEntries category="<$MTCategoryLabel$>

<a href="<$MTEntryPermalink$>"> <$MTEntryTitle$></a></span><br /><br>

 </MTEntries>
 <br /><br />


</MTCategories>

Compare that to this code:
CODE
<div class="ctitle">
<i>Topic:</i>  <MTArchiveCategory upper_case="1"></div>

<div class="blogbody">
<MTEntries sort_order="ascend" sort_by="title">

    <div class="cat-title">
               <a href="<MTEntryPermalink>"><MTEntryTitle></a>  <span class="posted"><i>(posted <MTEntryDate format="%m/%d/%y">)</i></span></div>

</MTEntries>


You don't need the category tags as you've shown them. My code above will give this result.

Also, you show links to your categories on your category archive page within the content area, yet you also have links out in the left column. Is there a specific reason for the redundancy?


--------------------
Go to the top of the page
 
+Quote Post
2much
post Jan 19 2004, 05:28 PM
Post #6





Group: Members
Posts: 3
Joined: 19-January 04
Member No.: 19,959



PERFECT!!! Thank you soo soo much, I really appreciate it, I've tinkered with this for at least 15 hours, THANK YOU! Check it out now, it looks great (or it will once I fix the stylesheet).
Go to the top of the page
 
+Quote Post
Lighter
post Jan 21 2004, 12:29 PM
Post #7





Group: Members
Posts: 1
Joined: 20-June 03
Member No.: 12,467



Thank you! This helped me solve a related problem.
Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



Lo-Fi Version Time is now: 11.25.09 - 12:35 AM