public function action_update_check()
 {
     // add an extra GUID, in addition to the one in our .xml file to pretend a theme was registered
     Update::add('Test', '10cbaf18-bdd2-48e1-b0d3-e1853a4c649d', '3.0.2');
     // add an extra GUID, in addition to the one in our .xml file to pretend a plugin was registered
     Update::add('Test', '7a0313be-d8e3-11d1-8314-0800200c9a66', '0.9');
 }
Example #2
0
 /**
  * Perform a check of all beaconids.
  * Notifies update_check plugin hooks when checking so that they can add their beaconids to the list.
  * @return array An array of update beacon information for components that have updates
  */
 public static function check()
 {
     try {
         $instance = self::instance();
         if (count($instance->beacons) == 0) {
             Update::add('Habari', '7a0313be-d8e3-11db-8314-0800200c9a66', Version::get_habariversion());
             Plugins::act('update_check');
         }
         $request = new RemoteRequest(UPDATE_URL, 'POST');
         $request->set_params(array_map(create_function('$a', 'return $a["version"];'), $instance->beacons));
         $request->set_timeout(10);
         $result = $request->execute();
         if (Error::is_error($result)) {
             throw $result;
         }
         $updatedata = $request->get_response_body();
         if (Error::is_error($updatedata)) {
             throw $updatedata;
         }
         $instance->update = new SimpleXMLElement($updatedata);
         foreach ($instance->update as $beacon) {
             $beaconid = (string) $beacon['id'];
             foreach ($beacon->update as $update) {
                 // Do we have this beacon?  If not, don't process it.
                 if (empty($instance->beacons[$beaconid])) {
                     continue;
                 }
                 // If the remote update info version is newer...
                 if (version_compare($update['version'], $instance->beacons[$beaconid]['version']) > 0) {
                     // If this version is more recent than all other newer versions...
                     if (empty($instance->beacons[$beaconid]['latest_version']) || version_compare((string) $update['version'], $instance->beacons[$beaconid]['latest_version']) > 0) {
                         $instance->beacons[$beaconid]['latest_version'] = (string) $update['version'];
                     }
                     if (isset($instance->beacons[$beaconid]['severity'])) {
                         $instance->beacons[$beaconid]['severity'][] = (string) $update['severity'];
                         array_unique($instance->beacons[$beaconid]['severity']);
                     } else {
                         $instance->beacons[$beaconid]['severity'] = array((string) $update['severity']);
                     }
                     $instance->beacons[$beaconid]['url'] = (string) $beacon['url'];
                     $instance->beacons[$beaconid]['changes'][(string) $update['version']] = (string) $update;
                 }
             }
         }
         return array_filter($instance->beacons, array('Update', 'filter_unchanged'));
     } catch (Exception $e) {
         return $e;
     }
 }
Example #3
0
 /**
  * action: update_check
  *
  * @access public
  * @return void
  */
 public function action_update_check()
 {
     Update::add($this->info->name, $this->info->guid, $this->info->version);
 }
 function action_update_check()
 {
     Update::add('Lifestream', '122b28dc-0861-11dc-8314-0800200c9a66', self::VERSION);
 }
Example #5
0
 public function action_update_check()
 {
     Update::add('hpm', '693E59D6-2B5F-11DD-A23A-9E6C56D89593', $this->info->version);
 }
Example #6
0
 /**
  * Enable update notices to be sent using the Habari beacon
  */
 public function action_update_check()
 {
     Update::add('IncomingLinks', 'f33b2428-facb-43b7-bb44-a8d78cb3ff9d', $this->info->version);
 }
 /**
  * Add update beacon support
  **/
 public function action_update_check()
 {
     Update::add('Syntax Highlighter', 'CD64FF02-B078-11DD-9AA2-3F8056D89593', $this->info->version);
 }
 /**
  * Add update beacon support
  **/
 public function action_update_check()
 {
     Update::add('Colophon', 'c3eaec26-0bde-44db-b1f6-baaa8aedefea', $this->info->version);
 }
 /**
  * Add update beacon support
  **/
 public function action_update_check()
 {
     Update::add('Breezy Archives', '2f6d8d49-1e93-4c46-924f-af8a351af10a', $this->info->version);
 }
Example #10
0
 /**
  * Add update beacon support
  **/
 public function action_update_check()
 {
     Update::add('GoogleAnalytics', '7e57a660-3bd1-11dd-ae16-0800200c9a66', $this->info->version);
 }
 function action_update_check()
 {
     Update::add('GetClicky Analytics', '5F271634-89B7-11DD-BE47-289255D89593', $this->info->version);
 }
 /**
  * Add update beacon support
  **/
 public function action_update_check()
 {
     Update::add($this->info->name, '7cc973f3-dd6e-4081-98a3-535c7bf6e799', $this->info->version);
 }
 /**
  * Add update beacon support
  **/
 public function action_update_check()
 {
     Update::add('Tabasamu', '2a236020-7475-11dd-ad8b-0800200c9a66', $this->info->version);
 }
 /**
  * action: update_check
  *
  * @access public
  * @return void
  */
 public function action_update_check()
 {
     Update::add('Twitter Avatar', '3d327504-f01b-11dd-bd4c-001b210f913f', $this->info->version);
 }
