760. File Comparison Report

Produced on Mon May 12 13:07:02 2008 UTC. This report uses XHTML and CSS2, and is best viewed with a reasonably standards compliant browser such as the latest version of Firefox or Internet Explorer. For optimum results when printing this report, use landscape orientation and enable printing of background images and colours in your browser.

760.1 Files compared

# Location File Last Modified
1 Dolphin-v.6.0.5 browsePhoto.php Thu Sep 20 09:00:22 2007 UTC
2 Dolphin-v.6.1.0 browsePhoto.php Mon Apr 14 11:47:24 2008 UTC

760.2 Comparison summary

Description Between
Files 1 and 2
Text Blocks Lines
Unchanged 16 92
Changed 10 150
Inserted 2 3
Removed 3 28

760.3 Comparison options

Whitespace
Character case Differences in character case are significant
Line endings Differences in line endings (CR and LF characters) are ignored
CR/LF characters Not shown in the comparison detail

760.4 Active regular expressions

No regular expressions were active.

760.5 Comparison detail

1   <?php   1   <?php
2     2  
3   /********* ********** ********** ********** ********** ********** ********** ******   3   /********* ********** ********** ********** ********** ********** ********** ******
4   *                              D olphin Sma rt Communi ty Builder   4   *                              D olphin Sma rt Communi ty Builder
5   *                                 --------- --------   5   *                                 --------- --------
6   *     begi n                 : M on Mar 23  2006   6   *     begi n                 : M on Mar 23  2006
7   *     copy right             : ( C) 2006 Bo onEx Group   7   *     copy right             : ( C) 2006 Bo onEx Group
8   *     webs ite               : h ttp://www. boonex.com /   8   *     webs ite               : h ttp://www. boonex.com /
9   * This fil e is part  of Dolphin  - Smart C ommunity B uilder   9   * This fil e is part  of Dolphin  - Smart C ommunity B uilder
10   *   10   *
11   * Dolphin  is free so ftware. Th is work is  licensed  under a Cr eative Com mons Attri bution 3.0  License.    11   * Dolphin  is free so ftware. Th is work is  licensed  under a Cr eative Com mons Attri bution 3.0  License. 
12   * http://c reativecom mons.org/l icenses/by /3.0/   12   * http://c reativecom mons.org/l icenses/by /3.0/
13   *   13   *
14   * Dolphin  is distrib uted in th e hope tha t it will  be useful,  but WITHO UT ANY WAR RANTY;   14   * Dolphin  is distrib uted in th e hope tha t it will  be useful,  but WITHO UT ANY WAR RANTY;
15   * without  even the i mplied war ranty of   MERCHANTAB ILITY or F ITNESS FOR  A PARTICU LAR PURPOS E.   15   * without  even the i mplied war ranty of   MERCHANTAB ILITY or F ITNESS FOR  A PARTICU LAR PURPOS E.
16   * See the  Creative C ommons Att ribution 3 .0 License  for more  details.    16   * See the  Creative C ommons Att ribution 3 .0 License  for more  details. 
17   * You shou ld have re ceived a c opy of the  Creative  Commons At tribution  3.0 Licens e along wi th Dolphin   17   * You shou ld have re ceived a c opy of the  Creative  Commons At tribution  3.0 Licens e along wi th Dolphin
18   * see lice nse.txt fi le; if not , write to  marketing @boonex.co m   18   * see lice nse.txt fi le; if not , write to  marketing @boonex.co m
19   ********** ********** ********** ********** ********** ********** ********** *****/   19   ********** ********** ********** ********** ********** ********** ********** *****/
20     20  
21   require_on ce('inc/he ader.inc.p hp');   21   require_on ce('inc/he ader.inc.p hp');
22   require_on ce( BX_DIR ECTORY_PAT H_INC . 'd esign.inc. php' );    
23   require_on ce( BX_DIR ECTORY_PAT H_INC . 'a dmin.inc.p hp' );    
24   require_on ce( BX_DIR ECTORY_PAT H_INC . 'i mages.inc. php' );    
25   require_on ce( BX_DIR ECTORY_PAT H_INC . 's haring.inc .php' );   22   require_on ce(BX_DIRE CTORY_PATH _INC . 'sh aring.inc. php');
    23   require_on ce(BX_DIRE CTORY_PATH _CLASSES .  'BxDolSha redMedia.p hp');
