1
ovelho
News Topic Images
  • 2007/6/30 16:42

  • ovelho

  • Just popping in

  • Posts: 18

  • Since: 2005/9/13


Hi Folks,

I would like to add a "class" to the News Topic Images. Where do I found the code to add a class? I'm using News version 1.44.

Cheers!

2
script_fu
Re: News Topic Images

If I am following what your asking for correctly. Maybe you can elaborate a lil more.

You would start here...

modules/news/templates/blocks

Also you might need to adjust your style sheet in your theme folder based on what you do.



Edit: Slight spelling issue & more clarity.

3
ovelho
Re: News Topic Images
  • 2007/7/1 18:17

  • ovelho

  • Just popping in

  • Posts: 18

  • Since: 2005/9/13


Hi. I'll try to be more clear.

In the news I have News Topics. Each topic have a image associated. What I would like is to add the string "class=something" at the Code:

<img src='http://www.ovelho.com/modules/news/images/topics/hardware.jpg' alt='Hardware' hspace='10' vspace='10' align='right' />


I coudn't find where to change it. Any thoughts?

Cheers!

4
snow77
Re: News Topic Images
  • 2007/7/1 18:47

  • snow77

  • Just can't stay away

  • Posts: 864

  • Since: 2003/7/23


I think that is in the news_item.html news template on line number 12:

<td><div class="itemBody"><{$story.imglink}><class="itemText"><{$story.text}>p>div>td>

and it is <{$story.imglink}> you want to add a class to. You can embed it in a span like this:

<{$story.imglink}>

or in the style.css of your theme add something like this:

.itemBody img {margin:10px; float:right;}

5
snow77
Re: News Topic Images
  • 2007/7/1 19:03

  • snow77

  • Just can't stay away

  • Posts: 864

  • Since: 2003/7/23


forgot to say this, if you modify news_item.html you save the template not in the module templates folder but instead inside a new folder structure you create in your theme folder like this: your theme > modules > news > news_item.html

> then erase templates_c (except index.html) to refresh cache.

This is template overriding, part of the new templating functions XOOPS has. I don't advise the template cloning feature in the system functions. Your custom templates will always be safer in the themes folder.

Login

Who's Online

265 user(s) are online (195 user(s) are browsing Support Forums)


Members: 0


Guests: 265


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