Advanced search  


cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.

Pages: [1]   Go Down

Author Topic: <?php include 'gallery/index.php'; ?>  (Read 13914 times)

0 Members and 1 Guest are viewing this topic.


  • Coppermine newbie
  • Offline Offline
  • Posts: 3
<?php include 'gallery/index.php'; ?>
« on: November 29, 2003, 07:59:57 am »

I would like to have my gallery displayed alongside my homepage's main content without using IFRAMES, as shown in this example:

So I use the following PHP code to include the gallery index on my homepage <?php include 'gallery/index.php'; ?>

However, I am getting errors:

When my homepage is in a DIFFERENT directory as that of the gallery:

Warning: main(include/ failed to open stream: No such file or directory in /home/ml/public_html/www/gallery/include/ on line 135

Fatal error: main(): Failed opening required 'include/' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/ml/public_html/www/gallery/include/ on line 135

When I put the homepage in the SAME directory as the gallery:

Warning: Cannot modify header information - headers already sent by (output started at /home/ml/public_html/www/gallery/index2.php:7) in /home/mlin/public_html/www/gallery/themes/water_drop/theme.php on line 790

Warning: Cannot modify header information - headers already sent by (output started at /home/ml/public_html/www/gallery/index2.php:7) in /home/ml/public_html/www/gallery/include/ on line 51

Any ideas on how to fix this? Thanks a lot!

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47844
  • aka "GauGau"
<?php include 'gallery/index.php'; ?>
« Reply #1 on: November 29, 2003, 10:06:58 am »

well, simply speaking: you can't php-include coppermine! Instead, you'll have to modify the looks of your homepage to fit into the overall theme of coppermine (or change the coppermine theme to look like the rest of your homepage, your choice). If you're not familiar with the errors you got I say don't try experimenting with php-includes at all, since they are most familiar and should already point you into the right direction. If you want to find out about the "why"s, take a deep look at, but in fact you can just forget about the include stuff and try my recommendation from the first paragraph...

Pages: [1]   Go Up

Page created in 0.016 seconds with 18 queries.