**EDIT** just to be clear, this plugin works in Wordpress MU as a standard plugin - it does not work as a wordpress mu plugin, but at least you can install it now
I have included the entire options.php file here for your reference. Copy the contents below into the "options.php" file and then replace the one on your server with the new one.
- Code: Select all
<?php
$location = $options_page; // Form Action URI
/****************************************************
** changed the way the options are created on the database. **
*****************************************************/
if (isset($_POST['updateOptions'])) {
if (get_option('gallery-width') || get_option('gallery-width') == '')
update_option('gallery-width',$_POST['gallery-width']);
else
add_option('gallery-width',$_post['gallery-width']);
if (get_option('gallery-height') || get_option('gallery-height') == '')
update_option('gallery-height',$_POST['gallery-height']);
else
add_option('gallery-height',$_post['gallery-height']);
if (get_option('gallery-info') || get_option('gallery-info') == '')
update_option('gallery-info',$_POST['gallery-info']);
else
add_option('gallery-info',$_post['gallery-info']);
if (get_option('gallery-items') || get_option('gallery-items') == '')
update_option('gallery-items',$_POST['gallery-items']);
else
add_option('gallery-items',$_post['gallery-items']);
if (get_option('gallery-border-color') || get_option('gallery-border-color') == '')
update_option('gallery-border-color',$_POST['gallery-border-color']);
else
add_option('gallery-border-color',$_post['gallery-border-color']);
if (get_option('gallery-bg-color') || get_option('gallery-bg-color') == '')
update_option('gallery-bg-color',$_POST['gallery-bg-color']);
else
add_option('gallery-bg-color',$_post['gallery-bg-color']);
if (get_option('gallery-text-color') || get_option('gallery-text-color') == '')
update_option('gallery-text-color',$_POST['gallery-text-color']);
else
add_option('gallery-text-color',$_post['gallery-text-color']);
if (get_option('gallery-use-featured-content') || get_option('gallery-use-featured-content') == '')
update_option('gallery-use-featured-content',$_POST['gallery-use-featured-content']);
else
add_option('gallery-use-featured-content',$_post['gallery-use-featured-content']);
if (get_option('gallery-use-thumb-image') || get_option('gallery-use-thumb-image') == '')
update_option('gallery-use-thumb-image',$_POST['gallery-use-thumb-image']);
else
add_option('gallery-use-thumb-image',$_post['gallery-use-thumb-image']);
if (get_option('gallery-way') || get_option('gallery-way') == '')
update_option('gallery-way',$_POST['gallery-way']);
else
add_option('gallery-way',$_post['gallery-way']);
if (get_option('gallery-items-pages') || get_option('gallery-items-pages') == '')
update_option('gallery-items-pages',$_POST['gallery-items-pages']);
else
add_option('gallery-items-pages',$_post['gallery-items-pages']);
if (get_option('gallery-category') || get_option('gallery-category') == '')
update_option('gallery-category',$_POST['gallery-category']);
else
add_option('gallery-category',$_post['gallery-category']);
if (get_option('gallery-fcg-button') || get_option('gallery-fcg-button') == '')
update_option('gallery-fcg-button',$_POST['gallery-fcg-button']);
else
add_option('gallery-fcg-button',$_post['gallery-fcg-button']);
if (get_option('gallery-fade-duration') || get_option('gallery-fade-duration') == '')
update_option('gallery-fade-duration',$_POST['gallery-fade-duration']);
else
add_option('gallery-fade-duration',$_post['gallery-fade-duration']);
if (get_option('gallery-delay') || get_option('gallery-delay') == '')
update_option('gallery-delay',$_POST['gallery-delay']);
else
add_option('gallery-delay',$_post['gallery-delay']);
if (get_option('gallery-randomize-pages') || get_option('gallery-randomize-pages') == '')
update_option('gallery-randomize-pages',$_POST['gallery-randomize-pages']);
else
add_option('gallery-randomize-pages',$_post['gallery-randomize-pages']);
if (get_option('gallery-rss-word-quantity') || get_option('gallery-rss-word-quantity') == '')
update_option('gallery-rss-word-quantity',$_POST['gallery-rss-word-quantity']);
else
add_option('gallery-rss-word-quantity',$_post['gallery-rss-word-quantity']);
if (get_option('gallery-default-transaction') || get_option('gallery-default-transaction') == '')
update_option('gallery-default-transaction',$_POST['gallery-default-transaction']);
else
add_option('gallery-default-transaction',$_post['gallery-default-transaction']);
}?>
<div class="wrap">
<h2>Featured Content Gallery Configuration</h2>
<p>Use the options below to select the content for your gallery, to style your gallery, and to configure the gallery slides and transitions.<br />
Visit the <a href="http://www.featuredcontentgallery.com">Featured Content Gallery Plugin</a> website for more information.</p>
<form method="post" action="<?php echo $location?>"> <?php //changed this to $location and removed the nonce form stuff ?>
<fieldset name="general_options" class="options">
<div style="padding-top: 15px"></div>
<u><strong>Featured Content Gallery Code</strong></u> - If not already included, add this code to your template file where you want the Featured Content Gallery to be displayed:<br />
<blockquote><?php include (ABSPATH . '/wp-content/plugins/featured-content-gallery/gallery.php'); ?></blockquote>
<div style="padding-top: 10px"></div>
<?php $galleryoldway = (get_option('gallery-way') == 'old' || get_option('gallery-way') == '') ? "checked" : "";
$gallerynewway = get_option('gallery-way') == 'new' ? "checked" : "";
?>
<u><strong>Featured Content Selection</strong></u> - Select either a blog category or individual post/page IDs for your featured content:<br />
<div style="padding-top: 5px"></div>
<table width="690" border="0" cellpadding="0" cellspacing="7">
<tr>
<td width="330">
<input type="radio" name="gallery-way" id="gallery-way" size="25" value="old" <?php print $galleryoldway; ?>>
Select here to use category selection
</td>
<td width="360">
<input type="radio" name="gallery-way" id="gallery-way" size="25" value="new" <?php print $gallerynewway; ?>>
Select here to use individual post or page IDs
</td>
</tr>
<tr>
<td>
Category Name:<br />
<input name="gallery-category" id="gallery-category" size="25" value="<?php echo get_option('gallery-category'); ?>"></input>
</td>
<td>
Post or Page IDs <span class="style1">(comma separated no spaces)</span>:<br />
<input name="gallery-items-pages" id="gallery-items-pages" size="25" value="<?php echo get_option('gallery-items-pages'); ?>"></input>
</td>
</tr>
<tr>
<td>
Number of Items to Display:<br />
<input name="gallery-items" id="gallery-items" size="25" value="<?php echo get_option('gallery-items'); ?>"></input>
</td>
<td>
<?php $checked3 = get_option('gallery-randomize-pages') ? "checked" : ""; ?>
<input type="checkbox" name="gallery-randomize-pages" id="gallery-randomize-pages" <?php print $checked3 ?>>
Check here to randomize post/page ID display
</td>
</tr>
</table>
<div style="padding-top: 10px"></div>
<u><strong>Gallery Style</strong></u> - Choose your gallery size and colors:<br />
<div style="padding-top: 10px"></div>
<table width="690" border="0" cellpadding="0" cellspacing="7">
<tr>
<td width="330">
Gallery Width in Pixels:<br />
<input name="gallery-width" id="gallery-width" size="25" value="<?php echo get_option('gallery-width'); ?>"></input>
</td>
<td width="360">
Gallery Border Color (#hex or color name):<br />
<input name="gallery-border-color" id="gallery-border-color" size="25" value="<?php echo get_option('gallery-border-color'); ?>"></input>
</td>
</tr>
<tr>
<td>
Gallery Height in Pixels:<br />
<input name="gallery-height" id="gallery-height" size="25" value="<?php echo get_option('gallery-height'); ?>"></input>
</td>
<td>
Gallery Background Color (#hex or color name):<br />
<input name="gallery-bg-color" id="gallery-bg-color" size="25" value="<?php echo get_option('gallery-bg-color'); ?>"></input>
</td>
</tr>
<tr>
<td>
Text Overlay Height in Pixels:<br />
<input name="gallery-info" id="gallery-info" size="25" value="<?php echo get_option('gallery-info'); ?>"></input>
</td>
<td>
Gallery Text Color (#hex or color name):<br />
<input name="gallery-text-color" id="gallery-text-color" size="25" value="<?php echo get_option('gallery-text-color'); ?>"></input>
</td>
</tr>
</table>
<div style="padding-top: 10px"></div>
<u><strong>Slide Transition Times and Other Options</strong></u> - Choose your slide and fade duration, carousel button name and text overlay word quantity:<br />
<div style="padding-top: 10px"></div>
<table width="690" border="0" cellpadding="0" cellspacing="10">
<tr>
<td width="330">
Slide Display Duration (milliseconds):<br />
<input name="gallery-delay" id="gallery-delay" size="25" value="<?php echo get_option('gallery-delay'); ?>"></input><br />
(Default: 9000 milliseconds / 9 seconds)
</td>
<td width="360">
Carousel Button Name:<br />
<input name="gallery-fcg-button" id="gallery-fcg-button" size="25" value="<?php echo get_option('gallery-fcg-button'); ?>"></input><br />
(Default: "Featured Content")
</td>
</tr>
<tr>
<td>
Slide Fade Duration (milliseconds):<br />
<input name="gallery-fade-duration" id="gallery-fade-duration" size="25" value="<?php echo get_option('gallery-fade-duration'); ?>"></input><br />
(Default: 500 milliseconds / .5 seconds)
</td>
<td>
Number of Words in Text Overlay:<br />
<input name="gallery-rss-word-quantity" id="gallery-rss-word-quantity" size="25" value="<?php echo get_option('gallery-rss-word-quantity'); ?>"></input><br />
(Default: 100 words)
</td>
</tr>
</table>
<div style="padding-top: 10px"></div>
<u><strong>Slide Transition Type</strong></u> - Choose your slide transition effect:<br />
<div style="padding-top: 10px"></div>
<?php $galleryfade = (get_option('gallery-default-transaction') == 'fade' || get_option('gallery-default-transaction') == '') ? "checked" : "";
$galleryfadeslideleft = get_option('gallery-default-transaction') == 'fadeslideleft' ? "checked" : "";
$gallerycontinuoushorizontal = get_option('gallery-default-transaction') == 'continuoushorizontal' ? "checked" : "";
$gallerycontinuousvertical = get_option('gallery-default-transaction') == 'continuousvertical' ? "checked" : "";
?>
<table width="500" border="0" cellpadding="0" cellspacing="10">
<tr>
<td width="250">
<input type="radio" name="gallery-default-transaction" id="gallery-default-transaction" size="25" value="fade" <?php print $galleryfade; ?>> Simple Fade
</td>
<td width="250">
<input type="radio" name="gallery-default-transaction" id="gallery-default-transaction" size="25" value="fadeslideleft" <?php print $galleryfadeslideleft; ?>> Slide Left with Fade
</td>
</tr>
<tr>
<td>
<input type="radio" name="gallery-default-transaction" id="gallery-default-transaction" size="25" value="continuoushorizontal" <?php print $gallerycontinuoushorizontal; ?>> Continuous Horizontal
</td>
<td>
<input type="radio" name="gallery-default-transaction" id="gallery-default-transaction" size="25" value="continuousvertical" <?php print $gallerycontinuousvertical; ?>> Continuous Vertical
</td>
</tr>
</table>
<div style="padding-top: 10px"></div>
<u><strong>Required Custom Fields</strong></u>
<div style="padding-top: 5px"></div>
For each post or page you want to display in your gallery, regardless of your selections above, you <strong>must</strong> include a custom field. For the main gallery image, use the key <strong>articleimg</strong> and the full url of your image in the value. You <strong>must</strong> have at least two (2) items featured for the gallery to work.
<div style="padding-top: 10px"></div>
<u><strong>Advanced Custom Fields</strong></u>
<div style="padding-top: 5px"></div>
<?php $checked1 = get_option('gallery-use-featured-content') ? "checked" : ""; ?>
<input type="checkbox" name="gallery-use-featured-content" id="gallery-use-featured-content" <?php print $checked1 ?>>
Check here if you want to use custom text under the post/page title.<br />
Key: <strong>featuredtext</strong> - Insert custom text in the value. HTML is allowed.
<div style="padding-top: 10px"></div>
<?php $checked2 = get_option('gallery-use-thumb-image') ? "checked" : ""; ?>
<input type="checkbox" name="gallery-use-thumb-image" id="gallery-use-thumb-image" <?php print $checked2 ?>>
Check here if you want to use a custom thumbnail image in your gallery.<br />
Key: <strong>thumbnailimg</strong> - Insert the url of the image in the value.
<div style="padding-top: 5px"></div>
You can also add alt text to your gallery images with a custom field.<br />
Key: <strong>alttext</strong> - Insert the alt text in the value.
<div style="padding-top: 15px"></div>
For more information, please visit the <a href="http://www.featuredcontentgallery.com/install-setup">Featured Content Gallery Install & Setup</a> page.
</fieldset>
<p class="submit"><input type="submit" name="updateOptions" value="<?php _e('Update Options') //changed the name of the submit button to updateOptions?>" /></p>
<p><em>Featured Content Gallery WordPress Plugin v3.2.0 by <a href="http://www.ieplexus.com">iePlexus</a></em></p>
</form>
</div>
Hope this helps somebody out
Flash









