CM Download (CMDM) - Extras - Import/Export (CSV Files, Server System)
Navigate to Admin Dashboard → CM Downloads → Import/Export.
You can export or import downloads as a CSV file, which can be edited as a spreadsheet.
Note that the CSV file doesn't contain files - instead, it lists information on every file, including their address.
TIP: Create a Template
Before starting, export a CSV file to generate a template that will be easy to edit.
CSV File Format
Prepare the CSV files only using a dedicated CSV editor or a spreadsheet editor as MS Excel or OpenOffice Calc in order to make sure you won't make any mistakes with the CSV format (especially when using HTML). Also use the UTF-8 encoding for the CSV files.
Following columns in a such order will be imported from your CSV file:
- Id - Post ID - not included on import.
- Title - Download title.
- Type - Package type, one of following: file, url, shortcode.
- Source - Source file URL or local absolute path to the file. Single value or JSON-encoded array with multiple values. On import these files will be downloaded to the cmdm directory.
- Description - Download description. May contains HTML tags.
- Status - Post status, one of following: publish, draft.
- Categories - Categories list separated by commas. May contains categories names, slugs or ids. During the import the missing categories will be created. Optional on import.
- Mime - Download mime type, for example: application/zip. If missing, will be recognized. Optional on import.
- Slug - Download slug. Optional on import.
- Page url - Permalink to the page that download has been previously exported. Optional on import.
- User id - ID of the user on the Wordpress the download has been exported from. Optional on import.
- Author display name - Display name of the user on the Wordpress the download has been exported from. Optional on import.
- Views - Number of views. Optional on import.
- Tags - Tags list separated by commas. May contains tag names, slugs or ids. During the import the missing tags will be created. Optional on import.
- Screenshots - Screenshot URL or JSON-encoded array with multiple URLs. Optional on import.
- Created date - Download created date. Optional on import.
- Modified date - Download modified date. Optional on import.
Notices: Columns from ID to Description are required, but the ID may be empty
Please use the UTF-8 formatting.
Below: example CSV file.
Import from server file system
To import downloads from the server file system, choose the directory and set Status after import (published/draft).
Checking the option Trim out file extension in post title will affect the download names. For example, "File.zip" to "File".
Click Import files to finish. You should see a message "x downloads imported successfully".