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
27b17eb1
Commit
27b17eb1
authored
14 years ago
by
Alex Barth
Browse files
Options
Downloads
Patches
Plain Diff
Convert class strings to class arrays.
parent
28933bf1
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
feeds_ui/feeds_ui.admin.inc
+12
-12
12 additions, 12 deletions
feeds_ui/feeds_ui.admin.inc
with
12 additions
and
12 deletions
feeds_ui/feeds_ui.admin.inc
+
12
−
12
View file @
27b17eb1
...
@@ -160,7 +160,7 @@ function feeds_ui_create_form(&$form_state, $from_importer = NULL) {
...
@@ -160,7 +160,7 @@ function feeds_ui_create_form(&$form_state, $from_importer = NULL) {
'#description'
=>
t
(
'A natural name for this configuration. Example: RSS Feed. You can always change this name later.'
),
'#description'
=>
t
(
'A natural name for this configuration. Example: RSS Feed. You can always change this name later.'
),
'#required'
=>
TRUE
,
'#required'
=>
TRUE
,
'#maxlength'
=>
128
,
'#maxlength'
=>
128
,
'#attributes'
=>
array
(
'class'
=>
'feed-name'
),
'#attributes'
=>
array
(
'class'
=>
array
(
'feed-name'
)
)
,
);
);
$form
[
'id'
]
=
array
(
$form
[
'id'
]
=
array
(
'#type'
=>
'textfield'
,
'#type'
=>
'textfield'
,
...
@@ -168,7 +168,7 @@ function feeds_ui_create_form(&$form_state, $from_importer = NULL) {
...
@@ -168,7 +168,7 @@ function feeds_ui_create_form(&$form_state, $from_importer = NULL) {
'#description'
=>
t
(
'A unique identifier for this configuration. Example: rss_feed. Must only contain lower case characters, numbers and underscores.'
),
'#description'
=>
t
(
'A unique identifier for this configuration. Example: rss_feed. Must only contain lower case characters, numbers and underscores.'
),
'#required'
=>
TRUE
,
'#required'
=>
TRUE
,
'#maxlength'
=>
128
,
'#maxlength'
=>
128
,
'#attributes'
=>
array
(
'class'
=>
'feed-id'
),
'#attributes'
=>
array
(
'class'
=>
array
(
'feed-id'
)
)
,
);
);
$form
[
'description'
]
=
array
(
$form
[
'description'
]
=
array
(
'#type'
=>
'textfield'
,
'#type'
=>
'textfield'
,
...
@@ -279,7 +279,7 @@ function feeds_ui_edit_page($importer, $active = 'help', $plugin_key = '') {
...
@@ -279,7 +279,7 @@ function feeds_ui_edit_page($importer, $active = 'help', $plugin_key = '') {
$path
=
'admin/build/feeds/edit/'
.
$importer
->
id
;
$path
=
'admin/build/feeds/edit/'
.
$importer
->
id
;
$active_container
=
array
(
$active_container
=
array
(
'class'
=>
'active-container'
,
'class'
=>
array
(
'active-container'
)
,
'actions'
=>
array
(
l
(
t
(
'Help'
),
$path
)),
'actions'
=>
array
(
l
(
t
(
'Help'
),
$path
)),
);
);
switch
(
$active
)
{
switch
(
$active
)
{
...
@@ -316,7 +316,7 @@ function feeds_ui_edit_page($importer, $active = 'help', $plugin_key = '') {
...
@@ -316,7 +316,7 @@ function feeds_ui_edit_page($importer, $active = 'help', $plugin_key = '') {
// Build config info.
// Build config info.
$config_info
=
$info
=
array
();
$config_info
=
$info
=
array
();
$info
[
'class'
]
=
'config-set'
;
$info
[
'class'
]
=
array
(
'config-set'
)
;
// Basic information.
// Basic information.
$items
=
array
();
$items
=
array
();
...
@@ -430,7 +430,7 @@ function feeds_ui_plugin_form(&$form_state, $importer, $type) {
...
@@ -430,7 +430,7 @@ function feeds_ui_plugin_form(&$form_state, $importer, $type) {
$form
[
'submit'
]
=
array
(
$form
[
'submit'
]
=
array
(
'#type'
=>
'submit'
,
'#type'
=>
'submit'
,
'#value'
=>
t
(
'Save'
),
'#value'
=>
t
(
'Save'
),
'#attributes'
=>
array
(
'class'
=>
'feeds-ui-hidden-submit'
),
'#attributes'
=>
array
(
'class'
=>
array
(
'feeds-ui-hidden-submit'
)
)
,
);
);
return
$form
;
return
$form
;
}
}
...
@@ -460,7 +460,7 @@ function theme_feeds_ui_plugin_form($form) {
...
@@ -460,7 +460,7 @@ function theme_feeds_ui_plugin_form($form) {
'body'
=>
$form
[
'plugin_key'
][
$key
][
'#description'
],
'body'
=>
$form
[
'plugin_key'
][
$key
][
'#description'
],
);
);
$form
[
'plugin_key'
][
$key
][
'#title'
]
=
t
(
'Select'
);
$form
[
'plugin_key'
][
$key
][
'#title'
]
=
t
(
'Select'
);
$form
[
'plugin_key'
][
$key
][
'#attributes'
][
'class'
]
=
'feeds-ui-radio-link'
;
$form
[
'plugin_key'
][
$key
][
'#attributes'
][
'class'
]
=
array
(
'feeds-ui-radio-link'
)
;
unset
(
$form
[
'plugin_key'
][
$key
][
'#description'
]);
unset
(
$form
[
'plugin_key'
][
$key
][
'#description'
]);
$container
[
'actions'
]
=
array
(
drupal_render
(
$form
[
'plugin_key'
][
$key
]));
$container
[
'actions'
]
=
array
(
drupal_render
(
$form
[
'plugin_key'
][
$key
]));
...
@@ -530,7 +530,7 @@ function feeds_ui_mapping_form(&$form_state, $importer) {
...
@@ -530,7 +530,7 @@ function feeds_ui_mapping_form(&$form_state, $importer) {
$form
[
'unique_flags'
][
$i
]
=
array
(
$form
[
'unique_flags'
][
$i
]
=
array
(
'#type'
=>
'checkbox'
,
'#type'
=>
'checkbox'
,
'#default_value'
=>
!
empty
(
$mapping
[
'unique'
]),
'#default_value'
=>
!
empty
(
$mapping
[
'unique'
]),
'#attributes'
=>
array
(
'class'
=>
'feeds-ui-trigger-submit'
),
'#attributes'
=>
array
(
'class'
=>
array
(
'feeds-ui-trigger-submit'
)
)
,
);
);
}
}
$form
[
'remove_flags'
][
$i
]
=
array
(
$form
[
'remove_flags'
][
$i
]
=
array
(
...
@@ -553,7 +553,7 @@ function feeds_ui_mapping_form(&$form_state, $importer) {
...
@@ -553,7 +553,7 @@ function feeds_ui_mapping_form(&$form_state, $importer) {
'#type'
=>
'textfield'
,
'#type'
=>
'textfield'
,
'#size'
=>
20
,
'#size'
=>
20
,
'#default_value'
=>
t
(
'Name of source field'
),
'#default_value'
=>
t
(
'Name of source field'
),
'#attributes'
=>
array
(
'class'
=>
'hide-text-on-focus'
),
'#attributes'
=>
array
(
'class'
=>
array
(
'hide-text-on-focus'
)
)
,
);
);
}
}
$form
[
'target'
]
=
array
(
$form
[
'target'
]
=
array
(
...
@@ -568,7 +568,7 @@ function feeds_ui_mapping_form(&$form_state, $importer) {
...
@@ -568,7 +568,7 @@ function feeds_ui_mapping_form(&$form_state, $importer) {
$form
[
'save'
]
=
array
(
$form
[
'save'
]
=
array
(
'#type'
=>
'submit'
,
'#type'
=>
'submit'
,
'#value'
=>
t
(
'Save'
),
'#value'
=>
t
(
'Save'
),
'#attributes'
=>
array
(
'class'
=>
'feeds-ui-hidden-submit'
),
'#attributes'
=>
array
(
'class'
=>
array
(
'feeds-ui-hidden-submit'
)
)
,
);
);
return
$form
;
return
$form
;
}
}
...
@@ -715,15 +715,15 @@ function theme_feeds_ui_edit_page($config_info, $active_container) {
...
@@ -715,15 +715,15 @@ function theme_feeds_ui_edit_page($config_info, $active_container) {
* 'title' => 'the title',
* 'title' => 'the title',
* 'body' => 'the body of the container, may also be an array of more
* 'body' => 'the body of the container, may also be an array of more
* containers.',
* containers.',
* 'class' => 'the class of the container.',
* 'class' =>
array(
'the class of the container.'
)
,
* 'id' => 'the id of the container',
* 'id' => 'the id of the container',
* );
* );
*/
*/
function
theme_feeds_ui_container
(
$container
)
{
function
theme_feeds_ui_container
(
$container
)
{
$class
=
empty
(
$container
[
'class'
])
?
'
plain'
:
"
{
$container
[
'class'
]
}
"
;
$class
=
empty
(
$container
[
'class'
])
?
array
(
'plain'
)
:
$container
[
'class'
];
$id
=
empty
(
$container
[
'id'
])
?
''
:
' id="'
.
$container
[
'id'
]
.
'"'
;
$id
=
empty
(
$container
[
'id'
])
?
''
:
' id="'
.
$container
[
'id'
]
.
'"'
;
$output
=
'<div class="feeds-container'
.
$class
.
'"'
.
$id
.
'>'
;
$output
=
'<div class="feeds-container'
.
explode
(
' '
,
$class
)
.
'"'
.
$id
.
'>'
;
if
(
isset
(
$container
[
'actions'
])
&&
count
(
$container
[
'actions'
]))
{
if
(
isset
(
$container
[
'actions'
])
&&
count
(
$container
[
'actions'
]))
{
$output
.
=
'<ul class="container-actions">'
;
$output
.
=
'<ul class="container-actions">'
;
...
...
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