Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
feeds
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
drupal.org
feeds
Commits
49535c9b
Commit
49535c9b
authored
12 years ago
by
Franz Glauber Vanderlinde
Browse files
Options
Downloads
Patches
Plain Diff
Issue #1450714 by getgood: ATOM parser ignores 'updated' tag
parent
48b9f61e
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
libraries/common_syndication_parser.inc
+13
-1
13 additions, 1 deletion
libraries/common_syndication_parser.inc
with
13 additions
and
1 deletion
libraries/common_syndication_parser.inc
+
13
−
1
View file @
49535c9b
...
@@ -201,7 +201,19 @@ function _parser_common_syndication_atom10_parse($feed_XML) {
...
@@ -201,7 +201,19 @@ function _parser_common_syndication_atom10_parse($feed_XML) {
$item
[
'title'
]
=
_parser_common_syndication_title
(
$title
,
$body
);
$item
[
'title'
]
=
_parser_common_syndication_title
(
$title
,
$body
);
$item
[
'description'
]
=
$body
;
$item
[
'description'
]
=
$body
;
$item
[
'author_name'
]
=
$original_author
;
$item
[
'author_name'
]
=
$original_author
;
$item
[
'timestamp'
]
=
_parser_common_syndication_parse_date
(
isset
(
$news
->
published
)
?
"
{
$news
->
published
}
"
:
"
{
$news
->
issued
}
"
);
// Fall back to updated for timestamp if both published and issued are
// empty.
if
(
isset
(
$news
->
published
))
{
$item
[
'timestamp'
]
=
_parser_common_syndication_parse_date
(
"
{
$news
->
published
}
"
);
}
elseif
(
isset
(
$news
->
issued
))
{
$item
[
'timestamp'
]
=
_parser_common_syndication_parse_date
(
"
{
$news
->
issued
}
"
);
}
elseif
(
isset
(
$news
->
updated
))
{
$item
[
'timestamp'
]
=
_parser_common_syndication_parse_date
(
"
{
$news
->
updated
}
"
);
}
$item
[
'url'
]
=
trim
(
$original_url
);
$item
[
'url'
]
=
trim
(
$original_url
);
if
(
valid_url
(
$item
[
'url'
])
&&
!
valid_url
(
$item
[
'url'
],
TRUE
)
&&
!
empty
(
$base
))
{
if
(
valid_url
(
$item
[
'url'
])
&&
!
valid_url
(
$item
[
'url'
],
TRUE
)
&&
!
empty
(
$base
))
{
$item
[
'url'
]
=
$base
.
$item
[
'url'
];
$item
[
'url'
]
=
$base
.
$item
[
'url'
];
...
...
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