| Author |
Message |
PaoloIV
User


Joined: Oct 07, 2004 Posts: 36
|
Posted: Tue Feb 22, 2005 2:10 pm Post subject: Problem with a newly installed gallery |
|
|
Ok here's what happened, I had allready a gallery installed on my oild phpnuke site, I deleted the old version 7.2 and installed the new 7.5 version, I installed the gallery too on this version but I left the old Albums directory, I configured the whole gallery and everything worked fine, now I can see perfectly the thumb images but if I click on an image of the gallery to enlarge it I get this error
Error: Requested index [0] out of bounds [374]
Fatal error: Call to a member function on a non-object in /web/htdocs/www.dwarf.it/home/modules/gallery/classes/Album.php on line 1258
----
Give us your Gallery/webserver information to get a faster answer.
Get this information from the PHP diagnostic (in the configuration wizard).
Gallery URL (optional but very useful): www.dwarf.it
Gallery version: 1.4.4 pl4
Graphics Toolkit:GD
Operating system: Linux
Web browser/version (if applicable): Explorer latest
thank you for your help |
|
| Back to top |
|
|
AdBot
|
| Post subject: Problem with a newly installed gallery |
|
|
|
|
|
| Back to top |
|
 |
dari
Site Admin


Joined: Mar 03, 2003 Posts: 6276 Location: Washington Township, NJ, USA
|
Posted: Wed Feb 23, 2005 7:39 am Post subject: Re: Problem with a newly installed gallery |
|
|
try running the gallery setup again and double checking all your paths. _________________
 |
|
| Back to top |
|
|
PaoloIV
User


Joined: Oct 07, 2004 Posts: 36
|
Posted: Wed Feb 23, 2005 9:02 am Post subject: Re: Problem with a newly installed gallery |
|
|
| wait I have an idea....where are the config settings stored? in the database or in a file? because I've a backup of both so I can simply replace the new one with the old one and if it's a config problem it shoiuld work fine.. |
|
| Back to top |
|
|
dari
Site Admin


Joined: Mar 03, 2003 Posts: 6276 Location: Washington Township, NJ, USA
|
Posted: Wed Feb 23, 2005 9:07 am Post subject: Re: Problem with a newly installed gallery |
|
|
the configuration itself is in the config.php file in your gallery directory. data files pertaining to users and albums are in the album.dat and user.dat files. _________________
 |
|
| Back to top |
|
|
PaoloIV
User


Joined: Oct 07, 2004 Posts: 36
|
Posted: Wed Feb 23, 2005 11:06 am Post subject: Re: Problem with a newly installed gallery |
|
|
config doesn't change anything
where's that album.dat file? I couldn't find it in the gallery main directory...
maybe this is the problem : for almost everypicture I added the author and a little description, if that's not stored in the albums folder maybe that lost it?
thanks for the help as always |
|
| Back to top |
|
|
dari
Site Admin


