« Portlets に戻る

IP Geocoder Portlet

Table of Contents [-]

Information #

The IP Geocoder portlet locates your geological position. This portlet is not used so much as a stand alone portlet, although it does display your location in the portlet window, but is used in conjunction with other portlets, such as the Map portlet and the Google Maps portlet. The IP Geocoder portlet utilizes Max Mind's GeoIP City Database.

Configure#

  • 1. Deploy the IP Geocoder portlet.
  • 2. Shut down your application server.
  • 3. Download the GeoIP City Database, such as the free GeoLite City Database.
  • 4. Unzip the .dat file to your desired storage path.
  • 5. Go to /{ROOT}/webapps/ip-geocoder-portlet/WEB-INF/classes/.
  • 6. Create a portlet-ext.properties file at this location.
  • 7. Add the property maxmind.database.file=(GeoIP City Database .dat file path) to this file.
  • 8. Start your application server.
0 添付ファイル
49507 参照数
平均 (2 投票)
平均評価は4.0星中の5です。
コメント
コメント 作成者 日時
After these instructions, there is blank, grey... Jakub Liska 2010/10/06 9:18
Once you've installed IP Geocoder, edit... Franck Liénard 2011/02/13 9:06
Yes you are correct Franck. I had the same... Manikandan S 2011/08/15 21:55
Hi Franck, In my... Manikandan S 2011/08/17 3:01

After these instructions, there is blank, grey screen inside the portlet and I can't manage all the other porlets within the page (remove, min, max, edit)...
because of this:

16:06:18,191 INFO [PortalImpl:3847] Current URL /poller/receive generates exception: null
16:06:48,193 INFO [PortalImpl:3847] Current URL /poller/send generates exception: null
16:07:18,195 INFO [PortalImpl:3847] Current URL /poller/send generates exception: null
16:07:34,706 INFO [PortalImpl:3847] Current URL /poller/receive generates exception: null
16:07:39,969 INFO [PortalImpl:3847] Current URL /poller/receive generates exception: null
16:08:09,969 INFO [PortalImpl:3847] Current URL /poller/send generates exception: null
16:08:39,971 INFO [PortalImpl:3847] Current URL /poller/send generates exception: null
16:08:42,645 INFO [PortalImpl:3847] Current URL /poller/receive generates exception: null
16:09:04,135 INFO [PortalImpl:3847] Current URL /poller/receive generates exception: null
16:09:14,498 INFO [PortalImpl:3847] Current URL /poller/receive generates exception: null
投稿日時:10/10/06 9:18
Once you've installed IP Geocoder, edit /social-networking-portlet/map/view.jsp.
Replace these lines :
<liferay-util:html-bottom>
<script src="http://www.google.com/jsapi?key=<%= PortletProps.get("map.google.maps.api.key") %>" type="text/javascript"></script>
</liferay-util:html-bottom>

By :
<liferay-util:html-top>
<script src="http://www.google.com/jsapi?key=your-google-maps-api-key" type="text/javascript"></script>
</liferay-util:html-top>
Jakub Liskaへのコメント。投稿日時:11/02/13 9:06
Yes you are correct Franck. I had the same problem then I replaced this coding now its working fine. Thanks.
Franck Liénardへのコメント。投稿日時:11/08/15 21:55
Hi Franck,
In my social-networking-portlet\map\view.jsp page shows like,
float latitude = ipInfo.getLatitude();
System.out.println("latitude#########"+latitude);
float longitude = ipInfo.getLongitude();
System.out.println(" longitude #########"+longitude);
Both latitude and longitude return 0.0 value. I couldn't get exact location of the user in the map.
Mani kandanへのコメント。投稿日時:11/08/17 3:01