Featured Content Gallery | WordPress Plugin | iePlexus

Featured content breaking code in header

New releases, ideas for the future, and known issues

Featured content breaking code in header

PostBy chris_777 on Tue Jun 29, 2010 8:03 pm

Hello,

I have used featured content several times and love it! However this time I am having trouble with it. I am using wordpress 3.0 with the twentyten theme. I am trying to paste the code <?php include (ABSPATH . '/wp-content/plugins/featured-content-gallery/gallery.php'); ?> into the header to replace the header image with the featured content gallery. I have placed it everyplace I can think to place it. For some reason it always "page not found" when I refresh the page.

Can anyone help me?

Best Regards,
Chris_777
chris_777
 
Posts: 1
Joined: Tue Jun 29, 2010 7:58 pm

Re: Featured content breaking code in header

Thank you for using the Featured Content Gallery Forum
 

Re: Featured content breaking code in header

PostBy Grumpy on Mon Jul 05, 2010 4:24 pm

The value of ABSPATH is defined in script file wp-load.php in the WP root directory :
Code: Select all
/** Define ABSPATH as this files directory */
define( 'ABSPATH', dirname(__FILE__) . '/' );


To check and display the full path of your include, insert one of the following in header.php of the template, right before the include line you are adding :
Code: Select all
<?php
echo '<br />'
var_dump( ABSPATH );
echo '<br />'
echo ABSPATH . '/wp-content/plugins/featured-content-gallery/gallery.php';
// exit();
?>
OR :
Code: Select all
<?php
print '<br />'
var_dump( ABSPATH );
print '<br />'
print ABSPATH . '/wp-content/plugins/featured-content-gallery/gallery.php';
// exit();
?>
<?php include (ABSPATH . '/wp-content/plugins/featured-content-gallery/gallery.php'); ?>
Grumpy
 
Posts: 5
Joined: Mon Jun 28, 2010 4:27 pm
Location: .nl


Return to Development, Improvement, and Conflicts

Who is online

Users browsing this forum: No registered users and 0 guests