fbcomments_init

The WordPress Core fbcomments init function.

Description

fbcomments_init(); 

Usage

  1. if ( !function_exists( 'fbcomments_init' ) ) { 
  2. require_once '/class-admin.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = fbcomments_init(); 
  7.  

Defined (1)

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

/class-admin.php  
  1. function fbcomments_init() { 
  2. register_setting( 'fbcomments_options', 'fbcomments' ); 
  3. $new_options = array( 
  4. 'fbml' => 'on',  
  5. 'opengraph' => 'off',  
  6. 'fbns' => 'off',  
  7. 'html5' => 'on',  
  8. 'posts' => 'on',  
  9. 'pages' => 'off',  
  10. 'homepage' => 'off',  
  11. 'appID' => '',  
  12. 'mods' => '',  
  13. 'num' => '5',  
  14. 'count' => 'on',  
  15. 'countmsg' => 'comments',  
  16. 'title' => 'Comments',  
  17. 'titleclass' => '',  
  18. 'width' => '100%',  
  19. 'countstyle' => '',  
  20. 'linklove' => 'off',  
  21. 'scheme' => 'light',  
  22. 'language' => 'en_US' 
  23. ); 
  24.  
  25. // if old options exist, update to array 
  26. foreach( $new_options as $key => $value ) { 
  27. if( $existing = get_option( 'fbcomments_' . $key ) ) { 
  28. $new_options[$key] = $existing; 
  29. delete_option( 'fbcomments_' . $key ); 
  30.  
  31.  
  32.  
  33. add_option( 'fbcomments', $new_options );