Support » Plugin: Better Find and Replace » Regex to change URL to lowercase

  • Resolved gunterkrebs

    (@gunterkrebs)


    I try to replace all URLs by lower-case-versions

    The search string is: (href="https://mydomain.com/[^"]*")
    which works fine

    The replace string is \L\1
    which does not work. In the output the \L operator is just a \L string, but does not lowercase the \1 output.

    • This topic was modified 3 months, 2 weeks ago by gunterkrebs.
    • This topic was modified 3 months, 2 weeks ago by gunterkrebs.
    • This topic was modified 3 months, 2 weeks ago by gunterkrebs.
Viewing 1 replies (of 1 total)
  • Plugin Support jenneycs

    (@jenneycs)

    Hi @gunterkrebs,
    Thank you for reaching out to us. Unfortunately, you can’t make lowercase of your URL with this pattern. Especially you need a custom regex and PHP default upper case function inside of your Regex callback function.

    In our plugin, you can simply search your ‘UPPERCASE’ and replace with you ‘lowercase’ by selecting the ‘plain text’ option. Hopefully that will work for you. Make sure you have checked the dry-run option before going to final action.

    Thank you

Viewing 1 replies (of 1 total)
  • You must be logged in to reply to this topic.