Author |
Message |
majk
New Member


Joined: Dec 10, 2004
Posts: 15
|
Posted:
Tue Jan 04, 2005 12:17 am |
|
I´ve tried for some time to get Coppermine and phpNuke 7.5 to work together but I didnt managed to integrate Coppermine with phpNuke.
I have come uo with a temorary solution to my problem but im not pleased with it because that people that has popup killers is not able to see my Photoalbum.
Here is my solution.
First I created a directory in blocks that I named Coppermine and in this I placed a index.php looked like this:
Code:<HT ML><BO DY>
<SCR IPT LANGUAGE="JAVASC RIPT">
<!--
function WinOpen() {
open("http://www..petersb.org/Coppermine/index.php","Window1");
}
//-->
</SCR IPT>
<HT ML><BO DY onLoad="WinOpen()">
</BO DY></H TML>
<?php
/************************************************************************/
/* PHP-NUKE: Advanced Content Management System */
/* ============================================ */
/* */
/* Copyright (c) 2002 by Francisco Burzi */
/* http://phpnuke.org */
/* */
/* This program is free software. You can redistribute it and/or modify */
/* it under the terms of the GNU General Public License as published by */
/* the Free Software Foundation; either version 2 of the License. */
/************************************************************************/
require_once("mainfile.php");
$_SERVER['PHP_SELF'] = "modules.php";
$sql = "SELECT main_module from ".$prefix."_main";
$result = $db->sql_query($sql);
$row = $db->sql_fetchrow($result);
$name = $row[main_module];
$home = 1;
if ($httpref==1) {
$referer = $_SERVER["HTTP_REFERER"];
$referer = check_html($referer, nohtml);
if ($referer=="" OR eregi("^unknown", $referer) OR substr("$referer",0,strlen($nukeurl))==$nukeurl OR eregi("^bookmark",$referer)) {
} else {
$sql = "INSERT INTO ".$prefix."_referer VALUES (NULL, '$referer')";
$result = $db->sql_query($sql);
}
$sql = "SELECT * FROM ".$prefix."_referer";
$result = $db->sql_query($sql);
$numrows = $db->sql_numrows($result);
if($numrows>=$httprefmax) {
$sql = "DELETE FROM ".$prefix."_referer";
$result = $db->sql_query($sql);
}
}
if (!isset($mop)) { $mop="modload"; }
if (!isset($mod_file)) { $mod_file="index"; }
if (ereg("\.\.",$name) || ereg("\.\.",$file) || ereg("\.\.",$mod_file) || ereg("\.\.",$mop)) {
echo "You are so cool...";
} else {
$ThemeSel = get_theme();
if (file_exists("themes/$ThemeSel/module.php")) {
include("themes/$ThemeSel/module.php");
if (is_active("$default_module") AND file_exists("modules/$default_module/$mod_file.php")) {
$name = $default_module;
}
}
if (file_exists("themes/$ThemeSel/modules/$name/$mod_file.php")) {
$modpath = "themes/$ThemeSel/";
}
$modpath .= "modules/$name/$mod_file.php";
if (file_exists($modpath)) {
include($modpath);
} else {
$index = 1;
include("header.php");
OpenTable();
if (is_admin($admin)) {
echo "<center><font class=\"\"><b>"._HOMEPROBLEM."</b></font><br><br>[ <a href=\"admin.php?op=modules\">"._ADDAHOME."</a> ]</center>";
} else {
echo "<center>"._HOMEPROBLEMUSER."</center>";
}
CloseTable();
include("footer.php");
}
}
?>
|
I has uploaded my Coppermine album into the modules Directory where I named the directory to Coppermine. You can see it for your self at www.petersb.org and look to the left for Fotoalbum, the page is in swedish so you may be having problem with finding your way ;o) |
|
|
|
 |
TheosEleos
Life Cycles Becoming CPU Cycles

Joined: Sep 18, 2003
Posts: 960
Location: Missouri
|
Posted:
Tue Jan 04, 2005 9:14 am |
|
|
 |
 |
