function fb_instant_articles_display_get_article_entity_types in Facebook Instant Articles 7.2
Same name and namespace in other branches
- 7 modules/fb_instant_articles_display/fb_instant_articles_display.module \fb_instant_articles_display_get_article_entity_types()
Gets entity types that are treated as Facebook Instant Articles.
Return value
mixed Array of entity types and bundles.
6 calls to fb_instant_articles_display_get_article_entity_types()
- fb_instant_articles_display_entity_info_alter in modules/
fb_instant_articles_display/ fb_instant_articles_display.module - Implements hook_entity_info_alter().
- fb_instant_articles_display_entity_load in modules/
fb_instant_articles_display/ fb_instant_articles_display.module - Implements hook_entity_load().
- fb_instant_articles_display_is_article_type in modules/
fb_instant_articles_display/ fb_instant_articles_display.module - Checks if an entity type and bundle are a Facebook Instant Article type.
- fb_instant_articles_rss_get_article_nodes in modules/
fb_instant_articles_rss/ includes/ rss.inc - Return an array of nodes that are treated as articles.
- fb_instant_articles_rss_mass_update in modules/
fb_instant_articles_rss/ fb_instant_articles_rss.module - Makes mass update of fia_enabled status for selected nodes.
File
- modules/
fb_instant_articles_display/ fb_instant_articles_display.module, line 259 - Hook implementations for Facebook Instant Articles Display module.
Code
function fb_instant_articles_display_get_article_entity_types() {
ctools_include('export');
$fia_entity_types = ctools_export_crud_load_all('fb_instant_articles_display_entity_types');
$entity_types = array();
foreach ($fia_entity_types as $fia_entity_type) {
$entity_types[$fia_entity_type->entity_type][$fia_entity_type->entity_bundle] = array(
'type' => $fia_entity_type->entity_type,
'bundle' => $fia_entity_type->entity_bundle,
);
}
// Allow other modules to alter.
drupal_alter('fb_instant_articles_display_entity_types', $entity_types);
return $entity_types;
}