function spa_toolbox_housekeeping_form() { ?> <script type="text/javascript"> jQuery(document).ready(function() { spjAjaxForm('sfindexes', 'sfreloadhk'); spjAjaxForm('sfnewpostcleanup', 'sfreloadhk'); spjAjaxForm('sftransientcleanup', 'sfreloadhk'); spjAjaxForm('sfpostcountcleanup', 'sfreloadhk'); spjAjaxForm('sfresetprofiletabs', 'sfreloadhk'); spjAjaxForm('sfresetauths', 'sfreloadhk'); spjAjaxForm('sfresetplugdata', 'sfreloadhk'); spjAjaxForm('sfresetcombined', 'sfreloadhk'); spjAjaxForm('sfflushcache', 'sfreloadhk'); <?php do_action('sph_toolbox_housekeeping_ajax'); ?> }); </script> <?php $ahahURL = SFHOMEURL . 'index.php?sp_ahah=toolbox-loader&sfnonce=' . wp_create_nonce('forum-ahah') . '&saveform=housekeeping'; ?> <form action="<?php echo $ahahURL; ?> " method="post" id="sfhousekeepingform" name="sfhousekeeping"> </form> <?php spa_paint_options_init(); spa_paint_open_tab(spa_text('Toolbox') . ' - ' . spa_text('Housekeeping')); spa_paint_open_panel(); spa_paint_open_fieldset(spa_text('Rebuild Indexes'), true, 'rebuild-indexes'); echo '<p class="sublabel">' . spa_text("You shouldn't need to rebuild your indexes unless asked to by Simple:Press Support.") . '</p>'; ?> <form action="<?php echo $ahahURL; ?> " method="post" id="sfindexes" name="sfindexes"> <?php echo sp_create_nonce('forum-adminform_housekeeping'); ?> <p class="sublabel"><?php spa_etext('Select forum to have its indexes rebuilt'); ?> :<br /><br /></p> <select class="wp-core-ui" name="forum_id" > <?php echo sp_render_group_forum_select(false, false, false, true, '', '', 'wp-core-ui', 20); ?> </select> <br /><br /> <input type="submit" class="button-primary" id="saveit1" name="rebuild-fidx" value="<?php spa_etext('Rebuild Forum Indexes'); ?> " onclick="jQuery('#riimg').show();"/> <img class="sfhidden" id="riimg" src="<?php echo SFCOMMONIMAGES . 'working.gif'; ?> " alt=""/> </form> <?php echo '<p class="sublabel">' . spa_text('Note: Rebuilding the forum indexes may take some time if you have a large number of topics or posts.') . '</p>'; spa_paint_close_fieldset(); spa_paint_close_panel(); spa_paint_open_panel(); spa_paint_open_fieldset(spa_text('New Post Cleanup'), true, 'newpost-cleanup'); echo '<p class="sublabel">' . spa_text('This will reset the New Posts list for users who haven not visited the forum in the specified number of days.') . '</p>'; ?> <form action="<?php echo $ahahURL; ?> " method="post" id="sfnewpostcleanup" name="sfnewpostcleanup"> <?php echo sp_create_nonce('forum-adminform_housekeeping'); ?> <span>Number of Days Since User's Last Visit: <input class="wp-core-ui" type="text" value="30" name="sfdays" /></span> <br /> <input type="submit" class="button-primary" id="saveit2" name="clean-newposts" value="<?php spa_etext('Clean New Posts List'); ?> " onclick="jQuery('#npcimg').show();"/> <img class="sfhidden" id="npcimg" src="<?php echo SFCOMMONIMAGES . 'working.gif'; ?> " alt=""/> </form> <?php echo '<p>' . spa_text('Note: Cleaning up the New Post Lists may take some time if you have a large number of users that meet the criteria.') . '</p>'; spa_paint_close_fieldset(); spa_paint_close_panel(); spa_paint_open_panel(); spa_paint_open_fieldset(spa_text('User Post Count Cleanup'), true, 'post-count-cleanup'); echo '<p class="sublabel">' . spa_text('This will go through the users and posts database tables and recalculate post counts for all users based on existing posts.') . '</p>'; ?> <form action="<?php echo $ahahURL; ?> " method="post" id="sfpostcountcleanup" name="sfpostcountcleanup"> <?php echo sp_create_nonce('forum-adminform_housekeeping'); ?> <br /> <input type="submit" class="button-primary" id="saveit3" name="postcount-cleanup" value="<?php spa_etext('Clean Up Post Counts'); ?> " onclick="jQuery('#pcimg').show();"/> <img class="sfhidden" id="pcimg" src="<?php echo SFCOMMONIMAGES . 'working.gif'; ?> " alt=""/> </form> <?php echo '<p class="sublabel">' . spa_text('Note: Recalculating user post counts may take some time if you have a large number of users and cannot be reversed.') . '</p>'; spa_paint_close_fieldset(); spa_paint_close_panel(); do_action('sph_toolbox_housekeeping_left_panel'); spa_paint_tab_right_cell(); spa_paint_open_panel(); spa_paint_open_fieldset(spa_text('Transient Cleanup'), true, 'transient-cleanup'); echo '<p class="sublabel">' . spa_text('This will clean up expired WP Transients from the WP options table and any expired SP user notices.') . '</p>'; ?> <form action="<?php echo $ahahURL; ?> " method="post" id="sftransientcleanup" name="sftransientcleanup"> <?php echo sp_create_nonce('forum-adminform_housekeeping'); ?> <br /> <input type="submit" class="button-primary" id="saveit4" name="transient-cleanup" value="<?php spa_etext('Clean Up Transients'); ?> " onclick="jQuery('#tcimg').show();"/> <img class="sfhidden" id="tcimg" src="<?php echo SFCOMMONIMAGES . 'working.gif'; ?> " alt=""/> </form> <?php spa_paint_close_fieldset(); spa_paint_close_panel(); spa_paint_open_panel(); spa_paint_open_fieldset(spa_text('Rebuild Default Profile Tabs'), true, 'reset-tabs'); echo '<p class="sublabel">' . spa_text('This will remove all Profile Tabs and restore to default state.') . '</p>'; ?> <form action="<?php echo $ahahURL; ?> " method="post" id="sfresetprofiletabs" name="sfresetprofiletabs"> <?php echo sp_create_nonce('forum-adminform_housekeeping'); ?> <input type="submit" class="button-primary" id="saveit5" name="reset-tabs" value="<?php spa_etext('Reset Profile Tabs'); ?> " onclick="jQuery('#rdptimg').show();"/> <img class="sfhidden" id="rdptimg" src="<?php echo SFCOMMONIMAGES . 'working.gif'; ?> " alt=""/> </form> <?php spa_paint_close_fieldset(); spa_paint_close_panel(); spa_paint_open_panel(); spa_paint_open_fieldset(spa_text('Reset the Auths Cache'), true, 'reset-auths'); echo '<p class="sublabel">' . spa_text("This will force a rebuild of each user's auth cache. It does not change any permissions.") . '</p>'; ?> <form action="<?php echo $ahahURL; ?> " method="post" id="sfresetauths" name="sfresetauths"> <?php echo sp_create_nonce('forum-adminform_housekeeping'); ?> <input type="submit" class="button-primary" id="saveit6" name="reset-auths" value="<?php spa_etext('Reset Auths Cache'); ?> " onclick="jQuery('#rtacimg').show();"/> <img class="sfhidden" id="rtacimg" src="<?php echo SFCOMMONIMAGES . 'working.gif'; ?> " alt=""/> </form> <?php spa_paint_close_fieldset(); spa_paint_close_panel(); spa_paint_open_panel(); spa_paint_open_fieldset(spa_text('Reset Users Plugin Data Cache'), true, 'reset-plugin-data'); echo '<p class="sublabel">' . spa_text("This will force each user's plugin data cache to be cleared.") . '</p>'; ?> <form action="<?php echo $ahahURL; ?> " method="post" id="sfresetplugdata" name="sfresetplugdata"> <?php echo sp_create_nonce('forum-adminform_housekeeping'); ?> <input type="submit" class="button-primary" id="saveit10" name="reset-plugin-data" value="<?php spa_etext('Reset Users Plugin Data'); ?> " onclick="jQuery('#rrpdimg').show();"/> <img class="sfhidden" id="rrpdimg" src="<?php echo SFCOMMONIMAGES . 'working.gif'; ?> " alt=""/> </form> <?php spa_paint_close_fieldset(); spa_paint_close_panel(); spa_paint_open_panel(); spa_paint_open_fieldset(spa_text('Reset combined CSS/JS'), true, 'reset-combined'); echo '<p class="sublabel">' . spa_text('This will force a rebuild of the combined CSS and JS cache files.') . '</p>'; ?> <form action="<?php echo $ahahURL; ?> " method="post" id="sfresetcombined" name="sfresetcombined"> <?php echo sp_create_nonce('forum-adminform_housekeeping'); ?> <input type="submit" class="button-primary" id="saveit7" name="reset-combinedcss" value="<?php spa_etext('Reset Combined CSS Cache'); ?> " onclick="jQuery('#rtccimg').show();"/> <input type="submit" class="button-primary" id="saveit8" name="reset-combinedjs" value="<?php spa_etext('Reset Combined Script Cache'); ?> " onclick="jQuery('#rtccimg').show();"/> <img class="sfhidden" id="rtccimg" src="<?php echo SFCOMMONIMAGES . 'working.gif'; ?> " alt=""/> </form> <?php spa_paint_close_fieldset(); spa_paint_close_panel(); spa_paint_open_panel(); spa_paint_open_fieldset(spa_text('Flush general cache'), true, 'flush-cache'); echo '<p class="sublabel">' . spa_text("This will force a flushing of the general cache.") . '</p>'; ?> <form action="<?php echo $ahahURL; ?> " method="post" id="sfflushcache" name="sfflushcache"> <?php echo sp_create_nonce('forum-adminform_housekeeping'); ?> <input type="submit" class="button-primary" id="saveit9" name="flushcache" value="<?php spa_etext('Flush General Cache'); ?> " onclick="jQuery('#fcacheimg').show();"/> <img class="sfhidden" id="fcacheimg" src="<?php echo SFCOMMONIMAGES . 'working.gif'; ?> " alt=""/> </form> <?php spa_paint_close_fieldset(); spa_paint_close_panel(); do_action('sph_toolbox_housekeeping_right_panel'); spa_paint_close_container(); echo '<div class="sfform-panel-spacer"></div>'; spa_paint_close_tab(); }
function spa_forums_create_forum_form() { ?> <script type="text/javascript"> jQuery(document).ready(function() { spjAjaxForm('sfforumnew', 'sfreloadfb'); }); </script> <?php global $spPaths, $tab; spa_paint_options_init(); $ahahURL = SFHOMEURL . 'index.php?sp_ahah=forums-loader&sfnonce=' . wp_create_nonce('forum-ahah') . '&saveform=createforum'; ?> <form action="<?php echo $ahahURL; ?> " method="post" id="sfforumnew" name="sfforumnew"> <?php echo sp_create_nonce('forum-adminform_forumnew'); spa_paint_open_tab(spa_text('Forums') . ' - ' . spa_text('Create New Forum'), true); spa_paint_open_panel(); spa_paint_open_fieldset(spa_text('Create New Forum'), 'true', 'create-new-forum'); # check there are groups before proceeding if (spdb_count(SFGROUPS) == 0) { echo '<br /><div class="sfoptionerror">'; spa_etext('There are no groups defined'); echo '<br />' . spa_text('Create new group'); echo '</div><br />'; spa_paint_close_fieldset(); spa_paint_close_panel(); spa_paint_close_container(); spa_paint_close_tab(); echo '</form>'; return; } # Select the forum type first echo "<div class='sp-form-row'>\n"; echo "<div class='wp-core-ui sflabel sp-label-40'>" . spa_text('What type of forum are you creating') . ":</div>\n"; echo "<div class='wp-core-ui sp-radio'>"; echo '<input type="radio" name="forumtype" id="sfradio1" tabindex="' . $tab . '" value="1" checked="checked" onchange="spjSetForumOptions(\'forum\');" />' . "\n"; echo '<label for="sfradio1" class="wp-core-ui">' . spa_text('Standard Forum') . '</label><br>' . "\n"; $tab++; # check there are forums before offering subforum creation! if (spdb_count(SFFORUMS) != 0) { echo '<input type="radio" name="forumtype" id="sfradio2" tabindex="' . $tab . '" value="2" onchange="spjSetForumOptions(\'subforum\');" />' . "\n"; echo '<label for="sfradio2" class="wp-core-ui">' . spa_text('Sub or child forum') . '</label>' . "\n"; $tab++; } echo '</div><div class="clearboth"></div></div>'; # Now display the two select box options $ahahURL = SFHOMEURL . 'index.php?sp_ahah=forums&sfnonce=' . wp_create_nonce('forum-ahah'); $target = 'fseq'; echo '<div id="groupselect" style="display:block;">'; echo "<div class='sp-form-row'>\n"; echo "<div class='wp-core-ui sflabel sp-label-40'>" . spa_text('Select group new forum will belong to') . ":</div>\n"; echo '<select class="wp-core-ui sp-input-60" tabindex="' . $tab . '" name="group_id" onchange="spjSetForumSequence();">'; echo spa_create_group_select(0, 1); echo "</select>\n"; echo '<div class="clearboth"></div>'; echo '</div>'; $tab++; echo '</div>'; echo '<div id="forumselect" style="display:none;">'; echo "<div class='sp-form-row'>\n"; echo "<div class='wp-core-ui sflabel sp-label-40'>" . spa_text('Select forum new subforum will belong to') . ":</div>\n"; echo '<select class="wp-core-ui sp-input-60" tabindex="' . $tab . '" name="forum_id" onchange="spjSetForumSequence();">'; echo sp_render_group_forum_select(false, false, false, true); echo "</select>\n"; echo '<div class="clearboth"></div>'; echo '</div>'; $tab++; echo '</div>'; spa_paint_close_fieldset(); spa_paint_close_panel(); spa_paint_close_container(); echo '<div class="sfform-panel-spacer"></div>'; spa_paint_close_tab(); echo '<div class="sfform-panel-spacer"></div>'; echo '<div class="sfhidden" id="block1">'; spa_paint_open_nohead_tab(false); spa_paint_open_panel(); spa_paint_open_fieldset(spa_text('Forum Details'), false); $target = 'thisforumslug'; $ahahURL = SFHOMEURL . 'index.php?sp_ahah=forums&sfnonce=' . wp_create_nonce('forum-ahah'); # forum name and slug echo "<div class='sp-form-row'>"; echo "<div class='wp-core-ui sflabel sp-label-40'>" . spa_text('Forum Name') . ':</div>'; echo '<input type="text" class="wp-core-ui sp-input-60" tabindex="' . $tab . '" name="forum_name" value="" onchange="spjSetForumSlug(this, \'' . $ahahURL . '\', \'' . $target . '\', \'new\');" />'; echo '<div class="clearboth"></div>'; echo '</div>'; $tab++; echo "<div class='sp-form-row'>\n"; echo "<div class='wp-core-ui sflabel sp-label-40'>" . spa_text('Forum slug') . ":</div>"; echo '<input type="text" class="wp-core-ui sp-input-60" tabindex="' . $tab . '" name="thisforumslug" id="thisforumslug" value="" disabled="disabled" onchange="spjSetForumSlug(this, \'' . $ahahURL . '\', \'' . $target . '\', \'new\');" />'; echo '<div class="clearboth"></div>'; echo '</div>'; $tab++; spa_paint_input(spa_text('Description'), 'forum_desc', '', false, true); spa_paint_checkbox(spa_text('Locked'), 'forum_status', 0); spa_paint_checkbox(spa_text('Disable forum RSS feed so feed will not be generated'), 'forum_private', 0); echo '<div class="sfoptionerror spaceabove">'; echo '<p><b>' . sp_text('Custom Icon Ordering') . '</b></br>'; echo sp_text('When using custom forum or topic icons and multiple conditions exist, the following precedence is used:') . '</p>'; echo sp_text('Locked') . '<br />'; echo sp_text('Pinned') . '<br />'; echo sp_text('Unread') . '<br />'; echo sp_text('Custom') . '<br />'; echo sp_text('Theme Default') . '<br />'; echo '</div>'; spa_paint_select_start(spa_text('Custom forum icon'), 'forum_icon', ''); spa_select_icon_dropdown('forum_icon', spa_text('Select Custom Icon'), SF_STORE_DIR . '/' . $spPaths['custom-icons'] . '/', '', false); spa_paint_select_end(); spa_paint_select_start(spa_text('Custom forum icon when new posts'), 'forum_icon_new', ''); spa_select_icon_dropdown('forum_icon_new', spa_text('Select Custom Icon'), SF_STORE_DIR . '/' . $spPaths['custom-icons'] . '/', '', false); spa_paint_select_end(); spa_paint_select_start(spa_text('Custom forum icon when locked'), 'forum_icon_locked', ''); spa_select_icon_dropdown('forum_icon_locked', spa_text('Select Custom Icon'), SF_STORE_DIR . '/' . $spPaths['custom-icons'] . '/', '', false); spa_paint_select_end(); spa_paint_select_start(spa_text('Custom topic icon'), 'topic_icon', ''); spa_select_icon_dropdown('topic_icon', spa_text('Select Custom Icon'), SF_STORE_DIR . '/' . $spPaths['custom-icons'] . '/', '', false); spa_paint_select_end(); spa_paint_select_start(spa_text('Custom topic icon when new posts'), 'topic_icon_new', ''); spa_select_icon_dropdown('topic_icon_new', spa_text('Select Custom Icon'), SF_STORE_DIR . '/' . $spPaths['custom-icons'] . '/', '', false); spa_paint_select_end(); spa_paint_select_start(spa_text('Custom topic icon when locked'), 'topic_icon_locked', ''); spa_select_icon_dropdown('topic_icon_locked', spa_text('Select Custom Icon'), SF_STORE_DIR . '/' . $spPaths['custom-icons'] . '/', '', false); spa_paint_select_end(); spa_paint_select_start(spa_text('Custom topic icon when pinned'), 'topic_icon_pinned', ''); spa_select_icon_dropdown('topic_icon_pinned', spa_text('Select Custom Icon'), SF_STORE_DIR . '/' . $spPaths['custom-icons'] . '/', '', false); spa_paint_select_end(); spa_paint_input(spa_text('Custom meta keywords (SEO option must be enabled)'), 'forum_keywords', '', false, true); spa_paint_wide_textarea('Special forum message to be displayed above forums', 'forum_message', ''); spa_paint_close_fieldset(); echo '<div class="sfoptionerror spaceabove">'; echo sprintf(sp_text('To re-order your Groups, Forums and SubForums use the %s Order Groups and Forums %s option from the Forums Menu'), '<b>', '</b>'); echo '</div>'; spa_paint_close_panel(); spa_paint_tab_right_cell(); spa_paint_open_panel(); spa_paint_open_fieldset(spa_text('Extended Forum Options'), false); # As added by plugins do_action('sph_forum_create_forum_options'); spa_paint_close_fieldset(); spa_paint_close_panel(); spa_paint_open_panel(); spa_paint_open_fieldset(spa_text('Add User Group Permissions'), false); echo '<div id="block2" class="sfhidden">'; echo '<strong>' . spa_text('You can selectively set the permission sets for the forum below. If you want to use the default permissions for the selected group, then do not select anything') . '</strong>'; # Permissions $usergroups = spa_get_usergroups_all(); $roles = sp_get_all_roles(); foreach ($usergroups as $usergroup) { echo '<input type="hidden" name="usergroup_id[]" value="' . $usergroup->usergroup_id . '" />'; spa_paint_select_start(sp_filter_title_display($usergroup->usergroup_name), 'role[]', ''); echo '<option value="-1">' . spa_text('Select permission set') . '</option>'; foreach ($roles as $role) { echo '<option value="' . $role->role_id . '">' . sp_filter_title_display($role->role_name) . '</option>' . "\n"; } spa_paint_select_end(); } echo '</div>'; spa_paint_close_fieldset(); spa_paint_close_panel(); spa_paint_close_container(); ?> <div class="sfform-submit-bar"> <input type="submit" class="button-primary" id="saveit" name="saveit" value="<?php spa_etext('Create New Forum'); ?> " /> </div> <?php spa_paint_close_tab(); ?> </div> </form> <div class="sfform-panel-spacer"></div> <?php }
function sp_move_post_popup() { $thispost = sp_esc_int($_GET['pid']); $topicid = sp_esc_int($_GET['id']); $thispostindex = sp_esc_int($_GET['pix']); $thistopic = spdb_table(SFTOPICS, "topic_id={$topicid}", 'row'); if (empty($thispost) || empty($thistopic)) { die; } $thisforum = spdb_table(SFFORUMS, "forum_id={$thistopic->forum_id}", 'row'); if (!sp_get_auth('move_posts', $thistopic->forum_id)) { if (!is_user_logged_in()) { sp_etext('Access denied - are you logged in?'); } else { sp_etext('Access denied - you do not have permission'); } die; } ?> <div id="spMainContainer" class="spForumToolsPopup"> <div class="spForumToolsHeader"> <div class="spForumToolsHeaderTitle"><?php echo sp_text('Move post'); ?> </div> </div> <form action="<?php echo sp_build_url($thisforum->forum_slug, $thistopic->topic_slug, 1, 0); ?> " method="post" name="movepostform"> <input type="hidden" name="postid" value="<?php echo $thispost; ?> " /> <input type="hidden" name="oldtopicid" value="<?php echo $topicid; ?> " /> <input type="hidden" name="oldforumid" value="<?php echo $thisforum->forum_id; ?> " /> <input type="hidden" name="oldpostindex" value="<?php echo $thispostindex; ?> " /> <fieldset><legend><?php sp_etext('Select Operation'); ?> </legend> <input type="radio" name="moveop" id="single" value="single" checked="checked" /> <label for="single"> <?php sp_etext('Move this post only'); ?> </label><br /> <input type="radio" name="moveop" id="tostart" value="tostart" /> <label for="tostart"> <?php sp_etext('Move this post and ALL preceding posts'); ?> </label><br /> <input type="radio" name="moveop" id="toend" value="toend" /> <label for="toend"> <?php sp_etext('Move this post and ALL succeeding posts'); ?> </label><br /> <input type="radio" name="moveop" id="select" value="select" /> <label for="select"> <?php sp_etext('Move the posts listed below'); ?> :</label><br /> <label for="idList"><?php sp_etext('Post Numbers to move - separated by commas'); ?> </label><br /> <input type="text" class="spControl" name="idlist" value="<?php echo $thispostindex; ?> ," /><br /><br /> <span> <input type="button" class="spSubmit" name="movetonew" value="<?php echo sp_splice(sp_text('Move to a NEW topic'), 2); ?> " onclick="jQuery('#oldtopic').hide(); jQuery('#newtopic').show();" /> <input type="button" class="spSubmit" name="movetoold" value="<?php echo sp_splice(sp_text('Move to an EXISTING topic'), 2); ?> " onclick="jQuery('#newtopic').hide(); jQuery('#oldtopic').show();" /> <input type="button" class="spSubmit" name="cancel" value="<?php echo sp_splice(sp_text('Cancel Move'), 0); ?> " onclick="jQuery('#dialog').dialog('close');" /> </span> </fieldset> <div id="newtopic" class="spCenter" style="display:none;"> <p class="spCenter" ><b><?php sp_etext('Move to a NEW topic'); ?> </b></p> <?php echo sp_render_group_forum_select(false, false, true, true, sp_text('Select forum'), 'forumid', 'spSelect'); ?> <br /><br /> <p class="spCenter"><?php sp_etext('New topic name'); ?> </p> <input type="text" class="spControl" size="80" name="newtopicname" value="" /><br /><br /> <?php do_action('sph_move_post_form', $thispost, $topicid); ?> <input type="submit" class="spSubmit" name="makepostmove1" value="<?php sp_etext('Move'); ?> " /> </div> <div id="oldtopic" class="spCenter" style="display:none;"> <p class="spCenter" ><b><?php sp_etext('Move to a EXISTING topic'); ?> </b></p> <p class="spCenter" ><?php sp_etext('Click on the Move button below and when the page refreshes navigate to the target topic to complete the move'); ?> </p> <?php do_action('sph_move_post_form', $thispost, $topicid); ?> <input type="submit" class="spSubmit" name="makepostmove2" value="<?php sp_etext('Move'); ?> " /> </div> </form> </div> <?php }
function spa_forums_merge_form() { ?> <script type="text/javascript"> jQuery(document).ready(function() { spjAjaxForm('sfmergeforums', 'sfreloadmf'); }); </script> <?php spa_paint_options_init(); $ahahURL = SFHOMEURL . 'index.php?sp_ahah=forums-loader&sfnonce=' . wp_create_nonce('forum-ahah') . '&saveform=mergeforums'; ?> <form action="<?php echo $ahahURL; ?> " method="post" id="sfmergeforums" name="sfmergeforums"> <?php echo sp_create_nonce('forum-adminform_mergeforums'); spa_paint_open_tab(spa_text('Forums') . ' - ' . spa_text('Merge Forums')); spa_paint_open_panel(); spa_paint_open_fieldset(spa_text('Select Source Forum to Merge From'), false); ?> <div id="forumselect1"> <?php spa_etext('The source forum selected here will have all sub-forums, topics, posts and references transferred to the forum selected as the target for the merge. It will then be deleted.'); ?> <br /><br /> <select class="sfacontrol" name="source"> <?php echo sp_render_group_forum_select(false, false, false, true, spa_text('Select Source Forum to Merge From')); ?> </select> </div> <?php spa_paint_close_fieldset(); spa_paint_close_panel(); spa_paint_tab_right_cell(); spa_paint_open_panel(); spa_paint_open_fieldset(spa_text('Select Target Forum to Merge To'), true, 'merge-forums'); ?> <div id="forumselect2"> <?php spa_etext('The target forum selected here will inherit all sub-forums, topics, posts and references from the source forum. Current permissions for this forum will be retained.'); ?> <br /><br /> <select class="sfacontrol" name="target"> <?php echo sp_render_group_forum_select(false, false, false, true, spa_text('Select Target Forum to Merge To')); ?> </select> </div> <?php spa_paint_close_fieldset(); spa_paint_close_panel(); do_action('sph_forums_merge_forums_panel'); spa_paint_close_container(); ?> <div class="sfform-submit-bar"> <input type="submit" class="button-primary" id="saveit" name="saveit" value="<?php spa_etext('Perform Forum Merge'); ?> " /> </div> <?php spa_paint_close_tab(); ?> </form> <div class="sfform-panel-spacer"></div> <?php }