diff --git a/README.md b/README.md index 9a9f0d5..823d523 100644 --- a/README.md +++ b/README.md @@ -12,12 +12,12 @@ PHP Curl Class makes it easy to send HTTP requests and integrate with web APIs. --- -- [โš™๏ธ Installation](#-installation) +- [โš™๏ธ Installation](#%EF%B8%8F-installation) - [๐Ÿ“‹ Requirements](#-requirements) - [๐Ÿš€ Quick Start and Examples](#-quick-start-and-examples) - [๐Ÿ“– Available Methods](#-available-methods) - [๐Ÿ”’ Security](#-security) -- [๐Ÿ› ๏ธ Troubleshooting](#-troubleshooting) +- [๐Ÿ› ๏ธ Troubleshooting](#%EF%B8%8F-troubleshooting) - [๐Ÿงช Testing](#-testing) - [๐Ÿค Contributing](#-contributing) diff --git a/scripts/update_readme_methods.sh b/scripts/update_readme_methods.sh index ff9fa24..5c85745 100755 --- a/scripts/update_readme_methods.sh +++ b/scripts/update_readme_methods.sh @@ -51,7 +51,19 @@ script=$(cat <<'EOF' preg_match_all('/^### (.*)/m', $data, $matches); $toc = []; foreach ($matches['1'] as $match) { - $slug = strtolower(preg_replace('/[^A-Za-z-]/', '', str_replace(' ', '-', $match))); + $slug = urlencode( + strtolower( + str_replace( + ' ', + '-', + preg_replace( + '/[^A-Za-z\x{FE0F} ]/u', + '', + $match, + ), + ) + ) + ); $href = '#' . $slug; $toc[] = '- [' . $match . '](' . $href . ')'; }