Jump to content
TNG Community
Dan Wedig

Add Additional Feature Articles Template 4

Recommended Posts

Dan Wedig

I would like to modify the Template 4 layout to add two or three more Feature Article fields on the home page. Is this possible and how do I go about doing so.

Thanks in advance for any assistance you can provide.

Dan Wedig

Share this post


Link to post
Share on other sites
jhculbert

Dan,

I am extremely disappointed in this Forum for not answering your question.  I just found it because I have a more specific question related to the same topic.

Do you have access to the files feature1.php to feature4.php?

These files need to be placed in your media histories folder, and each file needs to be changed using a text editor so that at the bottom of each the related feature article file name is entered.  Then file your feature article(s) into the same histories folder.

Finally, on your Setup >> Configuration >> Template Settings page, each of the php files (not your feature article file names!) needs to be entered into the appropriate window asking for the name of your Feature article link.  Show the entire path from the root, not just the php file name.

 

Share this post


Link to post
Share on other sites
slowjim

What I did to accomplish this was edit the index.php file in the template4 folder. Beginning on line 176 the comments will tell you what need to do to add another Feature article. I changed mine from the original 4 to add one more.

 

http://www.thebrownfamilytree.com/index.php

Share this post


Link to post
Share on other sites
Newfloridian

I believe T4 to be the most flexible of the templates through its Feature Article facility. There are a number of stratagems to enable expansion beyond the basic four. Keep up your good work.

Also please see PM

 

Share this post


Link to post
Share on other sites
huw ellis

After editing the index.php file in the template4 folder, I've created Article 5, which now has a slot in the Home Page, but the relevant article is not yet reflected on the page. See : www.achau.co.uk.

However, on  accessing Setup >> Configuration >> Template Settings page, the relevant Article 5 fields are not visible for inputting Article 5. How can I create the Article 5 fields in the Setup >> Configuration >> Template Settings?

Thanks in advance for any assistance, Huw

Share this post


Link to post
Share on other sites
Newfloridian

I've only looked at the "View Page" of your site but the relevant piece looks like this:

<p>
  <a href="extrapgs/llwydiarth.php"><img src="templates/template4/img/Arfbais Celynin3.jpg" alt="feature 3" class="featureimg" /></a>
  <a href="extrapgs/llwydiarth.php"><span class="emphasis">Fychaniaid Llwydiarth / Vaughans of Llwydiarth</span></a> The founder of this tribe Celynin ap RIRID is said to have fled from South Wales after killing...<br clear="left"/>
  </p>
  <p>
  <a href="extrapgs/glanllyn.php"><img src="templates/template4/img/Arbais Ririd Flaidd4.jpg" alt="feature 4" class="featureimg" /></a>
  <a href="extrapgs/glanllyn.php"><span class="emphasis">Fychaniaid Glanllyn / Vaughans of Glanllyn</span></a> The coat of arms of the Vaughan's of Glanllyn is descended from Rhirid Flaidd Lord of Penllyn, Eifionnydd and Pennant Melangell... </p>
  <p>
  <a href=""><img src="templates/template4/" alt="feature 5" class="featureimg" /></a>
  <a href=""><span class="emphasis"></span></a> </p>
 

This is the code for Feature Articles 3,4 and 5.

Obviously 5 looks totally different to 3 and 4. You will need to the references to href and img src to where your new article and thumbnail image are situated. And if they are already there, perhaps for simplicity that's where you should move them.

Cheers Alan

 

Share this post


Link to post
Share on other sites
Ken Roy

This is a 7 year old forum topic.  Lots have changed in TNG since 2015 and even 2017 when this topic was last posted to.

Since the Template Settings are now in the TNG Database, you at a minimum need to read Creating a new Template - TNG v12

Share this post


Link to post
Share on other sites
Ken Roy

Or use Template 20 is which a restyled Template 4 that uses <div> instead of <tables> for layout formatting and already has 6 feature article links

Share this post


Link to post
Share on other sites
huw ellis

Thanks all, I've gone for Template 14, which has links to my 'extrapgs'..

I've also started translating TNG into Welsh! The home page is sorted, but much more to do!

 

Huw

www.achau.co.uk

 

 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×