majk

|
Posted:
Tue Jan 04, 2005 11:05 am |
|
TheosElos
Yes! That exact how I would like it to works as it does on your site but Im only getting my Photoalbum in a blank window. |
|
|
|
 |
sixonetonoffun
Spouse Contemplates Divorce

Joined: Jan 02, 2003
Posts: 2496
|
Posted:
Tue Jan 04, 2005 11:46 am |
|
TheosEleos does the search function work in that version? |
_________________ [b][size=5]openSUSE 11.4-x86 | Linux 2.6.37.1-1.2desktop i686 | KDE: 4.6.41>=4.7 | XFCE 4.8 | AMD Athlon(tm) XP 3000+ | MSI K7N2 Delta-L | 3GB Black Diamond DDR
| GeForce 6200@433Mhz 512MB | Xorg 1.9.3 | NVIDIA 270.30[/size:2b8 |
|
|
 |
TheosEleos

|
Posted:
Tue Jan 04, 2005 2:05 pm |
|
I don't know. I just tried about 5 searches and never turned up anything. I searched for titles I knew existed and image names I knew existed.
Majk, I'm sorry, I don't know how to help you with your problem.  |
|
|
|
 |
majk

|
Posted:
Tue Jan 04, 2005 2:55 pm |
|
TheosEleos
You did! Thanks! I downloaded your version of Coppermine and installed it and then it worked exactly as I wished.
Thanks alot for the help man. |
|
|
|
 |
TheosEleos

|
Posted:
Thu Jan 06, 2005 10:25 am |
|
|
|
 |
majk

|
Posted:
Fri Jan 07, 2005 7:45 am |
|
TheosEleos
Now some new problem shown, I cant switch language and theme. It´s swedish in default installation and nothing wrong with that but some characters is not shown as they should.
Do you have any idea how I can change the theme and language? |
Last edited by majk on Sat Jan 08, 2005 12:56 pm; edited 1 time in total |
|
|
 |
TheosEleos

|
Posted:
Fri Jan 07, 2005 9:23 am |
|
|
|
 |
HardStyleMaster
New Member


Joined: Mar 12, 2005
Posts: 1
|
Posted:
Sat Mar 12, 2005 1:11 pm |
|
I have been trying to get ver 1.3.2 of Coppermine integrated into ver 7.5 PHP-Nuke for some time now; although I have been unable to get it working in full integration mode - I have been successful at getting it to work in stand-alone mode. (which simply means if people want to use it, they have to register within it)
I created a block script that enabled me to link from nuke directly to the Gallery.
Code:<?
if (eregi("block-Gal.php",$_SERVER['PHP_SELF'])) {
Header("Location: index.php");
die();
}
$content .= "<strong><big>·</big></strong><a href=\"Gallery\index.php\"> Gallery</a><br>\n";
?>
|
But if you're going to go this way, make sure you remove the code in both the installer and index files for coppermine that check for the stand-alone feature... otherwise it will never work.
I have done this twice now on 2 separate nuke sites - both work great. Hope this helps someone else out there - cuz it took me forever to figure this all out!! |
|
|
|
 |
tomg
New Member


Joined: May 29, 2005
Posts: 1
|
Posted:
Sun May 29, 2005 5:33 pm |
|
HardStyleMaster wrote: |
I created a block script that enabled me to link from nuke directly to the Gallery.
Code:<?
if (eregi("block-Gal.php",$_SERVER['PHP_SELF'])) {
Header("Location: index.php");
die();
}
$content .= "<strong><big>·</big></strong><a href=\"Gallery\index.php\"> Gallery</a><br>\n";
?>
|
But if you're going to go this way, make sure you remove the code in both the installer and index files for coppermine that check for the stand-alone feature... otherwise it will never work.
I have done this twice now on 2 separate nuke sites - both work great. Hope this helps someone else out there - cuz it took me forever to figure this all out!! | Hardstylemaster:
I am new to this- can you tell me exactly where to put this script?
Thanks |
|
|
|
 |
|