1
lynn112
News Module how to add html to the main page
  • 2004/11/17 14:52

  • lynn112

  • Just popping in

  • Posts: 13

  • Since: 2004/11/2


Hello, tried a search of the forums and found nothing.

This is probably a really dumb question, but I wanted to add html content to the main News page . I made 2 menus for the content of the news, but wanted to make them both part of the news main page template. Using custom blocks makes the tables show up on all the news pages and i only want them on the main news page.


So my question is this: which file do I edit to add custom html to the news index page? I tryed to add the table of links to the news_index.html , but it did not show up. Can anyone help?

HERE is my site.

2
anonymous
Re: News Module how to add html to the main page
  • 2005/4/9 19:41

  • anonymous

  • Just popping in

  • Posts: 4

  • Since: 2005/2/7 1


lynn,

I hope to see an answer to your question, because I want to do the same thing. I was approaching the problem a different way though. I thought maybe I could create a custom block which would include the news_index.html template (which I believe is the main news page that shows the intro to your main news articles).

If I could do this, then I could add other content, or other blocks.

The problem I have is there isn't a block for main news. There is recent news, News Topics, Big Story, etc. All of these blocks look like they are designed to be in a smaller column to just have a list of links to articles. I want a block for the news articles that I can display in the largest column (center for me) that will display the actual articles.

At first I thought I could do this by setting the news module as the top page, which displays the articles nicely, but when I put blocks in the center column (where the news module displays the main news), I have now way of weighting the block of news articles. I'd like to add blocks to the center column, but have them display BELOW the articles.

Hope there's a guru out there that can assist with our dilemna. I get the general feeling that this is much simpler than I'm making it seem though.

3
OBecanoby
Re: News Module how to add html to the main page
  • 2005/4/10 19:34

  • OBecanoby

  • Just popping in

  • Posts: 18

  • Since: 2005/2/1 4


I am sure there might be a better answer, but for html I use xt-conteudo module where i can have several pages that show in the main menu. Look at my site I use xt-conteudo for my Kool Links Pages. Hope this helps

4
anonymous
Re: News Module how to add html to the main page
  • 2005/4/11 21:34

  • anonymous

  • Just popping in

  • Posts: 4

  • Since: 2005/2/7 1


OBecanoby,

I'll try that module and see if I can figure it out.

How did you get the three columns at the top and only two at the botom (Search, New Members, Announcements at the top)?

5
brash
Re: News Module how to add html to the main page
  • 2005/4/12 0:04

  • brash

  • Friend of XOOPS

  • Posts: 2206

  • Since: 2003/4/10


Did you update your news module in XOOPS admin after making your template changes? Changes will not be displayed until this is done.

6
OBecanoby
Re: News Module how to add html to the main page
  • 2005/4/12 10:45

  • OBecanoby

  • Just popping in

  • Posts: 18

  • Since: 2005/2/1 4


This is how I have it set up click here http://obecanoby.com/blocks.jpg
Hope this helps.

7
anonymous
Re: News Module how to add html to the main page
  • 2005/4/17 20:25

  • anonymous

  • Just popping in

  • Posts: 4

  • Since: 2005/2/7 1


OK, I sorta found something that does what I want. The "Articles" module has a block that is designed to be used in the center that (after a bit of reformatting) looks close to what I want.

It appears though, that in the block it doesn't do the text parsing for html/xoops/urls like it does when looking at the article.

Take a look to see what I mean.

Here you can see it on the main page: http://www.riblets.org/
][ size=x-large ][ color=0000FF ][ font=Helvetica ]What's New[/font][/color][/size][/b] If you're used to visiting [url=http://

(spaces inserted to keep this forum from interpretting XOOPS code in the section above.


but when you look at the article here:
http://www.riblets.org/modules/articles/article.php?id=6

It displays more like this:

[b][size=x-large][color=0000FF][font=Helvetica]What's New[/font][/color][/size][/b] If you're used to visiting


Any ideas on how to fix this? I've edited the template a lot, but I'm not sure how to run the article body through the parser to deal with xoopcode. Anyone familiar with how to do this?

8
filesiteguy
Re: News Module how to add html to the main page

I take it there's not been an answer to this yet? I've been looking for awhile, too. I can mess with teh templates, but i just get, for example

Article Title
{$arts.description}

9
Tefnut
Re: News Module how to add html to the main page
  • 2005/5/10 17:10

  • Tefnut

  • Just popping in

  • Posts: 36

  • Since: 2004/9/13


i still searching a news block like "news_index"

i can't make my own homepage..

10
filesiteguy
Re: News Module how to add html to the main page

I did it!

I ended up adding the description to center block latest articles list.

However it wasn't easy.

https://xoops.org/modules/newbb/viewtopic.php?topic_id=35837

Here's the code I added to articles_latest_main.php.

At around line 50:
$description $myts->makeTboxData4Show($myrow['art_description']);
            if (!
XOOPS_USE_MULTIBYTES) {
                if (
strlen($myrow['art_description']) >= $options[2]) {
                    
$description $myts->makeTboxData4Show(substr($myrow['art_description'], 0, ($options[2] - 1))) . "...";
                } 
            }


Then again at around line 66:
$arts['description']                        = $description;



I then did what I mentioned in the other linked post by editing the table to show $arts.description instead of $arts.text

Login

Who's Online

341 user(s) are online (296 user(s) are browsing Support Forums)


Members: 0


Guests: 341


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Nov 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits