Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
E
expire
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
drupal.org
expire
Commits
1e4ccc93
Commit
1e4ccc93
authored
Jun 12, 2015
by
Spleshka
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Issue #1780144: Should expire.module urlencode urls
parent
0bacb207
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
3 deletions
+19
-3
includes/expire.api.inc
includes/expire.api.inc
+19
-3
No files found.
includes/expire.api.inc
View file @
1e4ccc93
...
...
@@ -92,8 +92,13 @@ class ExpireAPI {
// If base site url should be included, then simply add it to the internal paths.
if
(
$include_base_url
)
{
foreach
(
$urls
as
$internal_path
)
{
$urls
[
$internal_path
]
=
url
(
$internal_path
,
array
(
'absolute'
=>
TRUE
,
'alias'
=>
TRUE
,
'language'
=>
$language
));
foreach
(
$urls
as
$raw_url
=>
$url
)
{
$urls
[
$raw_url
]
=
url
(
$url
[
'path'
],
array
(
'absolute'
=>
TRUE
,
'alias'
=>
TRUE
,
'language'
=>
$language
,
'query'
=>
$url
[
'query'
],
));
}
}
}
...
...
@@ -408,8 +413,19 @@ class ExpireAPI {
$path
=
implode
(
'|'
,
$path_parts
);
}
// Parse internal path.
$parsed_path
=
parse_url
(
$path
);
if
(
!
empty
(
$parsed_path
[
'query'
]))
{
// Parse the query string into array.
parse_str
(
$parsed_path
[
'query'
],
$parsed_path
[
'query'
]);
}
// Collect array with information about expired URLs and its wildcards.
$urls
[
$path
]
=
$path
;
$urls
[
$path
]
=
array
(
'path'
=>
$parsed_path
[
'path'
],
'query'
=>
!
empty
(
$parsed_path
[
'query'
])
?
$parsed_path
[
'query'
]
:
array
(),
);
$wildcards
[
$path
]
=
$wildcard
;
// Don't process empty pass, because otherwise drupal will return us
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment