Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Open sidebar
drupal.org
better_formats
Commits
00ada777
Commit
00ada777
authored
Apr 30, 2009
by
dragonwize
Browse files
Added #358291 by dragonwize: Added CCK single line textfield support.
parent
21e50720
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
6 deletions
+10
-6
better_formats.module
better_formats.module
+10
-6
No files found.
better_formats.module
View file @
00ada777
...
...
@@ -274,25 +274,29 @@ function better_formats_node_type($op, $info) {
/**
* Implementation of hook_elements().
*
* Adds a process function to CCK's text
area
FAPI element.
* Adds a process function to CCK's text
module
FAPI element
s
.
*/
function
better_formats_elements
()
{
return
array
(
'text_textfield'
=>
array
(
'#process'
=>
array
(
'better_formats_text_process'
),
),
'text_textarea'
=>
array
(
'#process'
=>
array
(
'better_formats_text
area
_process'
),
'#process'
=>
array
(
'better_formats_text_process'
),
),
);
}
/**
* Processes a CCK text
area
element.
* Processes a CCK text element
s
.
*
* Resets the
textareas
filter area with bettter_formats default.
* This function is used to affect CCK text
area
s not core fields.
* Resets the filter area with bettter_formats default.
* This function is used to affect CCK text
module field
s not core fields.
*
* @see text_textfield_process()
* @see text_textarea_process()
*/
function
better_formats_text
area
_process
(
$element
,
$edit
,
$form_state
,
$form
)
{
function
better_formats_text_process
(
$element
,
$edit
,
$form_state
,
$form
)
{
$field
=
$form
[
'#field_info'
][
$element
[
'#field_name'
]];
if
(
!
empty
(
$field
[
'text_processing'
]))
{
...
...
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