WordPress.org

Plugin Directory

Changeset 648482


Ignore:
Timestamp:
01/06/13 00:40:11 (5 years ago)
Author:
imack
Message:

Tagging version 1.2.5

Location:
placeling/tags/1.2.5
Files:
6 edited
1 copied

Legend:

Unmodified
Added
Removed
  • placeling/tags/1.2.5/footer.php

    r538285 r648482  
    1616        $place_url = $WEB_HOSTNAME."/places/$pid"; 
    1717        $name = $place->name; 
    18          
    19         if ( isset($place->referring_perspectives) ){ 
     18        if ( isset( $place->referring_perspectives) ){ 
    2019            $found = false; 
    2120            $user_perspective; 
    22             foreach ($place->referring_perspectives as $perspective){ 
    23                 if ( $perspective->user->username == $username ){ 
    24                     $user_perspective = $perspective; 
    25                     $found = true; 
    26                 }    
     21 
     22            if ( count( $place->referring_perspectives ) == 1  && ( !isset( $username ) || $username == "") ){ 
     23                $username = $place->referring_perspectives[0]->user->username; 
     24            } else { 
     25                foreach ($place->referring_perspectives as $perspective){ 
     26                    if ( $perspective->user->username == $username ){ 
     27                        $user_perspective = $perspective; 
     28                        $found = true; 
     29                    } 
     30                } 
    2731            } 
    2832             
  • placeling/tags/1.2.5/index.php

    r538285 r648482  
    44Plugin URI: https://www.placeling.com 
    55Description: Placeling turns your blog into an iPhone- and map-based guide to the world. Simply use this plugin to tag your posts with a location and we'll convert each post into a point on a map at placeling.com. Your readers can use their iPhone to see nearby places you've recommended (and they'll be driven to your blog to read your post) or explore a web-based map of all your posts. 
    6 Version: 1.2.4 
     6Version: 1.2.5 
    77Author: Placeling (Internet Services) Inc. 
    88Author URI: https://www.placeling.com 
     
    4545            $postObj = get_post( $post_ID );  
    4646            $author_id = $postObj->post_author; 
    47             $username = get_user_meta( $author_id, '_placeling_username', true);     
     47            $username = get_site_option( '_placeling_username', false, true); 
    4848             
    4949            $place_json = rawurldecode( $meta_value ); 
     
    106106                 
    107107                $author_id = $GLOBALS['post']->post_author; 
    108                 $username = get_user_meta( $author_id, '_placeling_username', true); 
     108                $username = get_site_option( '_placeling_username', false, true); 
     109 
     110                // legacy case from pre-1.4 uses 
     111                if ( $username == "" && get_user_meta( $author_id, '_placeling_username', true) != "" ){ 
     112                    $username = get_user_meta( $author_id, '_placeling_username', true); 
     113                } 
    109114                 
    110115                wp_enqueue_style( 'footer', plugins_url( 'css/footer.css', __FILE__ ),false, "1.2" ); 
     
    188193            $current_user = wp_get_current_user(); 
    189194             
    190             $accessToken = get_user_meta($current_user->ID, '_placeling_access_token', true); 
    191             $secretToken = get_user_meta($current_user->ID, '_placeling_access_secret', true); 
     195            $accessToken = get_site_option('_placeling_access_token', false, true); 
     196            $secretToken = get_site_option('_placeling_access_secret', false, true); 
    192197     
    193198            $oauthObject = new OAuthSimple(); 
  • placeling/tags/1.2.5/popup/autocomplete.php

    r520727 r648482  
    88} 
    99 
    10 $fields_string .= "sensor=false&key=AIzaSyAjwCd4DzOM_sQsR7JyXMhA60vEfRXRT-Y"; 
     10$fields_string .= "sensor=false&radius=1000&key=AIzaSyAjwCd4DzOM_sQsR7JyXMhA60vEfRXRT-Y"; 
    1111//open connection 
    1212$ch = curl_init(); 
  • placeling/tags/1.2.5/popup/callback.php

    r532634 r648482  
    5555    // This will build a link to an RSS feed of the users calendars. 
    5656    $oauthObject->reset(); 
    57     update_user_meta( $current_user->ID, '_placeling_access_token', $access_token); 
    58     update_user_meta( $current_user->ID, '_placeling_access_secret', $access_token_secret); 
     57    update_site_option( '_placeling_access_token', $access_token); 
     58    update_site_option( '_placeling_access_secret', $access_token_secret); 
    5959     
    6060    header( 'Location:index.php' ) ;     
  • placeling/tags/1.2.5/popup/index.php

    r535801 r648482  
    1010    $current_user = wp_get_current_user(); 
    1111     
    12     $accessToken = get_user_meta($current_user->ID, '_placeling_access_token', true); 
    13     $secretToken = get_user_meta($current_user->ID, '_placeling_access_secret', true); 
     12    $accessToken = get_site_option('_placeling_access_token', false, true); 
     13    $secretToken = get_site_option('_placeling_access_secret', false, true); 
    1414     
    1515    $oauthObject = new OAuthSimple(); 
     
    5151        // Google will forward the request token, but not the secret. 
    5252        // Set a cookie, so the secret will be available once we return to this page. 
    53         update_user_meta( $current_user->ID, '_oauth_token_secret', $request_token_secret); 
     53        update_user_meta( $current_user->ID, '_oauth_token_secret', $request_token_secret); 
    5454        update_user_meta( $current_user->ID, '_oauth_token_secret_timeout', time()+3600); 
    5555        // 
     
    8787         
    8888        if ( $info['http_code'] == 401 ){ 
    89             delete_user_meta($current_user->ID, '_placeling_access_token'); 
    90             delete_user_meta($current_user->ID, '_placeling_access_secret'); 
     89            delete_site_option('_placeling_access_token'); 
     90            delete_site_option('_placeling_access_secret'); 
    9191            //die("no good access_key");     
    9292            header("Location:index.php"); 
     
    9999        $user = json_decode( $r ); 
    100100             
    101         $lat = $user->location[0]; 
    102         $lng = $user->location[1]; 
     101        $lat = $user->lat; 
     102        $lng = $user->lng; 
    103103         
    104104        $username = $user->username; 
    105         update_user_meta( $current_user->ID, '_placeling_username', $username ); 
     105        update_site_option( '_placeling_username', $username ); 
    106106         
    107107        $recent_perspectives = $user->perspectives; 
  • placeling/tags/1.2.5/readme.txt

    r538285 r648482  
    44Requires at least: 3.0 
    55Tested up to: 3.3.1 
    6 Stable tag: 1.2.4 
     6Stable tag: 1.2.5 
    77 
    88 
    9 Placeling turns your blog into a map-based, iPhone-enabled guide to your world. 
     9Placeling is the easiest way to put a map in your blog and turn blog posts into map pins. 
    1010 
    1111== Description == 
    1212 
    13 Placeling makes your blog a guide to your world. Each of your blog posts appears on a map plus and each pin on the map links back to that post. 
     13Placeling lets you put a map in your blog and turns your blog posts into pins on that map. 
    1414 
    15 This map can be embedded in your blog, giving your readers a new way to explore your world. 
     15When readers click on a pin it opens up the corresponding blog post in a new window. 
    1616 
    1717This map can also be seen on an iPhone (via the free Placeling app) so that your readers can literally see nearby places you've written about. 
     
    2424*   Each blog post includes a footer showing the location and a small map 
    2525*   At Placeling.com you can get an embed code to put your map in your blog 
     26*   When a reader clicks a pin an info window opens showing your snippet. Clicking the title of the info window opens that post 
    2627*   The [Placeling app](http://itunes.apple.com/ca/app/placeling/id465502398?mt=8 "Placeling app") is available for free in the iTunes app store 
    2728 
     
    6364== Changelog == 
    6465 
     66= 1.2.5 = 
     67* Bug Fixes around login 
     68* Placeling credentials now tied to site instead of author 
     69 
    6570= 1.1 = 
    6671* Fixed various IE8 issues 
Note: See TracChangeset for help on using the changeset viewer.