承接 timnarr/kirby-sanitize-filenames 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

timnarr/kirby-sanitize-filenames

最新稳定版本:0.2.0

Composer 安装命令:

composer require timnarr/kirby-sanitize-filenames

包简介

This plugin provides filename sanitizing by using file hooks.

README 文档

README

Sanitize Filenames for Kirby CMS – This plugin automatically transforms and sanitizes filenames using file hooks. It can converts filenames to snake_case or kebab-case. It also sanitizes filenames by modifying special characters and allows adding a custom prefix for consistent file naming.

Installation

Download

Download and copy this repository to /site/plugins/kirby-sanitize-filenames.

Composer

composer require timnarr/kirby-sanitize-filenames

Usage

The plugin listens for these two Kirby hooks, and when these are triggered, the filename gets manipulated:

  • file.create:after
  • file.replace:after

This plugin does not support the changeName hook because file renaming, which occurs after the create and replace hooks, will trigger the changeName hook too. This could lead to some misbehaviors. However, it is beneficial to be able to change the filename after the initial upload and filename manipulation.

Config

You can choose between snake and kebab style. The prefix will also be transformed to a safe-name and a delimiter gets appended: _ for snake and - for kebab style.

'timnarr.sanitize-filenames' => [
  'caseStyle' => 'snake',
  'prefix' => 'timnarr'
]

License

MIT License Copyright © 2023 Tim Narr

统计信息

  • 总下载量: 6
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 2
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2023-11-15

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固