Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
D
drupal
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Custom Issue Tracker
Custom Issue Tracker
Labels
Merge Requests
306
Merge Requests
306
Requirements
Requirements
List
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Analytics
Analytics
Code Review
Insights
Issue
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
project
drupal
Commits
36fce2f0
Commit
36fce2f0
authored
Dec 30, 2006
by
drumm
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
#18870
by zen. Only allow the new comment anchor to be output forthe first new comment.
parent
77176a8f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
modules/comment/comment.module
modules/comment/comment.module
+6
-2
No files found.
modules/comment/comment.module
View file @
36fce2f0
...
...
@@ -1679,10 +1679,14 @@ function theme_comment_preview($comment, $links = array(), $visible = 1) {
};
function
theme_comment_view
(
$comment
,
$links
=
array
(),
$visible
=
1
)
{
static
$first_new
=
TRUE
;
// Emit selectors:
$output
=
''
;
if
((
$comment
->
new
=
node_mark
(
$comment
->
nid
,
$comment
->
timestamp
))
!=
MARK_READ
)
{
$comment
->
new
=
node_mark
(
$comment
->
nid
,
$comment
->
timestamp
);
if
(
$first_new
&&
$comment
->
new
!=
MARK_READ
)
{
// Assign the anchor only for the first new comment. This avoids duplicate
// id attributes on a page.
$first_new
=
FALSE
;
$output
.
=
"<a id=
\"
new
\"
></a>
\n
"
;
}
...
...
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