BLOG:CMS :: Support Forum

Support Forum for BLOG:CMS

You are not logged in.

#1 30.12.2006 01:47

inter981
newbie...
Registered: 22.05.2006
Posts: 9

HELP !!! sort in NP_MiniForum

I used NP_MiniForum to build a page -like a guestbook- where i recolect people signs for a benefict act, like:

Name: John Smith
e-mail: smith@smith.com
Passport #: 5467567675

when i publish the data result in the page (hidding the passport # to the public but not to the owner to the blog -to avoid data thiefs-), it apperars:

1 Max Joel [03/01/01 12:12]
2 John Smith [02/01/01 12:12]
3 Sabrina Morris [01/01/01 12:12]

Max was the latest one signing the guestbook -the first in the list-...  How can i do (editting the php file or something) to invert the sort (latest in the bottom).

How to change the Locale timestamp to "time () + 7:00 h." ?

Any way to print the full list -in a printer- when i finish the project ??

ps: Excuse me if my english is not perfect, because i'm Spanish.
THANKYOU VERY MUCH

Offline

 

#2 30.12.2006 14:29

Radek Hulán
Site Admin
From: Prague, Czech Republic
Registered: 17.03.2004
Posts: 2509
Website

Re: HELP !!! sort in NP_MiniForum

To sort in a different order, just modify SQL query, use "ORDER BY ... DESC" or "ORDER BY ... ASC". To change time +7 hours, simply add time() + 60*60*7 (time is in seconds)


--= BLOG:CMS developer =--

Offline

 

#3 31.12.2006 13:12

inter981
newbie...
Registered: 22.05.2006
Posts: 9

Re: HELP !!! sort in NP_MiniForum

Thankyou very much.

it worked modifying the line #351

"VALUES (".$forumId.",'".$uname."','".$url."','".$body."',".time()."+ 60*60*7,".$memberid.")";

about the sorting... i did what u said (when db had 8 entries entered) and Now i have a strange order in MySQL database sorted by id:
id#: 8, 7, 6, 5, 4, 3, 2, 1, 9, 10, 11, ...

and it shows in the list (MiniForum shown) as it nothing happened... latest first. :-(

thankyou anyway,
regards from Spain

Offline

 

Board footer

Powered by PunBB
© Copyright 2002–2005 Rickard Andersson

TOPlist