Replace slashes with dashes

Please log in or register to do it.

Replace Slashes with Dashes: Convert / and \ to - in text. Options for specific slash types, URL/date preservation, custom replacements, and multi-slash handling. Ideal for path formatting and data cleanup.

Processing Modes:

Convert both / and \ to - everywhere
Replace only / characters
Replace only \ characters
Skip replacement in http/https URLs
Maintain slashes in date formats
Specify replacement character(s):
Convert consecutive slashes to single -

Examples:

Basic Replacement

Before:
2023/12\31/document
After:
2023-12-31-document

URL Preservation

Before:
Visit https://example.com/path
After:
Visit https://example.com/path

Date Preservation

Before:
Date: 2023/12/31 Time: 14\30
After:
Date: 2023/12/31 Time: 14-30

Custom Replacement

Before:
src/components/ui
After:
src_components_ui

Multiple Slash Handling

Before:
server//shared\\folder
After:
server-shared-folder
Replace JavaScript console.log with alert statements
Replace text with its Base64 encoded version