26     24  
27   $_page['na me_index']     = 82;   25   check_logg ed();
28   $_page['cs s_name']       = 'vie wPhoto.css ';    
29     26  
30   $oVotingVi ew = new B xTemplVoti ngView('gp hoto', 0,  0);   27   $member['I D'] = (int )$_COOKIE[ 'memberID' ];
31   $_page['ex tra_js']   = $oVoting View->getE xtraJs();    
32     28  
33   if ( !( $l ogged['adm in'] = mem ber_auth(  1, false )  ) )   29   $oNew = ne w BxDolSha redMedia(' photo', $s ite, $dir,  $member);
34   {    
35       if ( ! ( $logged[ 'member']  = member_a uth( 0, fa lse ) ) )    
36       {    
37           if  ( !( $log ged['aff']  = member_ auth( 2, f alse ) ) )    
38           {    
39                $logged[ 'moderator '] = membe r_auth( 3,  false );    
40           }    
41       }    
42   }    
43     30  
    31   $_page['na me_index']  = 82;
    32   $_page['cs s_name'] =  $oNew->sC ssName;
44     33  
45   $_page['he ader'] = _ t( "_brows ePhoto" );   34   $_page['he ader'] = _ t( "_brows ePhoto" );
46   $_page['he ader_text' ] = _t("_b rowsePhoto ");   35   $_page['he ader_text' ] = _t("_b rowsePhoto ");
47     36  
48   $_ni = $_p age['name_ index'];   37   $_ni = $_p age['name_ index'];
49     38  
50   $member['I D'] = (int )$_COOKIE[ 'memberID' ];   39   $aConditio n  = $oNew ->getCondi tionArray( $logged);
51     40   if ($aCond ition !==  false) {
52   $aWhere =  array();   41       $aSqlQ uery   = $ aCondition ['query'];
53   $aWhere[]  = '1';   42       $iTota lPages = $ aCondition ['total'];
54     43       $iCurP age    = $ aCondition ['cur_page '];
55   if (isset( $_GET['use rID']))   44       $iPerP age    = $ aCondition ['per_page '];
56   {    
57       $iUser  = (int)$_ GET['userI D'];    
58       $aWher e[] = "`sh arePhotoFi les`.`medP rofId`=$iU ser";       
59   }    
60      
61   if (isset( $_GET['tag ']))    
62   {    
63       $sTag  = htmlspec ialchars_a dv($_GET[' tag']);    
64       $aWher e[] = "`sh arePhotoFi les`.`medT ags` like  '%$sTag%'" ;    
65   }    
66      
67   if (isset( $_GET['act ion']))    
68   {    
69       $sAct  = htmlspec ialchars_a dv($_GET[' action']);    
70       $sAddo n = define BrowseActi on($sAct,' Photo',$me mber['ID'] );    
71   }   45   }
72     46   else {
73   $sqlWhere  = "WHERE "  . implode ( ' AND ',  $aWhere ) .$sAddon."  AND `Appr oved`= 'tr ue'";    
74      
75   $iTotalNum  = db_valu e( "SELECT  COUNT( *  ) FROM `sh arePhotoFi les` $sqlW here" );    
76   if( !$iTot alNum )    
77   {    
78       $_page _cont[$_ni ]['page_ma in_code']  = _t( '_So rry, nothi ng found'  );   47       $_page _cont[$_ni ]['page_ma in_code']  = _t( '_So rry, nothi ng found'  );
79      
80       PageCo de();   48       PageCo de();
81       exit;   49       exit;
82   }   50   }
83     51  
84   $iPerPage  = (int)$_G ET['per_pa ge'];   52   $rData = $ oNew->getF ilesList($ aSqlQuery) ;
85   if( !$iPer Page )    
86       $iPerP age = 10;    
87      
88   $iTotalPag es = ceil(  $iTotalNu m / $iPerP age );    
89      
90   $iCurPage  = (int)$_G ET['page'] ;    
91      
92   if( $iCurP age > $iTo talPages )    
93       $iCurP age = $iTo talPages;    
94      
95   if( $iCurP age < 1 )    
96       $iCurP age = 1;    
97      
98   $sLimitFro m = ( $iCu rPage - 1  ) * $iPerP age;    
99      
100   $sqlOrderB y = 'ORDER  BY `medDa te` DESC';    
101      
102   if (isset( $_GET['rat e']))    
103   {    
104       $oVoti ngView = n ew BxTempl VotingView  ('gphoto' , 0, 0);    
105           
106       $aSql         = $ oVotingVie w->getSqlP arts('`sha rePhotoFil es`', '`me dID`');    
107       $sHow         = $ _GET['rate '] == 'top ' ? "DESC"  : "ASC";    
108       $sqlOr derBy  = $ oVotingVie w->isEnabl ed() ? "OR DER BY `vo ting_rate`  $sHow, `v oting_coun t` $sHow,  `medDate`  $sHow" : $ sqlOrderBy  ;    
109       $sqlFi elds   = $ aSql['fiel ds'];    
110       $sqlLJ oin    = $ aSql['join '];    
111   }       
112   $sqlLimit  = "LIMIT $ sLimitFrom , $iPerPag e";    
113      
114   $sQuery =  "    
115       SELECT    
116           `s harePhotoF iles`.`med ID`,    
117           `s harePhotoF iles`.`med ProfId`,    
118           `s harePhotoF iles`.`med Title`,    
119           UN IX_TIMESTA MP(`shareP hotoFiles` .`medDate` ) as `medD ate`,    
120           `s harePhotoF iles`.`med Views`,    
121           `s harePhotoF iles`.`med Ext`,    
122           `P rofiles`.` NickName`    
123           $s qlFields    
124       FROM ` sharePhoto Files`    
125       LEFT J OIN `Profi les` ON    
126           `P rofiles`.` ID` = `sha rePhotoFil es`.`medPr ofId`    
127       $sqlLJ oin    
128       $sqlWh ere    
129       $sqlOr derBy    
130       $sqlLi mit    
131       ";    
132      
133   $rData = d b_res($sQu ery);    
134      
135   $_page_con t[$_ni]['p age_main_c ode'] = Pa geCompPage MainCode() ;    
136      
137   PageCode() ;    
138      
139   function P ageCompPag eMainCode( )    
140   {    
141       global  $site;    
142       global  $rData;    
143       global  $iTotalPa ges;    
144       global  $iCurPage ;    
145       global  $iPerPage ;    
146       global  $member;    
147           
148       $sCode  = '<div s tyle="posi tion: rela tive; floa t: left;"> ';    
149     53  
150       
i f   (
mysql_ num _ row s
($rData))
  54   wh i le   ( $aData   =   mysql_ fetch _ a s soc ($rData))
151       {   55       $sCode  .= $oNew- >showBrows eUnit($aDa ta);
152           wh ile ($aDat a = mysql_ fetch_arra y($rData))    
153           {    
154                $sImage  = $site['s haringImag es'].$aDat a['medID'] .'_t.'.$aD ata['medEx t'];    
155                $sProfLi nk = '<div >'._t("_By ").': <a h ref="'.get ProfileLin k($aData[' medProfId' ]).'">'.$a Data['Nick Name'].'</ a></div>';    
156                   56  
157                $oVoting View = new  BxTemplVo tingView ( 'gphoto',  $aData['me dID']);    
158                if( $oVo tingView-> isEnabled( ))    
159                {    
160                    $sRa te = $oVot ingView->g etSmallVot ing (0);    
161                    $sSh owRate = ' <div class ="galleryR ate">'. $s Rate . '</ div>';    
162                }    
163                $sHref =  $site['ur l'].'viewP hoto.php?f ileID='.$a Data['medI D'];    
164                $sImg  =  '<div cla ss="lastFi lesPic" st yle="backg round-imag e: url(\'' .$sImage.' \');">    
165                           <a href= "'.$sHref. '"><img sr c="'.$site ['images']  .'spacer. gif" width ="110" hei ght="110"> </a></div> ';    
166                    
167                $sPicTit le = strle n($aData[' medTitle'] ) > 0 ? $a Data['medT itle'] : _ t("_Untitl ed");    
168                $sDelLin k = $membe r['ID'] ==  $aData['m edProfId']  ? '<div>< a href="'. $_SERVER[' PHP_SELF'] .'?action= del&fileID ='.$aData[ 'medID'].' "    
169                onClick= "return co nfirm( \'' ._t("_are  you sure?" ).'\');">' ._t("_Dele te").'</a> </div>'  :  "" ;    
170                $sCode . = '<div cl ass="brows eUnit">';    
171                    $sCo de .= $sIm g;    
172                    $sCo de .= '<di v><a href= "'.$sHref. '"><b>'.$s PicTitle.' </b></a></ div>';    
173                    $sCo de .= $sPr ofLink;    
174                    $sCo de .= '<di v>'._t("_A dded").':  <b>'.defin eTimeInter val($aData ['medDate' ]).'</b></ div>';    
175                    $sCo de .= '<di v>'._t("_V iews").':  <b>'.$aDat a['medView s'].'</b>< /div>';    
176                    $sCo de .= $sSh owRate;    
177                    $sCo de .= $sDe lLink;    
178                $sCode . = '</div>'    
179           }    
180       }    
181       $sCode  .= '<div  class="cle ar_both">< /div>';   57   $sCode .=  '<div clas s="clear_b oth"></div >';
182          58  
183       // gen erate pagi nation   59   $sCode .=  $oNew->sho wPaginatio n($iTotalP ages, $iCu rPage, $iP erPage);
184       if( $i TotalPages  > 1)    
185       {    
186           $s Request =  $_SERVER[' PHP_SELF']  . '?';    
187           $a Fields = a rray( 'use rID', 'tag ', 'rate'  );    
188               
189           fo reach( $aF ields as $ field )    
190                if( isse t( $_GET[$ field] ) )    
191                    $sRe quest .= " &amp;{$fie ld}=" . ht mlentities ( process_ pass_data(  $_GET[$fi eld] ) );    
192              60  
193           $p agination  = '<div st yle="text- align: cen ter; posit ion: relat ive;">'._t ("_Results  per page" ).':   61   $_page_con t[$_ni]['p age_main_c ode'] = $s Code;
194                    <sel ect name=" per_page"  onchange=" window.loc ation=\''  . $sReques t . '&amp; per_page=\ ' + this.v alue;">    
195                         <option va lue="10"'  . ( $iPerP age == 10  ? ' select ed="select ed"' : ''  ) . '>10</ option>    
196                         <option va lue="20"'  . ( $iPerP age == 20  ? ' select ed="select ed"' : ''  ) . '>20</ option>    
197                         <option va lue="50"'  . ( $iPerP age == 50  ? ' select ed="select ed"' : ''  ) . '>50</ option>    
198                         <option va lue="100"'  . ( $iPer Page == 10 0 ? ' sele cted="sele cted"' : ' ' ) . '>10 0</option>    
199                    </se lect></div >' .    
200                genPagin ation( $iT otalPages,  $iCurPage , ( $sRequ est . '&am p;page={pa ge}&amp;pe r_page='.$ iPerPage )  );    
201       }    
202       else    
203           $p agination  = '';    
204          62  
205       return  $sCode .  $paginatio n.'</div>' ;   63   PageCode() ;
206   }    
207     64  
208   ?>   65   ?>