Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
#1 2013-01-22 04:41:26
- madzzoni
- Member
- From: Grünberg/Hessen/DE
- Registered: 2013-01-22
- Posts: 38
New to TXP 4.54 - Making a Frontpage
Hi There!
After 8 successfull years with WordPress as Blog/CMS i’m finally decided to try something else as CMS! I choose TXP, because it’s seems to have the same/more freedom as WP for a “Non Developer” and not to BIG a system like Drupal/Typo3 and others to begin with ;-/…
I’ve allready set-up a new TXP Blog design, very easy indeed, – based on the original 4.54 template CSS, – installed some plugins, OK, – but i’m “stuck” in making a proper “Frontpage, Homepage, Default-page or what ever the TXP system like to call it!! (In WP you just choose your “Homepage” from the Backend!)
I tried to follow some TXP guidelines via Google Search etc., but they all seems to be “outdated” (From 2005 and so!) … I tried to search the “TXP Homepage and Forum” for help, but without success, so far…
All i want to know from “the bottom” is:
How do i make a Front/Home/Default-page with:
1. a “Sticky” Article-excerpt from a TXP article with an “fullsize” image as “Top Story, Introduction” in the “main area”? (Not shown in the news-section!) (One can edit!)
2. a list of Headlines+excerpt (with link + excerpt + “Read more”) for the 4/5 newest “blog, articles, news” entry’s just under the “Sticky” intro article in the “main area” of the (Default) page?
3. How do i set this “Frontpage” as the “index, default, start-page”? ( = http://fym.xconsult.dk)
Hope somebody here can help here!
Best regards
-Madzzoni
<TXP:n00b />
Offline
Re: New to TXP 4.54 - Making a Frontpage
- To make default page, you go to Design ((((((My textpattern is in Russian, so I could name a few things wrong)))))))))
then, sections – 1st tab.
In sections tab, there is a section called default. that is your front page. You can the page and style it uses.
Then go pages, 2nd tab, here you will see pages you can edit.
Basically, for your default section there should be a special page, which you design.
In that page for your default section you can do what you listed in #2 and #1.
Offline
Re: New to TXP 4.54 - Making a Frontpage
The way I approach a Textpattern homepage is to make a page template specifically for it (called ‘homepage’). Assign the ‘default’ section (which means the home in Textpattern speak) to use that page template.
Then also create a section called ‘homepage’ and a sticky article for that section. Make sure that section is set ‘On front page’ to ‘Yes’ and that all other sections have set ‘On front page’ to ‘No’.
You can then use that sticky article to create content just for the homepage and nowhere else, and pull it into the homepage page template with:
<txp:article limit="1" status="sticky" />
That’s handy for also creating a meta description and title for the homepage and stuff like that.
For any other sections whose articles you want to appear in the homepage page template you can pull them in using something like:
<txp:article_custom section="news" sort="posted desc" limit="3" form="news-flash"/>
Which would pull the 3 latest news articles into your homepage using a form called ‘news-flash’.
Hope that helps somewhat.
Last edited by philwareham (2013-01-22 15:08:39)
Offline
Re: New to TXP 4.54 - Making a Frontpage
philwareham a écrit:
a sticky article for that section. Make sure that section is set ‘On front page’ to ‘Yes’ and that all other sections have set ‘On front page’ to ‘No’.
You can then use that sticky article to create content just for the homepage and nowhere else, and pull it into the homepage page template with:
<txp:article limit=“1” />
Hi Phil the correct code to output a sticky article would be:
<txp:article limit="1" status="sticky" />
Last edited by Dragondz (2013-01-22 09:40:44)
Offline
Re: New to TXP 4.54 - Making a Frontpage
Ha ha, oh yeah. Good spot. Now changed in the previous post.
Offline
Re: New to TXP 4.54 - Making a Frontpage
I prefer plain HTML code to sticky.
- Along with the rest of the site I can paste the whole page into Dreamweaver and make design whatever I want, and see it on my localhost server.
- Text of the entire front page, or just parts of it can be contained in separate sticky or hidden articles, and then we can just display body text by id number anywhere in design where it is appropriate.
This allows the user to REALLY edit contents of the page without requiring knowledge of HTML.
Offline
#7 2013-01-22 14:18:33
- gour
- Member
- From: Hlapičina, Croatia
- Registered: 2013-01-17
- Posts: 124
Re: New to TXP 4.54 - Making a Frontpage
philwareham wrote:
You can then use that sticky article to create content just for the homepage and nowhere else, and pull it into the homepage page template with:
What if I want to have excerpt from the ‘newest’ article only which can come from some of the selected categories (not all) on my homepage announcing ‘latest news’ and have that article under my articles/blog section as well?
Offline
Re: New to TXP 4.54 - Making a Frontpage
gour a écrit:
What if I want to have excerpt from the ‘newest’ article only which can come from some of the selected categories (not all) on my homepage announcing ‘latest news’ and have that article under my articles/blog section as well?
Like noted by phil above only add a code like that:
<txp:article_custom category="news,anothernews" sort="posted desc" limit="3">
<h3><txp:title /></h3>
<txp:excerpt />
</txp:article_custom>
Offline
Re: New to TXP 4.54 - Making a Frontpage
@sochicomputerRU
Just to clarify: obviously when I say use the sticky for homepage content, I mean for it’s textual content, not for housing any HTML code or txp tags (that should be in the page template itself).
One should never create CMS content with HTML mixed into it (the whole ‘keep structure, style and content separate’ thing). Same goes for any txp tags, try to keep their use within actually CMS article content to a minimum – then if you decide to move to a different CMS in future your content is easier to port. You’d never do that though of course because you’ll always stick with Textpattern ;)
For example, this site I’m currently building only uses the homepage sticky article to populate the homepage meta description and homepage Facebook Open Graph data.
Last edited by philwareham (2013-01-22 16:14:15)
Offline
#10 2013-01-22 15:59:43
- gour
- Member
- From: Hlapičina, Croatia
- Registered: 2013-01-17
- Posts: 124
Re: New to TXP 4.54 - Making a Frontpage
Dragondz wrote:
Like noted by phil above only add a code like that:
Hey, this txp is really cool!!
I’m so eager to receive the book…
Offline
#11 2013-01-22 23:42:47
- madzzoni
- Member
- From: Grünberg/Hessen/DE
- Registered: 2013-01-22
- Posts: 38
Re: New to TXP 4.54 - Making a Frontpage
THX to philwareham and everyone here for your helpful TXP tip’s … Very friendly Forum here, I’ll be back if got further problems,
-madzzoni
Last edited by madzzoni (2013-01-22 23:43:35)
<TXP:n00b />
Offline
#12 2013-01-23 00:58:58
- madzzoni
- Member
- From: Grünberg/Hessen/DE
- Registered: 2013-01-22
- Posts: 38
Re: New to TXP 4.54 - Making a Frontpage
philwareham wrote:
The way I approach a Textpattern homepage is to make a page template specifically for it (called ‘homepage’). Assign the ‘default’ section (which means the home in Textpattern speak) to use that page template.
Then also create a section called ‘homepage’ and a sticky article for that section. Make sure that section is set ‘On front page’ to ‘Yes’ and that all other sections have set ‘On front page’ to ‘No’.
You can then use that sticky article to create content just for the homepage and nowhere else, and pull it into the homepage page template with:
<txp:article limit=1" status="sticky" />
That’s handy for also creating a meta description and title for the homepage and stuff like that.
For any other sections whose articles you want to appear in the homepage page template you can pull them in using something like:
<txp:article_custom section="news" sort="posted desc" limit="3" form="news-flash"/>
Which would pull the 3 latest news articles into your homepage using a form called ‘news-flash’.
——————————————-
I followed these instructions 100%, create Section and new “Sticky” Article, … but it doesn’t put anything in the content area.
Here is my new “homepage” template from the Body-tag (a copy from Default-page and edited)
<body id=”<txp:if_section name=”“><txp:if_search>search<txp:else />front</txp:if_search><txp:else /><txp:section /></txp:if_section>-page”>
<!— header —> <header role=“banner”> <hgroup> <h1><txp:link_to_home><txp:site_name /></txp:link_to_home></h1> <h3><txp:site_slogan /></h3> </hgroup> </header>
<!— navigation —> <nav role=“navigation”> <h1><txp:text item=“navigation” /></h1> <txp:output_form form=“main_menu” /> </nav>
<div class=“wrapper”> <div class=“container”><!— left (main) column —> <div role=“main”>
<!— Homepage Intro — > <txp:article limit=1” status=“sticky” />
<!— News-flash —> <txp:article_custom section=“nyheder” sort=“posted desc” limit=“3” form=“article_listing”/> </div> <!— /main —> —-<TXP:n00b />
Offline