The Tools section provides features that are not absolutely necessary for running your site, but can be used to fix technical issues, insert custom code, and backup and restore your site. The available tools in this section are:
The Backups section is where you can manage backing up and restoring your website to protect from any data loss due to hacking, power loss etc...
Backing Up Your Site
To backup your site, click the Create backup button at the top-right of the section. A pop-up will opening allowing you to enter a name for your backup; clicking OK will create the new backup add it to the list of available backups (you can set where the backups are stored on your computer via the Publii Global Settings, covered in the next section).
Restoring Your Site
To restore your site from a backup, click on the Restore button to the right of the backup you wish to restore; a confirmation message will appear; click OK to run the restore process and roll your site back to the restored version.
To delete a backup, click on the checkbox to the left of the backup you wish to delete; doing so will cause a red Delete button to appear at the top of the list of backups. Once you've selected all the backups you want to delete, click the Delete button to remove. A confirmation will be displayed; click OK to proceed with the deletion. Remember that once a backup is deleted its gone forever, so only do this if you're sure you won't need the backup in the future.
Sometimes, after making a large change to a site such as changing the active theme, you might find that there are some issues with the responsive images as the new theme has different thumbnail requirements. In this case you will need to regenerate the thumbnails. This is an automated process accessible by clicking on the Settings option in the left-sidebar and scrolling down the settings page; the Regenerate thumbnails option is found in the Website Maintenance section. Note that this process may take some time if you have a large number of images on your site, so please be patient. It is recommended that this option is utilized every time a new theme is activated.
Note that this process may take some time if you have a large number of images on your site, so please be patient. It is recommended that this option is utilized every time a new theme is activated.
The File Manager tool allows for advanced users to inspect all the files generated for their website, including text files such as .htaccess, or media files that are used in the site posts. Opening the tool will display a list of files generated and uploaded to your site (you must have uploaded the site files at least once for them to appear in the list). From here, you can click on any of the files and it will be opened using your system's default editor e.g. if you use Sublime Text to edit your .html files, clicking on an .html file in the File Manager will automatically open it in Sublime Text for editing. This way, you can easily modify your site's .htaccess or robots.txt as you see fit.
You may also delete existing files by clicking on the checkbox next to the file you want to delete, then clicking the red Delete button that appears at the top of the list of files. For advanced users, you may also manually add a new file by clicking the Add new file button at the top-right of the screen; you will be prompted to name the file (don't forget to include the extension!), and you can then open it for editing by clicking on it. Alternatively, you may also manually add existing files to your site directory by clicking the Upload files button; this will open an explorer window where you can search for and select the file that you want to add to the site directory.
This section allows you to insert custom CSS code that can be used to modify or override the existing CSS rules included in the your chosen theme. Selecting this tool will open the CSS editor, where you can enter your custom rules. Once you have made your changes, you can either click the Save & Preview button to see how your changes will look on the live site before syncing, or click the Save settings button to confirm changes only with no preview.
Like the CSS tool, this tool allows you to insert custom HTML into your Publii website. As with the custom CSS editor, after opening the tool you will see a text editor where you can enter your custom code. However, there are also tab buttons to the left of the editor; Head, Body, and Footer. Clicking each of these allows you to insert your HTML code into a specific area of the page, depending on your requirements. Once your changes have been made, you have the option of clicking on the Save & Preview option to save changes and see how they will look on the live site after sync, or just clicking the Save settings button to save changes without a preview.
The Log Viewer tool stores information about your website syncs, which can be useful when troubleshooting connection or sync issues. The logs will include any sync errors, a connection log for FTP-type protocols, and a list of changed files that were deleted or replaced during the sync. Each sync operation generates a new log file automatically. When opening the Log Viewer tool you will have the option to Select file to load; selecting one of the generated log files will open the content into the content area underneath the drop-down box for easy viewing.
WP Importer (experimental)
The WP Importer tool provides a simple way to transfer your article and category content from your WordPress website to Publii. Currently, this tool is still in development and is thus considered experimental; we recommend that this import should only be used when building a brand new site based on Publii, rather than to overwrite your existing WP site with a Publii installation until the tool has its full features set and has been tested accordingly. A full step-by-step guide to importing WordPress content may be found in the Using the WordPress Importer section of this guide, available via the sidebar. The following options are available in this tool:
The following options are available in this tool:
- Select WXR File - This option defines which WordPress backup file to use.
The next set of options are only available once a WXR file has been chosen:
- Import selected types of posts - Here you can select which type of content will be imported; enable all that apply. Publii can import posts, pages and custom post types from WordPress. Each type will be imported as an individual post in the Publii interface.
- Used Taxonomy for Posts - Defines how posts imported from WordPress will be assigned tags; select whether to associate posts with their WordPress tags, or their WordPress categories (only tags OR categories may be imported, not both).
- Post Authors - Defines which author imported WordPress posts should be assigned to in Publii; can be set to the main Publii author, or author names can be imported also, and their posts assigned to them.
- Content formatting - When this option is enabled HTML paragraph and line break tags will be added automatically to the imported content if they are missing; useful if your WordPress content was formatted using plugins or shortcodes that are not available in Publii.