Import Articles from CSV/Excel to Page Module

How to import and transfer articles from Excel (XLSX) and CSV spreadsheets to the Page module on Cotonti CMF. Overview and detailed guide for the "pageimportcvsexcel" plugin

Overview and Detailed Guide to the «Import Articles from CSV/Excel to Page Module» Plugin for Cotonti CMF

The pageimportcvsexcel plugin is a professional tool developed specifically for the Cotonti content management system (version 0.9.26 and higher), which allows administrators to quickly and conveniently transfer large volumes of articles from Excel tables (XLSX) and CSV files into the Page module.

Video in Telegram | Video in YouTube

Tested on Cotonti 0.9.26+ with PHP 8.4

The plugin is fully standalone: it does not require Composer installation, uses the built-in latest stable version of the PhpSpreadsheet library, and works on PHP 8.4+. It is ideal for migrating content from other CMS platforms, importing articles from parsers, supplier Excel tables, or internal databases.

Key Features

  • Support for the two most popular formats: XLSX and CSV.
  • Flexible field mapping: the administrator independently matches Excel columns to any fields in the cot_pages table (title, text, desc, keywords, metatitle, alias, category, dates, author, etc.).
  • Automatic date processing (both in Excel format and regular strings).
  • Built-in text cleaning: optionally removes all links, scripts, JavaScript events, data- and javascript-schemes, empty tags — excellent protection against "dirty" content.
  • Limit on the number of imported rows (configurable, default 300).
  • Detailed logging of all stages (optional).
  • Convenient modern Bootstrap 5-based interface with tabular field mapping display.
  • Automatic default value insertion and protection against empty required fields (category and title).
  • If the page_text field remains empty, the plugin automatically fills it with the article title.
  • Complete cleanup of temporary files after import.

Installation and Activation

  1. Copy the pageimportcvsexcel folder to the /plugins/ directory.
  2. In the administration panel, go to Extensions → Plugins and install the plugin.
  3. Activate it and assign rights to the "Administrators" group (RW).

The plugin automatically creates an uploads/ folder inside its directory and uses the session to store the path to the uploaded file.

Plugin Configuration

In the Plugin Configuration section, five key parameters are available:

  • Target table — default is pages (you can specify any other table with a similar structure).
  • Maximum rows — import limit (0 = no limit).
  • Allowed formats — xlsx,csv (can be expanded or restricted).
  • Strip links in text — enable HTML cleaning function.
  • Keep import log — detailed journal in logs/import.log file.

Step-by-Step Usage Guide

Step 1. File Preparation Prepare the table in Excel or Google Sheets. The first row contains column headers (they can be in any language). Recommended columns: Title, Text, Short Description, Category, Alias, Publication Date, Author, Keywords, Meta Title, etc.

Step 2. File Upload Go to Administration → Others → Page Module articles CSV/Excel Import. Select the file and click "Upload File". The plugin checks the format, saves the file to a temporary folder, and automatically reads the column headers.

Step 3. Field Mapping Setup A convenient table appears: on the left — all available Page module fields (with clear labels). On the right — a dropdown list with your file's headers + the "Do Not Import" option.

Select the necessary mappings (most fields can be left on default auto-mapping). Click "Start Import".

Step 4. Import Process The process runs row by row. Upon completion, you will see the exact number of successfully added records. The file is automatically deleted, and the session is cleared.

Useful Tips and Best Practices

  • For very large files (over 1000 rows), set a reasonable row limit and run the import in multiple batches.
  • Enable the link cleaning function when importing content from external sources — this significantly improves security and article quality.
  • Keep the import log enabled during initial runs — it helps quickly identify and fix data issues.
  • If the file contains an alias column, be sure to map it to page_alias — the plugin does not automatically check uniqueness.
  • For dates, it is better to use “DO NOT IMPORT”.

Technical Features and Reliability

The plugin uses a modern approach: reads only data (without styles), processes row by row, protects against SQL injections via Cotonti's standard $db->insert() methods. The PhpSpreadsheet library autoloaders and PSR work without conflicts with other plugins.

All exceptions are caught and logged, and the user receives clear error messages. No "garbage" remains on the server after import.

Who the Plugin Is For

  • Owners of large Cotonti-based sites who need to regularly add hundreds of articles.
  • Developers and freelancers performing content migrations.
  • Online stores and information portals using Excel as their main article database.
  • Anyone tired of manually creating hundreds of pages.

Conclusion

pageimportcvsexcel is a mature, well-thought-out, and secure tool that saves dozens of hours of routine work. It combines maximum mapping flexibility with a user-friendly interface and reliable data processing. Thanks to the absence of external dependencies, the plugin works "out of the box" even on the strictest hosting environments.

If you actively use the Page module in Cotonti — this plugin should be in your arsenal. It is already production-ready and will be useful for both beginners and experienced administrators.

 Permanent link to the current plugin source code on GitHub. 

Official support and discussion page: https://abuyfile.com/ru/forums/cotonti/custom/plugs/topic123

Author: webitproff (February 2026).



Rating based on reviews:
Stars received: 0
Total reviews: 0
Average rating: 0
4 minutes read

Reviews to products

No reviews yet


Add to Cart

A downloadable file is attached to this product.

Page-Module-articles-CSV-Excel-Import_v.2.2.27.zip

Number of downloads 3

 

Category Extentions
Import, export, and data exchange, Utilities and tools
Availability
Free

Featured articles for this product

Open Server 6.5.0 is the first launch. User's Guide.

Open Server 6.5.0 is the first launch. User's Guide.

Step-by-step guide: Installing OSPanel 6.5.0 and running phpMyAdmin on PHP 8.5 Complete working
CMS and CMF: what are they, what is the difference?

CMS and CMF: what are they, what is the difference?

The verview article with simple examples, designed to help people understand the key differences

Content author

webitproff

Offline

webitproff

Last logged: 2026-07-20 14:34

  • Чем могу помочь?

    Оказываю весь спектр услуг по CMF Cotonti. Разработка открытых и закрытых корпоративных интернет порталов, небольших социальных сетей, торговые площадки, маркетплейсы, биржи фриланса, каталоги товаров оптовых поставщиков, интернет-магазин под заказ, чтобы делать совместные покупки и групповые совместные продажи от имени нескольких продавцов.

  • Разработки на GitHub бесплатно
  • Featured Products and Services

    Excel Export Plugin for Cotonti CMF

    Excel Export Plugin for Cotonti CMF

    "Excel Export" allows you to securely export data from any database table to Excel (XLSX). Field
    Market Products Import CSV/Excel - плагин для Cotonti

    Market Products Import CSV/Excel - плагин для Cotonti

    Плагин marketproductsimport - это инструмент массового импорта товаров в интернет-магазин или

    Market PRO Showcase

    CMS, Script and Engine for an online storefront, infoproduct shop and digital goods store. Different prices in different currencies. Online cryptocurrency payments for goods and services.