226. File Comparison Report

Produced on Mon May 12 13:05:17 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.

226.1 Files compared

# Location File Last Modified
1 Dolphin-v.6.0.5\inc articles.inc.php Thu Sep 20 08:58:34 2007 UTC
2 Mon May 12 13:05:17 2008 UTC

226.2 Comparison summary

Description Between
Files 1 and 2
Text Blocks Lines
Unchanged 0 0
Changed 0 0
Inserted 0 0
Removed 1 321

226.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

226.4 Active regular expressions

No regular expressions were active.

226.5 Comparison detail

1   <?    
2      
3   /********* ********** ********** ********** ********** ********** ********** ******    
4   *                              D olphin Sma rt Communi ty Builder    
5   *                                 --------- --------    
6   *     begi n                 : M on Mar 23  2006    
7   *     copy right             : ( C) 2006 Bo onEx Group    
8   *     webs ite               : h ttp://www. boonex.com /    
9   * This fil e is part  of Dolphin  - Smart C ommunity B uilder    
10   *    
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/    
13   *    
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.    
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    
18   * see lice nse.txt fi le; if not , write to  marketing @boonex.co m    
19   ********** ********** ********** ********** ********** ********** ********** *****/    
20      
21   if ( !( $l ogged['adm in'] = mem ber_auth(  1, false )  ) )    
22   {    
23       if ( ! ( $logged[ 'member']  = member_a uth( 0, fa lse ) ) )    
24       {    
25           if  ( !( $log ged['aff']  = member_ auth( 2, f alse )) )    
26           {    
27                $logged[ 'moderator '] = membe r_auth( 3,  false );    
28           }    
29       }    
30   }    
31      
32      
33      
34      
35   if( $logge d['admin']  )    
36   {    
37       $sUrl  = $site['u rl_admin'] ;    
38   }    
39   else    
40   {    
41       $sUrl  = $site['u rl'];    
42   }    
43      
44      
45      
46      
47      
48   function g etArticles Categiries List( $res urs = fals e )    
49   {    
50       global  $site;    
51       global  $logged;    
52       global  $sUrl;    
53      
54       $sCate gQuery = "    
55                SELECT    
56                         `CategoryI D`,    
57                         `CategoryN ame`,    
58                         `CategoryD escription `    
59                FROM    
60                         `ArticlesC ategory`    
61                ORDER BY  `Category ID` ASC    
62       ";    
63       $rCate gory = db_ res( $sCat egQuery );    
64      
65       if( $r esurs )    
66       {    
67           re turn $rCat egory;    
68       }    
69       else    
70       {    
71      
72           $r et = '';    
73           // $ret .= pr int_r($log ged, true)  . '<hr>';    
74           // $ret .= pr int_r($sit e, true) .  "\n";    
75      
76           if ( $logged[ 'admin'] )    
77           {    
78                $ret .=  '<div clas s="addLink ">' . "\n" ;    
79                    $ret  .= '<a hr ef="' . $s ite['url_a dmin'] . ' articles.p hp?action= addcategor y">' . "\n ";    
80                         $ret .= 'A dd New Cat egory' . " \n";    
81                    $ret  .= '</a>'  . "\n||";    
82                    $ret  .= '<a hr ef="' . $s ite['url_a dmin'] . ' articles.p hp?action= addarticle ">' . "\n" ;    
83                         $ret .= 'A dd New Art icle' . "\ n";    
84                    $ret  .= '</a>'  . "\n";    
85                $ret .=  '</div>' .  "\n";    
86           }    
87               
88           $i  = '';    
89           wh ile ($aCat egory = my sql_fetch_ assoc( $rC ategory ))    
90           {    
91                if ( ($i %2) == 0 )    
92                {    
93                    $sSt yleAdd = ' 1';    
94                }    
95                else    
96                {    
97                    $sSt yleAdd = ' 2';    
98                }    
99      
100      
101                $ret .=  '<div clas s="categor yBlock' .  $sStyleAdd  . '">' .  "\n";    
102                    $ret  .= '<div  class="cat egoryCapti on">' . "\ n";    
103                         $ret .= '< a href="'  . $sUrl .  'articles. php?catID= ' . $aCate gory['Cate goryID'] .  '&amp;act ion=viewca tegory">'  . "\n";    
104                             $ret . = process_ line_outpu t( $aCateg ory['Categ oryName']  ) . "\n";    
105                         $ret .= '< /a>' . "\n ";    
106      
107                    $ret  .= '</div >' . "\n";    
108                    $ret  .= '<div  class="cle ar_both">< /div>' . " \n";    
109                        
110                    $ret  .= '<div  class="cle ar_both">< /div>' . " \n";    
111                    $ret  .= '<div  class="cat egoryDescr iption">'  . "\n";    
112                         $ret .= pr ocess_html _output( $ aCategory[ 'CategoryD escription '] ) . "\n ";    
113                    $ret  .= '</div >' . "\n";    
114                        
115                         if( $logge d['admin']  )    
116                         {    
117                             $ret . = '<div cl ass="categ oryEdit">< a href="'  . $sUrl .  'articles. php?catID= ' . $aCate gory['Cate goryID'] .  '&amp;act ion=catego ryedit">Ed it</a>' .  "\n||";    
118                             $ret . = '<a href ="' . $sUr l . 'artic les.php?ca tID=' . $a Category[' CategoryID '] . '&amp ;action=ca tegorydele te" onclic k="javascr ipt: retur n confirm( \'Do you r ealy want  to delete  \n categor y ' . $aCa tegory['Ca tegoryName '] . ' \n  and all it s articles  \')">Dele te</a></di v>' . "\n" ;    
119                         }    
120      
121                $ret .=  '</div>' .  "\n";    
122      
123                $i++;    
124           }    
125      
126           re turn $ret;    
127       }    
128      
129   }    
130      
131   function g etArticles List( $iCa tegoryID )    
132   {    
133       global  $sUrl;    
134       global  $site;    
135       global  $logged;    
136       global  $short_da te_format;    
137      
138       $iCate goryID = ( int)$iCate goryID;    
139       if( !( int)$iCate goryID )    
140       {    
141           re turn '';    
142       }    
143       else    
144       {    
145           $s CategoryQu ery = "    
146                    SELE CT    
147                             `Categ oryName`,    
148                             `Categ oryDescrip tion`    
149                    FROM    
150                             `Artic lesCategor y`    
151                    WHER E    
152                             `Categ oryID` = ' $iCategory ID'    
153                    LIMI T 1;    
154           ";    
155           $a Category =  db_arr( $ sCategoryQ uery );    
156       }    
157      
158       $sArti clesQuery  = "    
159                    SELE CT    
160                             `Title `,    
161                             `Text` ,    
162                             DATE_F ORMAT( `Da te`, '$sho rt_date_fo rmat' ) AS  Date,    
163                             `Artic lesID`,    
164                             `Artic leFlag`    
165                    FROM    
166                             `Artic les`    
167                    WHER E    
168                             `Categ oryID` = ' $iCategory ID'    
169       ";    
170       $rArti cles = db_ res( $sArt iclesQuery  );    
171      
172      
173       $ret =  '';    
174       $ret . = '<div cl ass="navig ationLinks ">' . "\n" ;    
175           $r et .= '<sp an>' . "\n ";    
176                $ret .=  '<a href=" ' . $sUrl  . 'article s.php">' .  "\n";    
177                    $ret  .= 'Artic les' . "\n ";    
178                $ret .=  '</a>' . " \n";    
179           $r et .= '</s pan>' . "\ n";    
180           $r et .= '<sp an>' . "\n ";    
181                $ret .=  '&gt;' . " \n";    
182           $r et .= '</s pan>' . "\ n";    
183           $r et .= '<sp an>' . "\n ";    
184                $ret .=  process_li ne_output(  $aCategor y['Categor yName'] )  . "\n";    
185           $r et .= '</s pan>' . "\ n";    
186       $ret . = '</div>'  . "\n";    
187       $ret . = '<div cl ass="categ oryHeader" >' . "\n";    
188           $r et .= '<di v class="a rtCaption" >' . "\n";    
189                $ret .=  process_li ne_output(  $aCategor y['Categor yName'] )  . "\n";    
190           $r et .= '</d iv>' . "\n ";    
191           $r et .= '<di v>' . "\n" ;    
192                $ret .=  process_te xt_output(  $aCategor y['Categor yDescripti on'] ) . " \n";    
193           $r et .= '</d iv>' . "\n ";    
194       $ret . = '</div>'  . "\n";    
195      
196       $i = ' ';    
197       while  ( $aArticl es = mysql _fetch_ass oc( $rArti cles ))    
198       {    
199           if  ( ($i%2)  == 0 )    
200           {    
201                $sStyleA dd = '1';    
202           }    
203           el se    
204           {    
205                $sStyleA dd = '2';    
206           }    
207      
208           $r et .= '<di v class="a rticleBloc k' . $sSty leAdd . '" >' . "\n";    
209                $ret .=  '<div clas s="title"> ' . "\n";    
210                    $ret  .= '<a hr ef="' . $s Url . 'art icles.php? articleID= ' . $aArti cles['Arti clesID'] .  '&amp;act ion=viewar ticle">' .  "\n";    
211                         $ret .= pr ocess_line _output( $ aArticles[ 'Title'] )  . "\n";    
212                    $ret  .= '</a>'  . "\n";    
213                $ret .=  '</div>' .  "\n";    
214                $ret .=  '<div clas s="date">'  . "\n";    
215                    $ret  .= $aArti cles['Date '] . "\n";    
216                $ret .=  '</div>' .  "\n";    
217                $ret .=  '<div clas s="preview ">' . "\n" ;    
218                    if(  $aArticles ['ArticleF lag'] == ' HTML' )    
219                    {    
220                         $ret .= pr ocess_html _output( s trmaxtextl en( strip_ tags($aArt icles['Tex t']), 200  ) ) . "\n" ;    
221                    }    
222                    else    
223                    {    
224                         $ret .= pr ocess_text _output( s trmaxtextl en( $aArti cles['Text '], 200 )  ) . "\n";    
225                    }    
226                $ret .=  '</div>' .  "\n";    
227                if( $log ged['admin '] )    
228                {    
229                    $ret  .= '<div  class="cat egoryEdit" >' . "\n";    
230                         $ret .= '< a href="'  . $site['u rl_admin']  . 'articl es.php?art icleID=' .  $aArticle s['Article sID'] . '& amp;action =editartic le">' . "\ n";    
231                             $ret . = 'Edit' .  "\n";    
232                         $ret .= '< /a>' . "\n ||";    
233                         $ret .= '< a href="'  . $site['u rl_admin']  . 'articl es.php?art icleID=' .  $aArticle s['Article sID'] . '& amp;action =deleteart icle" oncl ick="javas cript: ret urn confir m(\' Are y ou sure ?\ ')">' . "\ n";    
234                             $ret . = 'Delete'  . "\n";    
235                         $ret .= '< /a>' . "\n ";    
236                    $ret  .= '</div >' . "\n";    
237                }    
238           $r et .= '</d iv>' . "\n ";    
239           $i ++;    
240       }    
241      
242      
243       return  $ret;    
244   }    
245      
246   function g etArticle(  $iArticle ID )    
247   {    
248       global  $short_da te_format;    
249      
250       if( !( int)$iArti cleID )    
251       {    
252           re turn '';    
253       }    
254       else    
255       {    
256           $s ArticleQue ry = "    
257                    SELE CT    
258                             `Title `,    
259                             `Text` ,    
260                             `Artic les`.`Cate goryID`,    
261                             DATE_F ORMAT( `Da te`, '$sho rt_date_fo rmat' ) AS  Date,    
262                             `Artic lesID`,    
263                             `Categ oryName`,    
264                             `Artic leFlag`    
265                    FROM    
266                             `Artic les`    
267                    INNE R JOIN `Ar ticlesCate gory` ON ` Articles`. `CategoryI D` = `Arti clesCatego ry`.`Categ oryID`    
268                    WHER E    
269                             `Artic lesID` = ' $iArticleI D'    
270                    LIMI T 1;    
271      
272           ";    
273       }    
274       $aArti cle = db_a rr( $sArti cleQuery ) ;    
275      
276       $ret =  '';    
277       $ret . = '<div cl ass="navig ationLinks ">' . "\n" ;    
278           $r et .= '<sp an>' . "\n ";    
279                $ret .=  '<a href=" articles.p hp">' . "\ n";    
280                    $ret  .= 'Artic les' . "\n ";    
281                $ret .=  '</a>' . " \n";    
282           $r et .= '</s pan>' . "\ n";    
283           $r et .= '<sp an>' . "\n ";    
284                $ret .=  '&gt;' . " \n";    
285           $r et .= '</s pan>' . "\ n";    
286           $r et .= '<sp an>' . "\n ";    
287                $ret .=  '<a href=" articles.p hp?catID='  . $aArtic le['Catego ryID'] . ' &amp;actio n=viewcate gory">' .  "\n";    
288                    $ret  .= proces s_line_out put( $aArt icle['Cate goryName']  ) . "\n";    
289                $ret .=  '</a>' . " \n";    
290           $r et .= '</s pan>' . "\ n";    
291           $r et .= '<sp an>' . "\n ";    
292                $ret .=  '&gt;' . " \n";    
293           $r et .= '</s pan>' . "\ n";    
294           $r et .= '<sp an>' . "\n ";    
295                $ret .=  process_li ne_output(  $aArticle ['Title'])  . "\n";    
296           $r et .= '</s pan>' . "\ n";    
297       $ret . = '</div>'  . "\n";    
298       $ret . = '<div cl ass="artic leBlock">'  . "\n";    
299           $r et .= '<di v class="m ainTitle"> ' . "\n";    
300                $ret .=  process_li ne_output(  $aArticle ['Title']  ) . "\n";    
301           $r et .= '</d iv>' . "\n ";    
302           $r et .= '<di v class="d ate">' . " \n";    
303                $ret .=  $aArticle[ 'Date'] .  "\n";    
304           $r et .= '</d iv>' . "\n ";    
305           $r et .= '<di v>' . "\n" ;    
306                if( $aAr ticle['Art icleFlag']  == 'HTML'  )    
307                {    
308                    $ret  .= proces s_html_out put( $aArt icle['Text '] ) . "\n ";    
309                }    
310                else    
311                {    
312                    $ret  .= proces s_text_out put( $aArt icle['Text '] ) . "\n ";    
313                }    
314           $r et .= '</d iv>' . "\n ";    
315       $ret . = '</div>'  . "\n";    
316      
317       return  $ret;    
318   }    
319      
320      
321   ?>