Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2006-03-14 20:20:27

Jeremie
Member
From: Provence, France
Registered: 2004-08-11
Posts: 1,578
Website

Default section and Front page not the same anymore

Edit: a formal Textbook Feature Request page as been added now.

Now : the default section/page and the front page are the same. This default page is mainly used to display Categories browsing (/category/catName) and Authors browsing (/author/authorName). It’s also the front page of a site.

Issue : the frontpage is similar to other articles page on a blog like website, but a lot of non blog websites use a specific frontpage. Some without even a txp:article tag in it. We can now detect the category browsing using a txp:if_category name="" / else trigger, but it’s a trick. And a trick not usable for author browsing. And a complex one to newcommers, who have to deal with nested conditionnal triggers on their first template/page coding.

Suggestion : make a distinction between the default section/page, and the frontpage. It’s more elegant (imo) and more simple to newcomers than another trick like a new txp:if_author name="" or something similar.

This would mean creating a new hardcoded FrontPage section, with a chosen page (exactly like the default section right now).

Any thoughts on this ?

Last edited by Jeremie (2006-03-19 05:04:16)

Offline

#2 2006-03-14 21:58:19

hakjoon
Member
From: Arlington, VA
Registered: 2004-07-29
Posts: 1,634
Website

Re: Default section and Front page not the same anymore

Perhaps a preference to choose the section that should be used for the front page? This would allow you to easily switch from one front page design to another if you wanted to.

Scenario:

You usually just have your front page display latest entries in your articles section you could set your front page to point to your articles section. If you then need to temporarily change the front page to a design without your articles you could create that as a new section and point your front page to that section.

Problems:

This changes the current behavior of including articles form certain sections in the frontpage. Maybe a section attribute similar to the one in article_custom could be introduced. If empty <txp:article > would behave as it currently does, however you could specify the sections you want to pull from when in article_list mode. Maybe something like.

<txp:if_article_list>
<txp:article section="articles,news">
<txp:else>
<txp:article>
</txp:if_article_list>

this might be more complicated then I anticipated given the amount of context sensitive behavior that txp:article has.

Last edited by hakjoon (2006-03-14 21:58:55)


Shoving is the answer – pusher robot

Offline

#3 2006-03-14 22:30:09

Jeremie
Member
From: Provence, France
Registered: 2004-08-11
Posts: 1,578
Website

Re: Default section and Front page not the same anymore

Redirecting the frontpage to a section is more trouble than anything I think. You can always switch the page if you need to.

Offline

#4 2006-03-14 22:40:36

hcgtv
Plugin Author
From: Key Largo, Florida
Registered: 2005-11-29
Posts: 2,722
Website

Re: Default section and Front page not the same anymore

Seeing as Textpattern is more of a CMS than a Blog, I can see where this would be very useful.

When designing sites, depending on what system I grab, I’ll use a specific blog for the front page or in the case of Textpattern, use a specific section.

Wish I could get into the technical details with you all but I’m still in the learning phase at this point.

Offline

#5 2006-03-14 23:27:43

hakjoon
Member
From: Arlington, VA
Registered: 2004-07-29
Posts: 1,634
Website

Re: Default section and Front page not the same anymore

Jeremie wrote:
Redirecting the frontpage to a section is more trouble than anything I think. You can always switch the page if you need to.

That was actually what I was thinking, I didn’t frame it properly. Assigning a page would accomplish the same thing I was trying to suggest.

Although it seems to me that other then the fact that it could change how on front page works, being able to specify which section is your frontpage section feels like a step in the right direction, rather then hard coding yet another special section.


Shoving is the answer – pusher robot

Offline

#6 2006-03-15 00:34:48

Jeremie
Member
From: Provence, France
Registered: 2004-08-11
Posts: 1,578
Website

Re: Default section and Front page not the same anymore

Well, assigning a section to the frontpage can have side effects. How would the “show on frontpage” option would work then ?

On the other hand, there is already a default section. Creating another named frontpage and using it for the “show on frontpage” and other similars things shouldn’t be too hard.

Offline

#7 2006-03-15 03:42:58

hakjoon
Member
From: Arlington, VA
Registered: 2004-07-29
Posts: 1,634
Website

Re: Default section and Front page not the same anymore

Jeremie wrote:
Well, assigning a section to the frontpage can have side effects. How would the “show on frontpage” option would work then ?

It wouldn’t, as I pointed out that would be one thing that would need to be re-evaluated. A potential solution would be to move that option to the template tag itself. There was aquick potential approach in my first post.

On the other hand, there is already a default section. Creating another named frontpage and using it for the “show on frontpage” and other similars things shouldn’t be too hard.

While it probably wouldn’t be that hard to implement, I wonder if it isn’t a paradigm worth re-evaluating. That’s not to say I think adding a frontpage section is a bad idea, quite the opposite in fact. I’m just wondering if there can maybe be a more flexible overall approach.


Shoving is the answer – pusher robot

Offline

#8 2006-03-15 05:51:11

Jeremie
Member
From: Provence, France
Registered: 2004-08-11
Posts: 1,578
Website

Re: Default section and Front page not the same anymore

For the frontpage, I don’t see how.

For the default “section”, maybe. But without knowing for sure what can be expected for the categories and the authors (would cat’ be tags ? would /author/joe output some bio and metadata ? etc.) it’s hard to say.

Offline

#9 2006-03-15 15:57:07

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

Re: Default section and Front page not the same anymore

Hi Jeremie,
I second your feature request and I would like to point to the <a href=“http://forum.textpattern.com/viewtopic.php?id=4526”>glx_if</a> plugin which offers a solution to the front page versus the default section. I would love to see the conditionals offered in the plugin in the core of txp (the front page being the most important for me too.


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

Offline

#10 2006-03-19 05:03:40

Jeremie
Member
From: Provence, France
Registered: 2004-08-11
Posts: 1,578
Website

Re: Default section and Front page not the same anymore

Textbook page added (gosh, this mediawiki markup is really foolish).

Offline

#11 2006-03-21 00:03:14

NyteOwl
Member
From: Nova Scotia, Canada
Registered: 2005-09-24
Posts: 539

Re: Default section and Front page not the same anymore

I’m still learning some of the quirks of Textpattern but can’t you just use the

<txp:if_section name=""> <txp:else /> </txp:if_section>

as a filter for the front page?


Obsolescence is just a lack of imagination. / 36-bits Forever! / #include <disclaimer.h>;

Offline

#12 2006-03-21 01:22:35

Jeremie
Member
From: Provence, France
Registered: 2004-08-11
Posts: 1,578
Website

Re: Default section and Front page not the same anymore

This test for a non section. But so are /author/ and /category/ browsing which are defined as non-sections too.

Offline

Board footer

Powered by FluxBB