Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
drupal.org
link
Commits
abe870d8
Commit
abe870d8
authored
Jun 21, 2008
by
Nathan Haug
Browse files
#272444 by spatz4000. Spelling corrections.
parent
fb1abc90
Changes
1
Hide whitespace changes
Inline
Side-by-side
link.module
View file @
abe870d8
...
...
@@ -123,7 +123,7 @@ function link_field_settings($op, $field) {
$form
[
'attributes'
][
'class'
]
=
array
(
'#type'
=>
'textfield'
,
'#title'
=>
t
(
'Additional CSS Class'
),
'#description'
=>
t
(
'When output, this link will have have this class attribute. Multiple classes should be sep
e
rated by spaces.'
),
'#description'
=>
t
(
'When output, this link will have have this class attribute. Multiple classes should be sep
a
rated by spaces.'
),
'#default_value'
=>
empty
(
$field
[
'attributes'
][
'class'
])
?
''
:
$field
[
'attributes'
][
'class'
],
);
return
$form
;
...
...
@@ -310,12 +310,12 @@ function _link_sanitize(&$item, $delta, &$field, &$node) {
$type
=
link_validate_url
(
$item
[
'url'
]);
$url
=
link_cleanup_url
(
$item
[
'url'
]);
// Sep
e
rate out the anchor if any.
// Sep
a
rate out the anchor if any.
if
(
strpos
(
$url
,
'#'
)
!==
FALSE
)
{
$item
[
'fragment'
]
=
substr
(
$url
,
strpos
(
$url
,
'#'
)
+
1
);
$url
=
substr
(
$url
,
0
,
strpos
(
$url
,
'#'
));
}
// Sep
e
rate out the query string if any.
// Sep
a
rate out the query string if any.
if
(
strpos
(
$url
,
'?'
)
!==
FALSE
)
{
$item
[
'query'
]
=
substr
(
$url
,
strpos
(
$url
,
'?'
)
+
1
);
$url
=
substr
(
$url
,
0
,
strpos
(
$url
,
'?'
));
...
...
Write
Preview
Supports
Markdown
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