Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
linkchecker-3247797
Manage
Activity
Members
Labels
Plan
Custom issue tracker
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Issue forks
linkchecker-3247797
Commits
c8849a95
Commit
c8849a95
authored
11 years ago
by
Alexander Hass
Browse files
Options
Downloads
Patches
Plain Diff
Issue
#1923328
by larowlan: Fragment check fails when source page
contains spaces between attribute name, equals and value.
parent
b580073f
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
CHANGELOG.txt
+1
-0
1 addition, 0 deletions
CHANGELOG.txt
linkchecker.module
+1
-1
1 addition, 1 deletion
linkchecker.module
with
2 additions
and
1 deletion
CHANGELOG.txt
+
1
−
0
View file @
c8849a95
linkchecker 6.x-dev, nightly
----------------------------
* Issue #1923328 by larowlan: Fragment check fails when source page contains spaces between attribute name, equals and value.
* Issue #1926558 by hass: Block extraction re-scans fail.
linkchecker 6.x-2.7, February 14, 2012
...
...
This diff is collapsed.
Click to expand it.
linkchecker.module
+
1
−
1
View file @
c8849a95
...
...
@@ -515,7 +515,7 @@ function _linkchecker_status_handling(&$response, $link) {
// element (naming it with the name attribute), or by any other element
// (naming with the id attribute).
// See http://www.w3.org/TR/html401/struct/links.html
if
(
$response
->
code
==
200
&&
!
empty
(
$response
->
uri
[
'fragment'
])
&&
(
!
empty
(
$response
->
data
)
&&
!
preg_match
(
'/(\s[^>]*(name|id)
=
["\'])('
.
preg_quote
(
$response
->
uri
[
'fragment'
],
'/'
)
.
')(["\'][^>]*>)/i'
,
$response
->
data
)))
{
if
(
$response
->
code
==
200
&&
!
empty
(
$response
->
uri
[
'fragment'
])
&&
(
!
empty
(
$response
->
data
)
&&
!
preg_match
(
'/(\s[^>]*(name|id)
(\s+)?=(\s+)?
["\'])('
.
preg_quote
(
$response
->
uri
[
'fragment'
],
'/'
)
.
')(["\'][^>]*>)/i'
,
$response
->
data
)))
{
// Override status code 200 with status code 404 so it can be handled with
// default status code 404 logic and custom error text.
$response
->
code
=
404
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment