Changeset 6939


Ignore:
Timestamp:
May 16, 2008, 9:40:26 AM (17 years ago)
Author:
aramis
Message:
 
File:
1 edited

Legend:

Unmodified
Added
Removed
  • TabularUnified trunk/templates/base/scripts/BxBaseProfileView.php

    r6683 r6939  
    197197    function showBlockPhoto( $iCol, $bNoDB = false ) 
    198198    { 
     199        $iPID = 0; 
    199200        if( $iCol == 1 ) { 
    200201            $iPID = $this -> _iProfileID; 
     
    209210        } 
    210211 
    211         $oPhotos = new ProfilePhotos( $iPID ); 
    212         $oPhotos -> getActiveMediaArray(); 
    213  
    214         if( $this -> _aProfile['Couple'] && $iCol != 1 ) { 
    215             $aCoupleInfo = getProfileInfo($this->_aProfile['Couple']); 
    216             if ($aCoupleInfo['Picture']==0) { 
    217                 $oPhotos = new ProfilePhotos( $this->_aProfile['Couple'] ); 
    218                 $oPhotos -> getActiveMediaArray(); 
    219             } 
    220             $ret = $oPhotos -> getMediaBlock($aCoupleInfo['PrimPhoto'], true); 
    221         } else { 
    222             $ret = $oPhotos -> getMediaBlock(0); 
    223         } 
    224  
    225         if ($bNoDB) { 
    226             return DesignBoxContent( _t( '_PROFILE Photos', $sNickName ), $ret, 1 ); 
    227         } else { 
    228             echo DesignBoxContent( _t( '_PROFILE Photos', $sNickName ), $ret, 1 ); 
     212        if ($iPID > 0) { 
     213            $oPhotos = new ProfilePhotos( $iPID ); 
     214            $oPhotos -> getActiveMediaArray(); 
     215 
     216            if( $this -> _aProfile['Couple'] && $iCol != 1 ) { 
     217                $aCoupleInfo = getProfileInfo($this->_aProfile['Couple']); 
     218                if ($aCoupleInfo['Picture']==0) { 
     219                    $oPhotos = new ProfilePhotos( $this->_aProfile['Couple'] ); 
     220                    $oPhotos -> getActiveMediaArray(); 
     221                } 
     222                $ret = $oPhotos -> getMediaBlock($aCoupleInfo['PrimPhoto'], true); 
     223            } else { 
     224                $ret = $oPhotos -> getMediaBlock(0); 
     225            } 
     226 
     227            if ($bNoDB) { 
     228                return DesignBoxContent( _t( '_PROFILE Photos', $sNickName ), $ret, 1 ); 
     229            } else { 
     230                echo DesignBoxContent( _t( '_PROFILE Photos', $sNickName ), $ret, 1 ); 
     231            } 
    229232        } 
    230233    } 
Note: See TracChangeset for help on using the changeset viewer.
 
Below is the legacy version of the Boonex site, maintained for Dolphin.Pro 7.x support.
The new Dolphin solution is powered by UNA Community Management System.
Fork me on GitHub