'', 'nBooks' => 6, 'title' => 'aNobii', 'showCredits' => 1 ); function anobii_options_page() { global $anobii_defaults; // If it's called after a POST... if (isset($_POST['anobii_submit'])) { $options = (array) get_option('anobii_options'); $options['anobii_url'] = strip_tags(stripslashes($_POST['anobii_url'])); $options['nBooks'] = intval($_POST['nBooks']); update_option('anobii_options', $options); // Update message echo "

aNobii Options Updated

"; } $options = get_option('anobii_options'); $anobii_url = ( $options['anobii_url'] != '' ) ? $options['anobii_url'] : $anobii_defaults['anobii_url']; $nBooks = ( $options['nBooks'] != '' ) ? $options['nBooks'] : $anobii_defaults['nBooks']; ?>

aNobii Plugin Options

In the following extremely complex form you need to specify the url to the main page of your aNobii's profile using the alphanumeric format.
If you chose a short format for your aNobii url (e.g.: http://www.anobii.com/people/jhack ) you must retrieve your user-id from the Feed RSS url near to the bottom of your aNobii's Home Profile.
Therefore the url you must provide here must be something like http://www.anobii.com/people/010c51b082b89840a7 .



\n"; ?>

'; $before_title = isset($before_title) ? $before_title : '

'; $after_title = isset($after_title) ? $after_title : '

'; $after_widget = isset($after_widget) ? $after_widget : ''; // http://www.anobii.com/people/$uid $nBooks = $options['nBooks']; $uid = basename($options['anobii_url']); $curPath = get_option('siteurl').anobiiDirpath; echo $before_widget; echo $before_title . $options['title'] . $after_title; echo "
"; echo "
"; echo ""; echo "
\"Reload
"; echo "
"; echo "
"; echo "Reload me, please :("; echo "
"; if ( ! $options['showCredits'] ) $hide = 'class="hide"'; echo '
developed by Jhack
'; echo "
"; echo " \n"; echo " \n"; /* echo "";*/ echo $after_widget; ?>

'; echo '

'; echo ''; } function anobii_widget_init() { // Check if the environment supports widgets if (!function_exists('register_sidebar_widget')) return; register_sidebar_widget(array('aNobii Widget', 'widgets'), 'anobii_widget'); register_widget_control(array('aNobii Widget', 'widgets'), 'anobii_widget_control', 200, 100); } function anobii_stylesheet() { $curPath = get_option('siteurl').anobiiDirpath; echo ""; } // Create the option menu add_action('admin_menu', 'anobii_options_menu' ); // Initialize the widget add_action('widgets_init', 'anobii_widget_init'); // Add stylesheet to head add_action('wp_head', 'anobii_stylesheet'); ?>