1
dougfc5
How can I change the Web Links sorted by popularity initially?
  • 2005/11/28 15:50

  • dougfc5

  • Just popping in

  • Posts: 39

  • Since: 2005/8/1 1


I use XOOPs 2.0.13.2 version with Web links module, in which's sites are sorted by Title (A to Z) initially. I want to change it to be sorted by Popularity initially.

I read the template of ViewCat.html but still cannot find any clues. Anyone have the same problem before? Please help.

Thanks in advance!
doug

2
highlander
Re: How can I change the Web Links sorted by popularity initially?
  • 2005/11/28 18:23

  • highlander

  • Not too shy to talk

  • Posts: 151

  • Since: 2004/12/5


Hi Doug,

You need to change the template mylinks_index.html to do this.

in the template mylinks_index.html
find the following :
<a href="<{$xoops_url}>/modules/mylinks/viewcat.php?cid=<{$category.id}>"><img src="<{$category.image}>" height="50" border="0" alt="" />a>

and change to :
<a href="<{$xoops_url}>/modules/mylinks/viewcat.php?cid=<{$category.id}>&orderby=hitsD"><img src="<{$category.image}>" height="50" border="0" alt="" />a>


and find :
<td valign="top" width="40%"><a href="<{$xoops_url}>/modules/mylinks/viewcat.php?cid=<{$category.id}>"><b><{$category.title}>b>a>&nbsp;(<{$category.totallink}>)<br /><{$category.subcategories}>td>

and change that to :
<td valign="top" width="40%"><a href="<{$xoops_url}>/modules/mylinks/viewcat.php?cid=<{$category.id}>&orderby=hitsD"><b><{$category.title}>b>a>&nbsp;(<{$category.totallink}>)<br /><{$category.subcategories}>td>


good luck !

Highlander
So, I'm in the park wondering why frisbees get larger as they get closer when suddenly, it hits me...
http://www.AnimalPedigree.com

3
dougfc5
Re: How can I change the Web Links sorted by popularity initially?
  • 2005/11/29 3:56

  • dougfc5

  • Just popping in

  • Posts: 39

  • Since: 2005/8/1 1


Thanks highlander!

I follow your instruction, but it don't work.

peter

4
highlander
Re: How can I change the Web Links sorted by popularity initially?
  • 2005/12/5 10:21

  • highlander

  • Not too shy to talk

  • Posts: 151

  • Since: 2004/12/5


Hi Peter,

I am on 2.0.13.2 as well and the code I posted works fine. When I go into the weblinks module and click on a category all links show up sorted by popularity.

you get send to an url similar to this one :
http://www.yourdomain.com/modules/mylinks/viewcat.php?cid=9&orderby=hitsD

Have you cloned the template set and made the changes in the clone ?
Sounds like the changes just havent "stuck".

kind regards, Highlander
So, I'm in the park wondering why frisbees get larger as they get closer when suddenly, it hits me...
http://www.AnimalPedigree.com

Login

Who's Online

165 user(s) are online (39 user(s) are browsing Support Forums)


Members: 0


Guests: 165


more...

Donat-O-Meter

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

Latest GitHub Commits