Example #15
0
 /**
  * Handles GET requests for the theme listing
  */
 public function get_themes()
 {
     $all_themes = Themes::get_all_data();
     foreach ($all_themes as $name => $theme) {
         if (isset($all_themes[$name]['info']->update) && $all_themes[$name]['info']->update != '' && isset($all_themes[$name]['info']->version) && $all_themes[$name]['info']->version != '') {
             Update::add($name, $all_themes[$name]['info']->update, $all_themes[$name]['info']->version);
         }
     }
     $updates = Update::check();
     foreach ($all_themes as $name => $theme) {
         if (isset($all_themes[$name]['info']->update) && isset($updates[$all_themes[$name]['info']->update])) {
             $all_themes[$name]['info']->update = $updates[$all_themes[$name]['info']->update]['latest_version'];
         } else {
             $all_themes[$name]['info']->update = '';
         }
     }
     $this->theme->all_themes = $all_themes;
     $this->theme->active_theme = Themes::get_active_data(true);
     $this->theme->active_theme_dir = $this->theme->active_theme['path'];
     // If the active theme is configurable, allow it to configure
     $this->theme->active_theme_name = $this->theme->active_theme['info']->name;
     $this->theme->configurable = Plugins::filter('theme_config', false, $this->active_theme);
     $this->theme->assign('configure', Controller::get_var('configure'));
     $activedata = Themes::get_active_data(true);
     $areas = array();
     if (isset($activedata['info']->areas->area)) {
         foreach ($activedata['info']->areas->area as $area) {
             $areas[] = (string) $area;
         }
     }
     $this->theme->areas = $areas;
     $this->theme->previewed = Themes::get_theme_dir(false);
     $this->theme->blocks = Plugins::filter('block_list', array());
     $this->theme->block_instances = DB::get_results('SELECT b.* FROM {blocks} b ORDER BY b.title ASC', array(), 'Block');
     $blocks_areas_t = DB::get_results('SELECT b.*, ba.scope_id, ba.area, ba.display_order FROM {blocks} b INNER JOIN {blocks_areas} ba ON ba.block_id = b.id ORDER BY ba.scope_id ASC, ba.area ASC, ba.display_order ASC', array());
     $blocks_areas = array();
     foreach ($blocks_areas_t as $block) {
         if (!isset($blocks_areas[$block->scope_id])) {
             $blocks_areas[$block->scope_id] = array();
         }
         $blocks_areas[$block->scope_id][$block->area][$block->display_order] = $block;
     }
     $this->theme->blocks_areas = $blocks_areas;
     $this->theme->scopes = DB::get_results('SELECT * FROM {scopes} ORDER BY id ASC;');
     $this->theme->theme_loader = Plugins::filter('theme_loader', '', $this->theme);
     $this->theme->display('themes');
 }
 /**
  * Adds the plugin to the update check routine.
  */
 public function action_update_check()
 {
     Update::add('StaticCache', '340fb135-e1a1-4351-a81c-dac2f1795169', self::VERSION);
 }
 /**
  * Add update beacon support
  **/
 public function action_update_check()
 {
     Update::add($this->info->name, '9bfb17aa-f8f0-4638-a549-af4f86a9d412', $this->info->version);
 }
Example #18
0
 /**
  * Add update beacon support
  **/
 public function action_update_check()
 {
     Update::add('Twitter', 'DD2774BA-96ED-11DC-ABEF-3BAA56D89593', $this->info->version);
 }
 /**
  * Pro-forma update beacon support
  **/
 public function action_update_check()
 {
     Update::add('StatusNet', '8676A858-E4B1-11DD-9968-131C56D89593', $this->info->version);
 }
 /**
  * Add update beacon support
  **/
 public function action_update_check()
 {
     Update::add('KeyNavigation', '', $this->info->version);
 }
 public function action_update_check()
 {
     Update::add($this->info->name, 'c7d47111-d452-4522-a343-f1d0df1d9095', $this->info->version);
 }
Example #22
0
 public function action_update_check()
 {
     Update::add(self::PLUGIN_NAME, self::GUID, $this->info->version);
 }
 /**
  * Add update beacon support
  **/
 public function action_update_check()
 {
     Update::add('DateNinja', 'e64e02e0-38f8-11dd-ae16-0800200c9a66', $this->info->version);
 }
 /**
  * Add update beacon support
  **/
 public function action_update_check()
 {
     Update::add($this->info->name, 'c330c3fe-3f34-47ff-b5c7-51b2269cfaed', $this->info->version);
 }
 /**
  * Add update beacon support
  **/
 public function action_update_check()
 {
     Update::add('Fontdeck', '483f2c57-3e38-48cc-87c1-f38c28aec691', $this->info->version);
 }
Example #26
0
 /**
  * Implement the update notification feature
  */
 public function action_update_check()
 {
     Update::add('RecentComments', '6d49a362-db63-11dc-95ff-0800200c9a66', $this->info->version);
 }
 /**
  * Add update beacon support
  **/
 public function action_update_check()
 {
     Update::add('Brightkite', '263F0954-4B2B-11DE-B433-958C55D89593', $this->info->version);
 }
Example #28
0
 public function action_update_check()
 {
     Update::add($this->info->name, 'e283ba9d-d16d-4932-b9dd-0117e84a3ba8', $this->info->version);
 }
 /**
  * Add update beacon support
  */
 public function action_update_check()
 {
     Update::add('Notify All', '7445fa2e-badc-4b6a-8098-4f3b85563ffb', $this->info->version);
 }
 public function action_update_check()
 {
     Update::add($this->info->name, '8d5a4403-33a5-430e-8674-ae4a1b1a09d3', $this->info->version);
 }