Changeset 16815

Show
Ignore:
Timestamp:
07/08/08 15:46:44 (5 months ago)
Author:
rambo
Message:

scripted whitespace normalization

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/midcom/midcom.core/midcom/services/auth.php

    r16607 r16815  
    717717     */ 
    718718    function can_do($privilege, &$content_object, $user = null) 
    719     {   
     719    {     
    720720        if (   $privilege != 'midgard:read' 
    721721            && $_MIDGARD['sitegroup'] != 0 
     
    723723        { 
    724724            return false; 
    725         }       
     725        }     
    726726        return $this->can_do_byguid($privilege, $content_object->guid, get_class($content_object), $user); 
    727727    } 
  • trunk/midcom/midcom.helper.search/viewer.php

    r16112 r16815  
    316316            $data['shown_documents'] = $last_document_id - $first_document_id + 1; 
    317317            $data['results_per_page'] = $results_per_page; 
    318            $data['all_results'] =& $result; 
     318        $data['all_results'] =& $result; 
    319319            $data['result'] = array_slice($result, $first_document_id, $results_per_page); 
    320320            // Register GUIDs for cache engine 
  • trunk/midcom/midcom.helper.xsspreventer/main.php

    r16079 r16815  
    3939        return preg_replace_callback 
    4040        ( 
    41                "%(<\s*)+(/\s*)+{$element}%i",  
     41            "%(<\s*)+(/\s*)+{$element}%i",  
    4242            create_function 
    4343            ( 
    44                '$matches', 
    45                'return htmlentities($matches[0]);' 
     44                '$matches', 
     45                'return htmlentities($matches[0]);' 
    4646            ), 
    4747            $input 
  • trunk/midcom/midgard.admin.asgard/navigation.php

    r16301 r16815  
    1 <?php 
     1<?php 
    22/** 
    33 * @package midgard.admin.asgard 
  • trunk/midcom/org.openpsa.invoices/style/show-list-item.php

    r16722 r16815  
    3939    { 
    4040        if ($_MIDCOM->auth->can_do('midgard:update', $data['invoice']) 
    41            && isset($data['next_marker'])) 
     41        && isset($data['next_marker'])) 
    4242        { 
    4343            $next_marker_url = $prefix . "invoice/mark_" . $data['next_marker'] . "/" . $data['invoice']->guid . ".html"; 
  • trunk/midcom/org.routamc.positioning/lib/fireeagle.php

    r16642 r16815  
    7474 
    7575  function __construct($consumerKey, 
    76                       $consumerSecret,  
    77                       $oAuthToken = null,  
    78                       $oAuthTokenSecret = null)  { 
     76               $consumerSecret,  
     77               $oAuthToken = null,  
     78               $oAuthTokenSecret = null)  { 
    7979    $this->sha1_method = new OAuthSignatureMethod_HMAC_SHA1(); 
    8080    $this->consumer = new OAuthConsumer($consumerKey, $consumerSecret, NULL); 
     
    152152      $r->user->best_guess = NULL; 
    153153      foreach ($r->user->location_hierarchy as &$loc) { 
    154        $c = $loc->geometry->coordinates; 
    155        switch ($loc->geometry->type) { 
    156        case 'Box': // DEPRECATED 
    157          $loc->bbox = $c; 
    158          $loc->longitude = ($c[0][0] + $c[1][0]) / 2; 
    159          $loc->latitude = ($c[0][1] + $c[1][1]) / 2; 
    160          $loc->geotype = 'box'; 
    161          break; 
    162        case 'Polygon': 
    163          $loc->bbox = $bbox = $loc->geometry->bbox; 
    164          $loc->longitude = ($bbox[0][0] + $bbox[1][0]) / 2; 
    165          $loc->latitude = ($bbox[0][1] + $bbox[1][1]) / 2; 
    166          $loc->geotype = 'box'; 
    167          break; 
    168        case 'Point': 
    169          list($loc->longitude, $loc->latitude) = $c; 
    170          $loc->geotype = 'point'; 
    171          break; 
    172        
    173        if ($loc->best_guess) $r->user->best_guess = $loc; // add shortcut to get 'best guess' loc 
    174        unset($loc); 
     154    $c = $loc->geometry->coordinates; 
     155    switch ($loc->geometry->type) { 
     156    case 'Box': // DEPRECATED 
     157      $loc->bbox = $c; 
     158      $loc->longitude = ($c[0][0] + $c[1][0]) / 2; 
     159      $loc->latitude = ($c[0][1] + $c[1][1]) / 2; 
     160      $loc->geotype = 'box'; 
     161      break; 
     162    case 'Polygon': 
     163      $loc->bbox = $bbox = $loc->geometry->bbox; 
     164      $loc->longitude = ($bbox[0][0] + $bbox[1][0]) / 2; 
     165      $loc->latitude = ($bbox[0][1] + $bbox[1][1]) / 2; 
     166      $loc->geotype = 'box'; 
     167      break; 
     168    case 'Point': 
     169      list($loc->longitude, $loc->latitude) = $c; 
     170      $loc->geotype = 'point'; 
     171      break; 
     172   
     173    if ($loc->best_guess) $r->user->best_guess = $loc; // add shortcut to get 'best guess' loc 
     174    unset($loc); 
    175175      } 
    176176    } 
     
    254254      $url_bits = parse_url($url); 
    255255      if (isset($postData)) { 
    256        self::dump("POST ".$url_bits['path']." HTTP/1.0\nHost: ".$url_bits['host']."\nContent-Type: application/x-www-urlencoded\nContent-Length: ".strlen($postData)."\n\n$postData\n"); 
     256    self::dump("POST ".$url_bits['path']." HTTP/1.0\nHost: ".$url_bits['host']."\nContent-Type: application/x-www-urlencoded\nContent-Length: ".strlen($postData)."\n\n$postData\n"); 
    257257      } else { 
    258        $get_url = $url_bits['path']; 
    259        if ($url_bits['query']) $get_url .= '?' . $url_bits['query']; 
    260        self::dump("GET $get_url HTTP/1.0\nHost: ".$url_bits['host']."\n\n"); 
     258    $get_url = $url_bits['path']; 
     259    if ($url_bits['query']) $get_url .= '?' . $url_bits['query']; 
     260    self::dump("GET $get_url HTTP/1.0\nHost: ".$url_bits['host']."\n\n"); 
    261261      } 
    262262    }