1
caek9
Default News Module Blues
  • 2008/8/23 3:27

  • caek9

  • Friend of XOOPS

  • Posts: 35

  • Since: 2008/7/9 2


I was wondering how I can change the way the default news module displays titles. Right now it seems to like making everything capitalized and the first letter of every word slightly larger.

Is there anyway I can change that behavior?
Also, is there anyway to get rid of the "bytes more" at the end of a teaser? perhaps changed it into a word count?

2
Mamba
Re: Default News Module Blues
  • 2008/8/23 4:19

  • Mamba

  • Moderator

  • Posts: 11409

  • Since: 2004/4/23


I think, you should be able to change by changing the templates.
Support XOOPS => DONATE
Use 2.5.11 | Docs | Modules | Bugs

3
caek9
Re: Default News Module Blues
  • 2008/8/23 5:15

  • caek9

  • Friend of XOOPS

  • Posts: 35

  • Since: 2008/7/9 2


I took a look at the templates and couldn't find anything that might have controlled the formatting of titles, is there another place this might be?

4
ghia
Re: Default News Module Blues
  • 2008/8/23 10:41

  • ghia

  • Community Support Member

  • Posts: 4953

  • Since: 2008/7/3 1


For the titles, you have to look in your theme's css files for itemHead and itemTitle and remove font-variant: small-caps; .

For the bytes more, you have to edit news\class\class.newsstory.php . Look for _NW_BYTESMORE and adapt the formatting of $totalcount.

5
iHackCode
Re: Default News Module Blues

CBB / LatestNews / Publisher / XM-Spotlight

(ノ◕ヮ◕)ノ*:・゚✧

6
caek9
Re: Default News Module Blues
  • 2008/8/24 4:53

  • caek9

  • Friend of XOOPS

  • Posts: 35

  • Since: 2008/7/9 2


Big thanks to ghia_ and Bandit-X

I'm not quite familiar how XOOPS works and only a basic grasp on php and mySQL so far and your posts were very helpful

I'm still having problems making XOOPS display a word count.. I did have a problem finding _NW_BYTESMORE in news\class\class.newsstory.php. What function should it be under? Can I just add it in or is it defined somewhere else?


Also heres another question since I don't want to spam the topic list. When my visitors visit my site they see /modules/news/ after my url. Is there anyway to clean that up so they just see my domain? I think it has something to do with the way I initially tried setting XOOPS up. Thanks a lot.

7
ghia
Re: Default News Module Blues
  • 2008/8/24 9:00

  • ghia

  • Community Support Member

  • Posts: 4953

  • Since: 2008/7/3 1


As the first hack in the list pointed to by Bandit-X explains, you have to replace some lines. (The first replacement has to be done in other language files too, if you use other then english.)
If you can find the required lines (it is in function prepare2show), I must assume you have a very old version? (Current = 1.62, but also usable in V1.56).

You can make that the users directly see the news on the start page by setting News as the 'Module for your start page' in admin preferences system general.

8
caek9
Re: Default News Module Blues
  • 2008/8/28 2:06

  • caek9

  • Friend of XOOPS

  • Posts: 35

  • Since: 2008/7/9 2


Thank you for your help again. Heres another set set of questions as your reward. :)

The site in question is http://medicalmarijuanareferrals.com

On my recent news block ( on the right) it shows the date and a list of recent articles. How do I remove the date? I tried looking in the templates for news_block_new.html but I can't figure out what exactly to edit. I'm using the classic view, and I thought I changed the relevant code, but I must be mistaken.

Second Question is how get users to see my news module in the index [b]without the address changing to /modules/news. I just want it show the domain. It's a minor issue but it's a gripe of the owner of the site.

Thanks again to the XOOPS Developers who designed this. It's a great system.

9
ghia
Re: Default News Module Blues
  • 2008/8/28 3:03

  • ghia

  • Community Support Member

  • Posts: 4953

  • Since: 2008/7/3 1


Comment all <{$news.date}> out in modules\news\templates\blocks\news_block_top.html .

Move your XOOPS to a subdirectory eg /xoops .
Adapt your URL and path in mainfile.php
Create an index.html in http://medicalmarijuanareferrals.com like:
<html><head>head>
<
frameset ROWS="100%, *" frameborder="no" framespacing=0 border=0>
<
frame SRC="http://medicalmarijuanareferrals.com/xoops/" 
NAME="mainwindow" frameborder="no" framespacing="0" marginheight="0" 
marginwidth="0" title="Mainframe" scrolling="yes">
<
noframes
<
body><center>Our site is at
<
a href="http://medicalmarijuanareferrals.com/xoops/">
http://medicalmarijuanareferrals.com/xoops/
a>center>
body>
noframes>
 frameset>html>
Your users won't see any link at all!

Login

Who's Online

319 user(s) are online (250 user(s) are browsing Support Forums)


Members: 0


Guests: 319


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