Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2007-01-24 10:13:58

Qwest
Member
From: London, UK
Registered: 2007-01-24
Posts: 112

Multiple categories on one page? Can it be done?

Morning all!

I’ve been looking for a decent CMS for a long while now. I’ve been using Coranto for the past 6 years or so. it’s a small & lightweight CGI based CMS, but it stores all the news in .txt files which can be overwritten quite easily!…

Anyway, i’ve been looking for a solid MySQL based system for a while now for one of my clients. I tried Wordpress about 6 months ago, but the client’s host wouldn’t allow it. I came accross Textpattern yesterday (via hicksdesign.co.uk) and immediatly looked into it and i have now installed it on my client’s server.

Now my question is, can i display multiple categorys or sections on my client’s site. The nature of the website is club promotion. They run a monthly club event in London. I’d like to have a “Next Event” section displayed at the top of the page. This will show the flyers & details for the event. I’d like this section to be displayed permenantly at the top of the page. I’d also like to be able to have an archive of the “events” and their comments etc.

And then below that, will be the standard textpattern ‘blog’ like posts with the 2 sidebar sections.

My main requirement would be the event section at the top of the page… Does anyone know whether / how it can be done?

If my description is a little off, let me know and i’ll do a quick mock-up of it!

Hope you can help :)

Tony

edit:

Here’s a mockup of what i’m talking about:

The yellow section beneath the navigation should be seperate from the other posts, but should still show on the front page and should always be visable at the top of the page?

Last edited by Qwest (2007-01-24 12:21:14)

Offline

#2 2007-01-24 13:04:30

DigitalRealm
Member
From: Greenville, SC
Registered: 2006-07-22
Posts: 139
Website

Re: Multiple categories on one page? Can it be done?

You can certainly display articles from different categories on the same page with no problem at all. What you want to do should be pretty easy to setup, you will just need to get yourself familiar with all of the txp tags so that you can manipulate things like you want it.

Offline

#3 2007-01-24 13:33:02

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,091
Website GitHub Mastodon Twitter

Re: Multiple categories on one page? Can it be done?

Hi Qwest and welcome to txp

Now my question is, can i display multiple categorys or sections on my client’s site. The nature of the website is club promotion. They run a monthly club event in London. I’d like to have a “Next Event” section displayed at the top of the page. This will show the flyers & details for the event. I’d like this section to be displayed permenantly at the top of the page. I’d also like to be able to have an archive of the “events” and their comments etc.

you can do that by using article_cutom

And then below that, will be the standard textpattern ‘blog’ like posts with the 2 sidebar sections.

Here’s a mockup of what i’m talking about:

http://static.zooomr.com/images/673412_d24b6aa4da_o.jpg

Form your mock I see that you might need a plugin for the advert (you can find it in this forum somewhere)

The yellow section beneath the navigation should be seperate from the other posts, but should still show on the front page and should always be visable at the top of the page?

if you only want to have the yellow section in the front page you should check for the glx_if plugin here in the forum. It’ll provide you with a set of conditionals which you might find very useful.

You might want to have a look at the textbook wiki as you will find lots of info there regarding txp.


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#4 2007-01-24 15:52:47

Qwest
Member
From: London, UK
Registered: 2007-01-24
Posts: 112

Re: Multiple categories on one page? Can it be done?

colak, thanks for your reply! Much appreciated.

I followed your post, and read up on the “article_custom” tag, and with a bit of jiggery pokery, i managed to get it working!!! All i’ve got to do now is style it all!

Why would i need a plugin for adverts?

Offline

#5 2007-01-24 16:08:43

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,091
Website GitHub Mastodon Twitter

Re: Multiple categories on one page? Can it be done?

Qwest wrote:

Why would i need a plugin for adverts?

hi Qwest,
If you need the adverst to rotate and do things that adverts do, you would need a plugin. If you just want to place a static add, then you can use txp out of the box


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#6 2007-01-24 16:51:09

Qwest
Member
From: London, UK
Registered: 2007-01-24
Posts: 112

Re: Multiple categories on one page? Can it be done?

At the moment, it will be just a static ad, but in the future, i will probably expand and use a plug-in like you suggested!

Now going back to my previous problem regarding custom-articles… I want the “events” posts to be displayed differently. They will have Flyer’s attached, showing the flyers for the event, along with the date etc… Now I’ve gathered that i need to create some custom fields, which i have done! How do i go about building a template for the events?

I assumed it was through Presentation > Forms, (ive created a form for Events), but i can’t seem to link it to the ‘events’ category, so that it takes the appropriate fields and put’s them where my template says! Am i doing it wrong?

Offline

#7 2007-01-25 07:31:37

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,091
Website GitHub Mastodon Twitter

Re: Multiple categories on one page? Can it be done?

I hyess you discovered the <if_custom_field> tag..

Instead of trying to explain here’s how one of my forms looks like:

<txp:if_individual_article> 
<txp:output_form form="customsingle" />
</txp:if_individual_article> 

<txp:if_article_list>
<div style="clear:both;margin-bottom:10px;">

<div style="float:left;margin-right:10px;">
<center>

<div class="metaperm">

<div class="sectiontitle">Arts Info</div>
<div class="day"><txp:posted format="%d" /></div>
<div class="month"><txp:posted format="%B %Y" /></div>
<txp:if_custom_field name="custom1"><div class="comall"><txp:custom_field name="custom1" /></div></txp:if_custom_field>
<div class="deadline"><txp:if_custom_field name="custom2"><txp:custom_field name="custom2" /></txp:if_custom_field><txp:if_custom_field name="custom3"> <br />(<txp:custom_field name="custom3" />)</txp:if_custom_field></div>
<txp:if_comments_allowed><div class="comall"><txp:comments_invite /></div></txp:if_comments_allowed>
</div>
</center>
</div>

<div class="excerpt"><h3><txp:permlink><txp:title /></txp:permlink></h3>
<txp:excerpt /></div>
<div style="clear:both;">&nbsp;</div>
</div>
</txp:if_article_list>

Here it is on the net

I call that form from the left side in the ‘write’ tab in the ‘Advanced Options’ > ‘Override form’


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#8 2007-01-25 11:47:00

Qwest
Member
From: London, UK
Registered: 2007-01-24
Posts: 112

Re: Multiple categories on one page? Can it be done?

Colak, thank’s for that, it has helped..

However, i’ve noticed one slight flaw with my install. I write the article, i change the ‘form’ from the ‘override form’ menu and, granted, it does change the style of the post, but it doesn’t affect the “Next Event” section at the top of the page. It only changes the style in the ‘blog’ part of the page…

What am i doing wrong?

Offline

Board footer

Powered by FluxBB