Subject:*
<
Name/Email:*
<
Message Icon:*
<
Select*
<
Message:*
<



Click the Preview to see the content in action.
Options:*
<
Confirmation Code*
<
7 - 1 = ?  
Input the result from the expression
Maximum attempts you can try: 10
*
<
     

Re: XoopsGallery Fixes.. Recent Comments Link, New Pics Block showing thumbnail, etc...
by ik2xnw on 2007/5/23 14:27:00

I had such output, whilst trying to see full sized images.

I remembered that in the Protector Preferences panel, somewhat sounded like this:

"All requests named "*id" will be treated as integer.
This option protects you from some kind of XSS and SQL Injections.
Though I recommend to turn this option on, it can cause problems with some modules."

Switched that setting to "no", solved my problem.
Re: XoopsGallery Fixes.. Recent Comments Link, New Pics Block showing thumbnail, etc...
by gstarrett on 2003/11/14 18:41:39

Quote:

shinybt wrote:
which stats module u were saying? sorry, this was the 3rd days for me to play this XOOPS and gallery. It was a 1st php portal for me also.. >.<


It's called "Statistics", by Mispunt. The readme instructs you to as follows:
Quote:
Installation. |
--------------------------------

After installing the normal module, you have to modify some files.
First you must at in the file "header.php" (which is in the root directory) under:

include_once XOOPS_ROOT_PATH.'/class/xoopsblock.php';

the line:

include_once("modules/statistics/include/counter.php");

Whith this peace of code the website add information of the hits to the database, so
you can view them in the admin section.


I've been able to patch the include file so it doesn't stomp on variables. All the patch does is isolate the routine from the global variables by putting it into a funciton instead of inline.

Modify 2 places. Add the line in red to the TOP of the file to look like this:
<?php [color=FF0000][b]function statistics_counter_countpage() {[/b][/color] /********************************************************************/ /* File: counter.php */ /* Directory: ./include/ */ ...


... now add the 2 lines in red at the BOTTOM to look like this:

le="color: #000000"><?php ... else { $xoopsDB->queryF("INSERT INTO ".$xoopsDB->prefix("statistics_ip")." (ip, date, hits) VALUES ('$ip', '$now_ip', '1')"); } [color=FF0000][b]} statistics_counter_countpage();[/b][/color] ?>


I'll send the author the full patch also, so he can update his code. I won't be posting a patched version since I don't know if I have the latest or not.


Another tip while I'm in there anyway... If you change
le="color: #000000"><?php $ip = $HTTP_SERVER_VARS['REMOTE_ADDR'];


to (all on a single line):

le="color: #000000"><?php $ip = isset($_SERVER["REMOTE_ADDR"]) ? $_SERVER["REMOTE_ADDR"] : $HTTP_SERVER_VARS['REMOTE_ADDR'];


it'll get IP addresses properly while running on Apache too.
Re: XoopsGallery Fixes.. Recent Comments Link, New Pics Block showing thumbnail, etc...
by shinybt on 2003/11/14 18:15:51

Quote:

That can be caused by not updating, but there is a statistics module that will cause that too. Removing the statistics module has fixed the problem for others.


which stats module u were saying? sorry, this was the 3rd days for me to play this XOOPS and gallery. It was a 1st php portal for me also.. >.<
Re: XoopsGallery Fixes.. Recent Comments Link, New Pics Block showing thumbnail, etc...
by gstarrett on 2003/11/14 18:10:40

Quote:
ERROR: requested index [] out of bounds [2]


That can be caused by not updating, but there is a statistics module that will cause that too. Removing the statistics module has fixed the problem for others.

(Surprised you didn't recognize that one, gnik )
Re: XoopsGallery Fixes.. Recent Comments Link, New Pics Block showing thumbnail, etc...
by shinybt on 2003/11/14 17:41:54

my bad, forgot to mentioned I did "updated" them as well. Had tried to re-update once again. and the bug still bugging me badly...

any idea?

Who's Online

192 user(s) are online (137 user(s) are browsing Support Forums)


Members: 0


Guests: 192


more...

Donat-O-Meter

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

Latest GitHub Commits