1
ysbrasil
changing module variables
  • 2005/8/2 18:07

  • ysbrasil

  • Just popping in

  • Posts: 5

  • Since: 2005/8/2 1


hi,
im pretty new to xoops. trying to change the overall look of a website made on xoops..
the question is: how can i change the module variables?

for example:
im using a news module. there, a variable named <{$pagenav}> makes a simple menu, to navigate between the news. like that: << 1 2 3 4 5 6 >>
the problem is that each page really contains 2 news. and the <{$pagenav}> is set to 5 news per page.
how can i change it?


another thing: does XOOPS give some support to make the page a xhtml 1.0 strict ( w3c ) ?


thanks,

ys

2
ysbrasil
Re: changing module variables
  • 2005/8/4 22:47

  • ysbrasil

  • Just popping in

  • Posts: 5

  • Since: 2005/8/2 1


c'mon, people.. this shouldn't be a hard one =|


and about the support: looks like the modules i'm using are all full of tables! are there tableless modules?

3
ysbrasil
Re: changing module variables
  • 2005/8/10 11:37

  • ysbrasil

  • Just popping in

  • Posts: 5

  • Since: 2005/8/2 1


so, there's no way i can change the variables on the XOOPS modules...? =|


i'm changing all my modules to tableless, one by one. it takes some time. just personal opinion: people should be more concearned about using the w3c patterns

4
Dave_L
Re: changing module variables
  • 2005/8/10 13:50

  • Dave_L

  • XOOPS is my life!

  • Posts: 2277

  • Since: 2003/11/7


Quote:
im using a news module. there, a variable named <{$pagenav}> makes a simple menu, to navigate between the news. like that: << 1 2 3 4 5 6 >>
the problem is that each page really contains 2 news. and the <{$pagenav}> is set to 5 news per page.
how can i change it?


I don't understand your question.

To get the pagenav to work properly, you have to pass it the right information, as shown below:

Constructor
*
* @
param   int     $total_items    Total number of items
* @param   int     $items_perpage  Number of items per page
* @param   int     $current_start  First item on the current page
* @param   string  $start_name     Name for "start" or "offset"
* @param   string  $extra_arg      Additional arguments to pass in the URL
**/
function 
XoopsPageNav($total_items$items_perpage$current_start$start_name="start"$extra_arg="")
{

5
ysbrasil
Re: changing module variables
  • 2005/8/15 11:41

  • ysbrasil

  • Just popping in

  • Posts: 5

  • Since: 2005/8/2 1


thanks for the help =)

but i really dont know how (or where) to 'pass it the right information'.
i suppose i need to change the value of '$items_perpage'. how can i do this?

6
Dave_L
Re: changing module variables
  • 2005/8/15 11:49

  • Dave_L

  • XOOPS is my life!

  • Posts: 2277

  • Since: 2003/11/7


Find the place where you're instantiating XoopsPageNav (for that page). It should look like this:

$... = new XoopsPageNav(...

7
ysbrasil
Re: changing module variables
  • 2005/8/17 12:16

  • ysbrasil

  • Just popping in

  • Posts: 5

  • Since: 2005/8/2 1


thanks. found it on /modules/news/article.php =)
but, strange enough, the var $items_perpage is set to 1..
i'll try and find out this time

Login

Who's Online

196 user(s) are online (112 user(s) are browsing Support Forums)


Members: 0


Guests: 196


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