Title: EasyGeo
Author: theozero
Published: <strong>2011 年 5 月 3 日</strong>
Last modified: 2011 年 5 月 3 日

---

搜索插件

**该插件尚未通过WordPress的最新3个主要版本进行测试**。 当与较新版本的WordPress一起
使用时，可能不再受到维护或支持，并且可能会存在兼容性问题。

![](https://s.w.org/plugins/geopattern-icon/easygeo.svg)

# EasyGeo

 作者：[theozero](https://profiles.wordpress.org/theozero/)

[下载](https://downloads.wordpress.org/plugin/easygeo.zip)

 * [详情](https://cn.wordpress.org/plugins/easygeo/#description)
 * [评价](https://cn.wordpress.org/plugins/easygeo/#reviews)
 *  [安装](https://cn.wordpress.org/plugins/easygeo/#installation)
 * [开发进展](https://cn.wordpress.org/plugins/easygeo/#developers)

 [支持](https://wordpress.org/support/plugin/easygeo/)

## 描述

This plugin is extremely simple, and intended for someone who wants to add geocoding
to their blog, but without the bloat of a big fat plugin. This lets you tag each
post with a location (description, latitude, longitude) which can then be used in
your custom theme.

This plugin also provides a feature to track of a single location not associated
with any posts. This is useful in order to create a “Where Am I?” feature on your
blog where you control the level of detail (just to share the city, rather than 
pluggin in foursquare data). This is especially nice if you’re running a travel 
blog or a website for some kind of tour.

## 屏幕截图

 * [[
 * The extra meta-box that appears while editing posts. A similar box appears on
   the dashboard if you choose to enable the “Where Am I” tracker.

## 安装

 1. Upload `easygeo.php` to the `/wp-content/plugins/` directory
 2. Activate the plugin through the ‘Plugins’ menu in WordPress
 3. Use `EasyGeo :: getCoordinates($post->ID)` to get the coordinates in tuple (description,
    lat, lon)
 4. Or use `EasyGeo :: getCoordinatesString($post->ID)` to get “lat,lon” and `EasyGeo::
    getLocationString($post->ID)` to get the description
 5. Use `EasyGeo :: getCurrentCoordinates()` and getCurrent… to get the single location
    tracked from the dashboard

## 常见问题

### How do I actually add a map to my template?

You can use the google static maps API to get a static image. Heres an example:

    ```
    <?php if ( EasyGeo :: getCoordinates($post->ID) != null ) : ?>
    <div>
        <img src="http://maps.google.com/maps/api/staticmap?center=<?php echo EasyGeo::getCoordinatesString($post->ID); ?>&zoom=6&size=219x220&maptype=hybrid&markers=color:blue|<?php echo SimpleGeo::getCoordinatesString($post->ID); ?>&sensor=false" width="219" height="220" />
        <span id="where_label"><?php echo SimpleGeo::getLocationString($singlepostid); ?></span>
    </div>
    ```

Or you can use the regular API to get an interactive map. It’s all pretty straightforward.

### What else does this plugin do?

Nothing. The point is that it’s dead simple, and easy to use in the backend. From
this, you can build all kinds of crazy interactive map browsers for your blog and
this plugin will just handle the tagging on the backend.

_Enjoy!_

## 评价

此插件暂无评价。

## 贡献者及开发者

「EasyGeo」是开源软件。 以下人员对此插件做出了贡献。

贡献者

 *   [ theozero ](https://profiles.wordpress.org/theozero/)

[帮助将「EasyGeo」翻译成简体中文。](https://translate.wordpress.org/projects/wp-plugins/easygeo)

### 对开发感兴趣吗?

您可以[浏览代码](https://plugins.trac.wordpress.org/browser/easygeo/)，查看[SVN仓库](https://plugins.svn.wordpress.org/easygeo/)，
或通过[RSS](https://plugins.trac.wordpress.org/log/easygeo/?limit=100&mode=stop_on_copy&format=rss)
订阅[开发日志](https://plugins.trac.wordpress.org/log/easygeo/)。

## 更新日志

#### 1.0

 * Initial Release

## 额外信息

 *  版本 **1.0**
 *  最后更新：**15 年前**
 *  活跃安装数量 **10+**
 *  WordPress 版本 ** 2.0.2 或更高版本 **
 *  已测试的最高版本为 **3.0.0**
 *  语言
 * [English (US)](https://wordpress.org/plugins/easygeo/)
 * 标签
 * [geo](https://cn.wordpress.org/plugins/tags/geo/)[geocode](https://cn.wordpress.org/plugins/tags/geocode/)
   [geocoding](https://cn.wordpress.org/plugins/tags/geocoding/)[lat](https://cn.wordpress.org/plugins/tags/lat/)
   [lon](https://cn.wordpress.org/plugins/tags/lon/)
 *  [高级视图](https://cn.wordpress.org/plugins/easygeo/advanced/)

## 评级

尚未提交反馈。

[Your review](https://wordpress.org/support/plugin/easygeo/reviews/#new-post)

[查看全部评论](https://wordpress.org/support/plugin/easygeo/reviews/)

## 贡献者

 *   [ theozero ](https://profiles.wordpress.org/theozero/)

## 支持

有话要说吗？是否需要帮助？

 [查看支持论坛](https://wordpress.org/support/plugin/easygeo/)

## 捐助

您愿意支持这个插件的发展吗?

 [ 捐助此插件 ](http://theoephraim.com/)