In general, there is an IPB forum. If you go to the sections of the forums, the forum is displayed, but with an error:
Warning: Invalid argument supplied for foreach() in /home/p50193/www/play-mp3.ru/public/style_images/engraved/_php/IPBForumSkins.php on line 36 Warning: Invalid argument supplied for foreach() in /home/p50193/www/play-mp3.ru/public/style_images/engraved/_php/IPBForumSkins.php on line 41 Here is the IPBForumSkins.php file:
<?php class IPBForumSkins{ static public $_instance; static public function init(){ if(self::$_instance == null) self::$_instance = new IPBForumSkins_Functions(ipsRegistry::instance()); return self::$_instance; } } class IPBForumSkins_Functions{ protected $registry; protected $DB; protected $settings; protected $request; protected $lang; protected $member; protected $memberData; protected $cache; protected $caches; public $topic_data; public function __construct(ipsRegistry $registry){ $this->registry = $registry; $this->DB = $this->registry->DB(); $this->settings =& $this->registry->fetchSettings(); $this->request =& $this->registry->fetchRequest(); $this->lang = $this->registry->getClass('class_localization'); $this->member = $this->registry->member(); $this->memberData =& $this->registry->member()->fetchMemberData(); $this->cache = $this->registry->cache(); $this->caches =& $this->registry->cache()->fetchCaches(); } public function loadAvatars( &$topic_data ){ $members = array(); $members_ids = array(); foreach( $topic_data as $tid => $data ) $members_ids[ $data['starter_id'] ] = $data['starter_id']; $members = IPSMember::load( array_keys( $members_ids ), 'core,extendedProfile' ); foreach($members as $member ) $members_avatars[ $member['member_id'] ] = IPSMember::buildAvatar( $member ); foreach( $topic_data as $tid => $data ) $topic_data[ $tid ]['starter_avatar'] = $members_avatars[ $data['starter_id'] ]; return $topic_data; } } ?> Because I have a bottom in PHP, I ask for help from you, dear professionals.