WP_Import::import_options PHP Method

import_options() public method

Display pre-import options, author importing/mapping and option to fetch attachments
public import_options ( )
        function import_options()
        {
            $j = 0;
            ?>
            <form action="<?php 
            echo admin_url('admin.php?import=wordpress&amp;step=2');
            ?>
" method="post">
				<?php 
            wp_nonce_field('import-wordpress');
            ?>
                <input type="hidden" name="import_id" value="<?php 
            echo $this->id;
            ?>
"/>

				<?php 
            if (!empty($this->authors)) {
                ?>
                    <h3><?php 
                _e('Assign Authors', 'wordpress-importer');
                ?>
</h3>
                    <p><?php 
                _e('To make it easier for you to edit and save the imported content, you may want to reassign the author of the imported item to an existing user of this site. For example, you may want to import all the entries as <code>admin</code>s entries.', 'wordpress-importer');
                ?>
</p>
					<?php 
                if ($this->allow_create_users()) {
                    ?>
                        <p><?php 
                    printf(__('If a new user is created by WordPress, a new password will be randomly generated and the new user&#8217;s role will be set as %s. Manually changing the new user&#8217;s details will be necessary.', 'wordpress-importer'), esc_html(get_option('default_role')));
                    ?>
</p>
					<?php 
                }
                ?>
                    <ol id="authors">
						<?php 
                foreach ($this->authors as $author) {
                    ?>
                            <li><?php 
                    $this->author_select($j++, $author);
                    ?>
</li>
						<?php 
                }
                ?>
                    </ol>
				<?php 
            }
            ?>

				<?php 
            if ($this->allow_fetch_attachments()) {
                ?>
                    <h3><?php 
                _e('Import Attachments', 'wordpress-importer');
                ?>
</h3>
                    <p>
                        <input type="checkbox" value="1" name="fetch_attachments" id="import-attachments"/>
                        <label for="import-attachments"><?php 
                _e('Download and import file attachments', 'wordpress-importer');
                ?>
</label>
                    </p>
				<?php 
            }
            ?>

                <p class="submit"><input type="submit" class="button"
                                         value="<?php 
            esc_attr_e('Submit', 'wordpress-importer');
            ?>
"/></p>
            </form>
			<?php 
        }