请问一下htaccess正则匹配的问题
请问一下, 类似如下的地址
http://localhost/info.html\"
打算过滤掉多输入的\"
RewriteRule ^info.html(.*)$ member_info.php
RewriteRule ^info.html\\\"$ member_info.php
都匹配失败了, 请问一下, 有其他的匹配方法么?
回复讨论(解决方案)
又不影响使用,何必让 Apache 那么辛苦?
再说,重写不会改变地址栏的显示,跳转才会
http://bbs.csdn.net/topics/390859703
http://bbs.csdn.net/topics/390859703/
这个/放在上面也没啥,效果是同样的。
又不影响使用,何必让 Apache 那么辛苦?
再说,重写不会改变地址栏的显示,跳转才会
http://bbs.csdn.net/topics/390859703/“ 改成http://bbs.csdn.net/topics/390859703
前者是显示失败404
我想转成后者才是正常的。
http://bbs.csdn.net/topics/390859703
http://bbs.csdn.net/topics/390859703/
这个/放在上面也没啥,效果是同样的。
还有一个引号的。
http://bbs.csdn.net/topics/390859703/“ 改成http://bbs.csdn.net/topics/390859703
前者是显示失败404
我想转成后者才是正常的。
如果加了,遇到真正文件?就出?了。
如果加了,遇到真正文件?就出?了。
目前没有真正文件夹。 始终匹配不到。
http://bbs.csdn.net/topics/390859703
http://bbs.csdn.net/topics/390859703/
这个/放在上面也没啥,效果是同样的。
还有一个引号的。
http://bbs.csdn.net/topics/390859703/“ 改成http://bbs.csdn.net/topics/390859703
前者是显示失败404
我想转成后者才是正常的。
你在什么浏览器测试,我这边效果是一样。
http://localhost/info.html\"
打算过滤掉多输入的\"
RewriteRule ^info.html(.*)$ member_info.php
已经搞定了, 这个可以匹配的到。

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics



Go Language Regular Expressions Practical Guide: How to Match Hexadecimal Color Codes Introduction: Regular expressions are a powerful and flexible tool for pattern matching and finding strings. In Go language, we can use the built-in regular expression package regexp to implement these operations. This article will introduce how to use regular expressions to match hexadecimal color codes in Go language. Importing the regular expression package First, we need to import the regular expression package regexp of the Go language. You can add the following import statement at the beginning of the code: i

PHP regular expressions are a powerful tool for text processing and conversion. It can effectively manage text information by parsing text content and replacing or intercepting it according to specific patterns. Among them, a common application of regular expressions is to replace strings starting with specific characters. We will explain this as follows

PHP regular expression practice: matching letters and numbers Regular expression is a tool used to match strings, which can easily realize string search, replacement, split and other operations. Regular expressions are also a very useful tool in PHP development. This article will introduce how to use PHP regular expressions to match letters and numbers. Matching a Single Character To match a single character, you can use the character classes in regular expressions. Character classes are represented by square brackets []. The characters in them represent the characters that can be matched. You can use hyphens - to represent ranges.

Golang regular expressions use the pipe character | to match multiple words or strings, separating each option as a logical OR expression. For example: matches "fox" or "dog": fox|dog matches "quick", "brown" or "lazy": (quick|brown|lazy) matches "Go", "Python" or "Java": Go|Python |Java matches words or 4-digit zip codes: ([a-zA

PHP Regular Expressions: Exact Matching and Exclusion Fuzzy inclusion regular expressions are a powerful text matching tool that can help programmers perform efficient search, replacement and filtering when processing text. In PHP, regular expressions are also widely used in string processing and data matching. This article will focus on how to perform exact matching and exclude fuzzy inclusion operations in PHP, and will illustrate it with specific code examples. Exact match Exact match means matching only strings that meet the exact condition, not any variations or extra words.

PHP String Matching Tips: Avoid Ambiguous Included Expressions In PHP development, string matching is a common task, usually used to find specific text content or to verify the format of input. However, sometimes we need to avoid using ambiguous inclusion expressions to ensure match accuracy. This article will introduce some techniques to avoid ambiguous inclusion expressions when doing string matching in PHP, and provide specific code examples. Use preg_match() function for exact matching In PHP, you can use preg_mat

How to remove Chinese in PHP using regular expressions: 1. Create a PHP sample file; 2. Define a string containing Chinese and English; 3. Use "preg_replace('/([\x80-\xff]*)/i', '',$a);" The regular method can remove Chinese characters from the query results.

In this article, we will learn how to remove HTML tags and extract plain text content from HTML strings using PHP regular expressions. To demonstrate how to remove HTML tags, let's first define a string containing HTML tags.
