

        <div class="meta-box-sortabless">
   
            <form method="post" action="<?php echo $_SERVER["REQUEST_URI"]; ?>">

            <div class="postbox">
                <h3 class="hndle">Search friendly URLs:</h3>
                <div class="inside">
                    <fieldset class="options">
 
                    <table class="form-table" border="0">
                    <tbody>
                    <?php if ( get_option('permalink_structure') == '' ):?>
                    <tr valign="top" >
                        <th colspan="2">Before enabling Search friendly URLs, switch on non-default <a href="<?php echo get_bloginfo('url');?>/wp-admin/options-permalink.php">Permalink structure</a> 
                        </th>
                    </tr>
                    <?php else:?>
                    <tr valign="top" >
                        <th ><label for="seo_url_all">Enable friendly URLs:</label></th>
                        <td>
                        <input type="checkbox" id="seo_url_all" name="seo_url_all" value="true"
                        <?php if ($this->view->devOptions['seo_url_all'] == "true")
                        { _e('checked="checked"', "SphinxSearch"); }?>/>
                        </td>
                    </tr>
                    <?php endif; ?>
                    </tbody>
                    </table>
                    </fieldset>
                </div>
            </div>

            <div class="postbox">
                <h3 class="hndle">Select what to include in the search:</h3>
                <div class="inside">
                    <fieldset class="options">

                    <table class="form-table" border="0">
                    <tbody>
                    
                    <?php foreach (array('search_comments' => 'Comment', 'search_posts' => 'Post', 'search_pages' => 'Page', 'search_tags' => 'Tag')
                            as $option => $title
                        ) { ?>
                    <tr valign="top" >
                        <th ><label for="<?php echo $option ?>"><?php echo $title ?> content</label></th>
                        <td>
                            <input type="checkbox" id="<?php echo $option ?>" name="<?php echo $option ?>" value="true"
                                <?php if ($this->view->devOptions[$option] == "true") {_e('checked="checked"', "SphinxSearch"); }?>/>
                        </td>
                    </tr>
                    <?php } ?>
                    </tbody>
                    </table>
                    </fieldset>
                </div>
            </div>

           <div class="postbox">
                <h3 class="hndle">Keyword highlighting settings</h3>
                <div class="inside">
                    <fieldset class="options">
                    <table class="form-table">
                    <tbody>
                    <tr valign="top" >
                        <th scope="row">Before keyword in text</th>
                        <td ><input type="text" id="excerpt_before_match" name="excerpt_before_match"
                            value="<?php echo stripslashes(htmlspecialchars($this->view->devOptions['excerpt_before_match']));?>" /></td>
                    </tr>
                    <tr valign="top" >
                        <th scope="row">After keyword in text</th>
                        <td ><input type="text" id="excerpt_after_match" name="excerpt_after_match"
                        value="<?php echo stripslashes(htmlspecialchars($this->view->devOptions['excerpt_after_match']));?>" /> </td>
                    </tr>
                    <tr valign="top" >
                        <th scope="row">Before keyword in title</th>
                        <td ><input type="text" id="excerpt_before_match_title" name="excerpt_before_match_title"
                        value="<?php echo stripslashes(htmlspecialchars($this->view->devOptions['excerpt_before_match_title']));?>" /></td>
                    </tr>
                    <tr valign="top" >
                        <th scope="row">After keyword in title</th>
                        <td ><input type="text" id="excerpt_after_match_title" name="excerpt_after_match_title"
                            value="<?php echo stripslashes(htmlspecialchars($this->view->devOptions['excerpt_after_match_title']));?>" /></td>
                    </tr>
                    </tbody>
                    </table>
                </div>
                </div>

           <div class="postbox">
                <h3 class="hndle">Snippet settings</h3>
                <div class="inside">
                    <fieldset class="options">
                    <table class="form-table">
                    <tbody>
                    <tr valign="top" >
                        <th scope="row">Snippet separator</th>
                        <td ><input type="text" id="excerpt_chunk_separator" name="excerpt_chunk_separator"
                            value="<?php echo stripslashes(htmlspecialchars($this->view->devOptions['excerpt_chunk_separator']));?>" /></td>
                    </tr>
                    <tr valign="top" >
                        <th scope="row">Snippet max length</th>
                        <td ><input type="text" id="excerpt_limit" name="excerpt_limit" size="4"
                            value="<?php echo $this->view->devOptions['excerpt_limit'];?>" /></td>
                    </tr>
                    <tr valign="top" >
                        <th scope="row">Maximum number of words around keyword</th>
                        <td ><input type="text" id="excerpt_around" name="excerpt_around" size="4"
                            value="<?php echo $this->view->devOptions['excerpt_around'];?>" /> </td>
                    </tr>

                    </tbody>
                    </table>
                </div>
                </div>

           <div class="postbox">
                <h3 class="hndle">Search results settings</h3>
                <div class="inside">
                    <fieldset class="options">
                    <table class="form-table">
                    <tbody>
                    <tr valign="top" >
                        <th scope="row">Maximum number of search results (up to 100 000)</th>
                        <td ><input type="text" id="sphinx_max_matches" name="sphinx_max_matches"
                            value="<?php echo stripslashes(htmlspecialchars($this->view->devOptions['sphinx_max_matches']));?>" /></td>
                    </tr>
                    <tr valign="top" >
                        <th scope="row">Prefix before Comment title</th>
                        <td ><input type="text" id="before_comment" name="before_comment"
                            value="<?php echo stripslashes(htmlspecialchars($this->view->devOptions['before_comment']));?>" /></td>
                    </tr>
                    <tr valign="top" >
                        <th scope="row">Prefix before Page title</th>
                        <td ><input type="text" id="before_page" name="before_page"
                            value="<?php echo stripslashes(htmlspecialchars($this->view->devOptions['before_page']));?>" /> </td>
                    </tr>
                    <tr valign="top" >
                        <th scope="row">Prefix before Post title</th>
                        <td ><input type="text" id="before_post" name="before_post"
                            value="<?php echo stripslashes(htmlspecialchars($this->view->devOptions['before_post']));?>" /></td>
                    </tr>
                    <tr valign="top" >
                        <th scope="row">Phrase filter (list of phrases to exclude from posts content)</th>
                        <td><textarea id="strip_tags" name="strip_tags" rows="10"
                                      cols="25"><?php echo $this->view->devOptions['strip_tags'];?></textarea></td>
                    </tr>
                    </tbody>
                    </table>
                    </fieldset>
                    <p class="submit">
                        <input type="submit" name="update_SphinxSearchSettings" class="button-primary"
                            value="<?php _e('Save Settings', 'SphinxSearch') ?>" />
                    </p>
                </div>
           </div>
            </form>

        </div>
    </div>
</div>