Random block and featured photo block installation problems

boonkwee

Joined: 2003-02-12
Posts: 2
Posted: Wed, 2003-02-12 15:01

Hi All.

I have searched through the forum and have tried everything that has been mentioned but I'm still having difficulty adding a php-nuke block for random block or featured photo. I'll list my details below.

1. Running php-nuke 6.0 with gallery 1.3.3
2. I've read and followed the instructions (hopefully carefully) in all relevant posts. Mage changes to the various files as follows.

Step 1. added this line to block-combo.php
$GALLERY_BASEDIR = "$/home/boonkwee/public_html/photography/modules/gallery/";

Step 2. added these lines to theme.php for the theme I'm using.
function themesidebox($title, $content) {
if (@file_exists($content)) {
$fp = fopen ($content, "r");
$content = fread($fp, filesize($content));
fclose ($fp);
$content = "?>$content<?";
$content = eval($content);
} else if (eregi("^http", $content)) {
$fp = fopen ($content, "r");
$content = fread($fp, 65535);
fclose ($fp);
}

Step 3. added block-random.php to index.php

Step 4. created block using block admin and added the following url to content box
http://photography.mavenonline.com/modules.php?op=modload&amp;name=gallery&amp;file=index&amp;include=block-combo.php

Step 5. I receive this error message if I paste this url into the browser
Warning: main($/home/boonkwee/public_html/photography/modules/gallery/init.php) [function.main]: failed to create stream: No such file or directory in /home/boonkwee/public_html/photography/modules/gallery/block-combo.php on line 59

Fatal error: main() [function.main]: Failed opening required '$/home/boonkwee/public_html/photography/modules/gallery/init.php' (include_path='') in /home/boonkwee/public_html/photography/modules/gallery/block-combo.php on line 59

Step 6. I see a block containing the url if I load my page. Please http://photography.mavenonline.com

I'll be really grateful for any help. Please also point me to the right direction if I'm missing something here (like a detailed installation document or something).

Thank you thank you thank you!!!!

:???: :???: :???:

 
vpy

Joined: 2002-09-27
Posts: 18
Posted: Thu, 2003-02-13 02:13

Looks like the random block is working on your site! For the "combo" (featured photo + last updates), you would also need to add that file name to gallery's index.php list of permitted files. I just reposted the script I am using to make sure it was the most updated version. Maybe <!-- BBCode Start --><A HREF="http://www.kalorama.net/vyftp/block-combo.php.txt" TARGET="_blank">this version</A><!-- BBCode End --> will work for you (making edits as needed to include your domain/directories). As with the random photo block, I have it saved in my gallery directory and I use the same url type to call it from blocks admin. Sorry I can't help more. . .

 
Warren
Warren's picture

Joined: 2002-07-24
Posts: 794
Posted: Thu, 2003-02-13 17:15

Topic moved from PHP-Nuke or Post-Nuke Module

 
ClubCosmic
ClubCosmic's picture

Joined: 2002-12-29
Posts: 7
Posted: Fri, 2003-02-21 19:00

i had the same problem and resolved it by changing the lowercase g in the block content box to an uppercase g because my folder is modules/Gallery not modules/gallery.

good luck