Joined: Mar 03, 2003 Posts: 6276 Location: Washington Township, NJ, USA
|
Posted: Wed Feb 23, 2005 11:15 am Post subject: Re: Problem with a newly installed gallery |
|
|
The album data files are in the album directory (and in each specific album's directory).
I would also recommend upgrading to 1.4.4-pl6 as well. This might solve your problem. _________________
 |
|
| Back to top |
|
|
PaoloIV
User


Joined: Oct 07, 2004 Posts: 36
|
Posted: Wed Feb 23, 2005 5:55 pm Post subject: Re: Problem with a newly installed gallery |
|
|
I only need to download the pl6 gallery or the pl5 too? ^^
sorry to bother but now that I have your attention on me I'm all warm  |
|
| Back to top |
|
|
PaoloIV
User


Joined: Oct 07, 2004 Posts: 36
|
Posted: Wed Feb 23, 2005 6:16 pm Post subject: Re: Problem with a newly installed gallery |
|
|
nutting nutting nutting, I upgraded it, but yet nothing happened... the weird thing is that it adds new pictures, it links them you can even see the thumbnails but you can't see the picture.... I tryed to upload a new picture it uploaded it perfectly I can see it trough ftp, I can link it but if I click on it that error comes out....
some other clue? |
|
| Back to top |
|
|
DanB
Beginner


Joined: Feb 24, 2005 Posts: 2 Location: Edinburgh Scotland
|
Posted: Thu Feb 24, 2005 4:06 am Post subject: Re: Problem with a newly installed gallery |
|
|
It's a problem with Nuke Sentinel and Gallery (specifically the Santy worm code).
I had the exact same problem on line 1258. There's a description and fix at http://ravenphpscripts.com/postt4165.html
Although - I fixed the error somewhat differently.
Based on what I could see, the variable $id is being used by two different process. So I changed the Santy worm fix with the following code (I'd like feedback if someone has a better idea):
Open includes/sentinel.php and find:
// Stop Santy Worm
$bad_uri_content="rush,highlight,perl,chr(,pillar,visualcoder,sess_";
global $REQUEST_URI;
$tmp=explode(",",$bad_uri_content);
while(list($id,$uri_content)=each($tmp)) {
if (strpos($REQUEST_URI,$uri_content)) {
die("Illegal Content");
}
}
I added two lines - one before and one after to save and then restore the variable $id
// Stop Santy Worm
$saveid = $id;
$bad_uri_content="rush,highlight,perl,chr(,pillar,visualcoder,sess_";
global $REQUEST_URI;
$tmp=explode(",",$bad_uri_content);
while(list($id,$uri_content)=each($tmp)) {
if (strpos($REQUEST_URI,$uri_content)) {
die("Illegal Content");
}
}
$id = $saveid;
Now both are working and I didn't have to disable the Nuke Sentinel Santy worm code  |
|
| Back to top |
|
|
PaoloIV
User


Joined: Oct 07, 2004 Posts: 36
|
Posted: Thu Feb 24, 2005 4:38 am Post subject: Re: Problem with a newly installed gallery |
|
|
IT WORKS!
thanks a lot, will it give me some problem on security?
Dari put it in the faq! ^^ it's too usefull if you have both sentinel and gallery installed |
|
| Back to top |
|
|
dari
Site Admin


Joined: Mar 03, 2003 Posts: 6276 Location: Washington Township, NJ, USA
|
Posted: Thu Feb 24, 2005 7:50 am Post subject: Re: Problem with a newly installed gallery |
|
|
Done. Added as FAQ C-4. _________________
 |
|
| Back to top |
|
|
PaoloIV
User


Joined: Oct 07, 2004 Posts: 36
|
Posted: Thu Feb 24, 2005 8:31 am Post subject: Re: Problem with a newly installed gallery |
|
|
| as always you'r able to solve my problems thanks to you and to nukedgallery.net |
|
| Back to top |
|
|
dari
Site Admin


Joined: Mar 03, 2003 Posts: 6276 Location: Washington Township, NJ, USA
|
Posted: Thu Feb 24, 2005 9:30 am Post subject: Re: Problem with a newly installed gallery |
|
|
hehe...thanks for the compliments. but it isn't just me....the success of NukedGallery is due in large part to all the great users out there who help out the others who have questions. _________________
 |
|
| Back to top |
|
|
DanB
Beginner


Joined: Feb 24, 2005 Posts: 2 Location: Edinburgh Scotland
|
Posted: Sat Jun 25, 2005 9:49 am Post subject: Re: Problem with a newly installed gallery |
|
|
Another update...
The code above restricts words like rush, highlight, perl, chr, etc... from the input string.
But, Gallery uses the word "highlight" when you try to "highlight a picture or album".
There are probably several work arounds. I simply took out the highlight as a restriction.
Here's my code now (below).
If someone wants to take the time to code a more elaborate solution, then please post it.
Cheers - Dan
// Stop Santy Worm
$saveid = $id;
$bad_uri_content="rush,perl,chr(,pillar,visualcoder,sess_";
global $REQUEST_URI;
$tmp=explode(",",$bad_uri_content);
while(list($id,$uri_content)=each($tmp)) {
if (strpos($REQUEST_URI,$uri_content)) {
die("Illegal Content");
}
}
$id = $saveid; |
|
| Back to top |
|
|
dari
Site Admin


Joined: Mar 03, 2003 Posts: 6276 Location: Washington Township, NJ, USA
|
Posted: Mon Jun 27, 2005 6:23 am Post subject: Re: Problem with a newly installed gallery |
|
|
one of the reasons that "highlight" was included was because of a phpBB exploit involving the highlight code. if your version of phpBB is up to date, you can (i think) safely remove highlight from the list. _________________
 |
|
| Back to top |
|
|
|
|
|
|
|