FacebookFanpageImportAdmin

The Facebook Fanpage Import FacebookFanpageImportAdmin class.

Defined (1)

The class is defined in the following location(s).

/components/admin/component.php  
  1. class FacebookFanpageImportAdmin{ 
  2. var $name; 
  3.  
  4. /** 
  5. * Initializes the Component. 
  6. * @since 1.0.0 
  7. */ 
  8. function __construct() { 
  9. $this->name = get_class( $this ); 
  10. $this->includes(); 
  11.  
  12.  
  13. if( 'status' == skip\value( 'fbfpi_settings', 'insert_post_type' ) ) 
  14. add_action( 'init', array( $this, 'custom_post_types' ), 11 ); 
  15.  
  16.  
  17. // Functions in Admin 
  18. if( is_admin() ): 
  19. // add_action( 'admin_menu', array( $this, 'admin_menu' ) ); 
  20. endif; 
  21. } // end constructor 
  22.  
  23.  
  24. /** 
  25. * Creates Custom Post Types 
  26. * @since 1.0.0 
  27. */  
  28. public function custom_post_types() { 
  29. $args_post_type = array( 
  30. 'labels' => array( 
  31. 'name' => __( 'Status Messages', 'fbfpi-locale' ),  
  32. 'singular_name' => __( 'Status Message', 'fbfpi-locale' ) 
  33. ),  
  34. 'public' => TRUE,  
  35. 'has_archive' => TRUE,  
  36. 'supports' => array( 'title', 'editor', 'author', 'thumbnail', 'excerpt', 'comments' ),  
  37. 'rewrite' => array( 
  38. 'slug' => 'status-message',  
  39. 'with_front' => TRUE 
  40. );  
  41. register_post_type( 'status-message', $args_post_type );  
  42.  
  43. /** 
  44. * Including needed Files. 
  45. * @since 1.0.0 
  46. */  
  47. private function includes() { 
  48. include( dirname(__FILE__) . '/settings.php' );