[Script] WMEOpenData v2.16 (20150507)

Image

Moderators: Unholy, Timbones

Re: [Script] WMEOpenData v1.32 (20130520)

Postby NorfolkMustard » Wed May 22, 2013 11:29 am

;)

How are you getting the uniqueness? Would it benefit from a DB lookup rather than a set of .js files?
Stu
AM (L4): England wiki | Australia wiki
NorfolkMustard
Area Manager
Area Manager
 
Posts: 734
Joined: Thu Mar 25, 2010 7:44 am
Location: Blighty
Has thanked: 122 times
Been thanked: 146 times

Re: [Script] WMEOpenData v1.32 (20130520)

Postby NorfolkMustard » Wed May 22, 2013 4:15 pm

Twister_UK wrote:
NorfolkMustard wrote:;)

How are you getting the uniqueness? Would it benefit from a DB lookup rather than a set of .js files?


It performs a binary search through the pre-sorted placename list to see if the placename exists at all, and if so, it then does a local linear search to see if the name is unique. The last time I did any DB development work was during my IT GCSE in the late 80's, so I've got no idea if storing the names in a DB would be better :?


I'll have a play, see if I can get it working, then we can see if it would help. Can you point me to the source of the data?
Stu
AM (L4): England wiki | Australia wiki
NorfolkMustard
Area Manager
Area Manager
 
Posts: 734
Joined: Thu Mar 25, 2010 7:44 am
Location: Blighty
Has thanked: 122 times
Been thanked: 146 times

Re: [Script] WMEOpenData v1.32 (20130520)

Postby NorfolkMustard » Thu May 23, 2013 12:15 am

Twister_UK wrote:
NorfolkMustard wrote:;)

How are you getting the uniqueness? Would it benefit from a DB lookup rather than a set of .js files?


It performs a binary search through the pre-sorted placename list to see if the placename exists at all, and if so, it then does a local linear search to see if the name is unique. The last time I did any DB development work was during my IT GCSE in the late 80's, so I've got no idea if storing the names in a DB would be better :?


How's that for starters http://waze.cartwright.tv/gaz_gb.php (for the purposes of the demo it asks permission for your browser to provide lat/long. you can decline and type them in or provide a url with them in instead)

It should save you and each user a bit of time and bandwith (a few bytes per query v. 1.1mb gazetter.js file

It does the same lookup as you're doing I think, 5km either side of the given northings and eastings, but I've also calculated & stored the number of duplicates in each DB record, so it doesn't have to do subsequent lookups

I'm just showing the raw data for review currently. not limiting it to ten records, or creating the picklist yet, but they're easy do add.

Happy to hand over the DB and php if it's useful, or host it for you if you can't get a MySQL/php host running.

I'll be reusing/hosting the shell of it anyway as I want to do something similar for Australian wazers.
Last edited by NorfolkMustard on Fri May 24, 2013 9:48 pm, edited 1 time in total.
Stu
AM (L4): England wiki | Australia wiki
NorfolkMustard
Area Manager
Area Manager
 
Posts: 734
Joined: Thu Mar 25, 2010 7:44 am
Location: Blighty
Has thanked: 122 times
Been thanked: 146 times

Re: [Script] WMEOpenData v1.33 (20130522)

Postby NorfolkMustard » Fri May 24, 2013 9:47 pm

Twister_UK wrote:Thanks, haven't had time to look at it yet but I'll try and do so over the weekend (kids, family engagements and other time-leeches permitting...)


No rush, hope it shows some potential for you. If you add &json to the end of the url it will return a JSON encoded string of the 10 closest items from the given eastings/northings. e.g.

http://waze.cartwright.tv/gaz_gb.php?no ... Names&json
Stu
AM (L4): England wiki | Australia wiki
NorfolkMustard
Area Manager
Area Manager
 
Posts: 734
Joined: Thu Mar 25, 2010 7:44 am
Location: Blighty
Has thanked: 122 times
Been thanked: 146 times

Re: [Script] WMEOpenData v1.33.1 (20130529)

Postby NorfolkMustard » Sat Jun 29, 2013 8:47 pm

v1.33.1 working OK for me on the prod editor. I do find I have to refresh/ click permalink to get it to appear every now and then.

Chrome v27
Stu
AM (L4): England wiki | Australia wiki
NorfolkMustard
Area Manager
Area Manager
 
Posts: 734
Joined: Thu Mar 25, 2010 7:44 am
Location: Blighty
Has thanked: 122 times
Been thanked: 146 times

Re: [Script] WMEOpenData v2.1 (20140106)

Postby NorfolkMustard » Tue Jan 07, 2014 8:31 am

Thanks. Updated automatically for me (I had prev installed 2.0 from Chrome WS last week)
Stu
AM (L4): England wiki | Australia wiki
NorfolkMustard
Area Manager
Area Manager
 
Posts: 734
Joined: Thu Mar 25, 2010 7:44 am
Location: Blighty
Has thanked: 122 times
Been thanked: 146 times

Re: [Script] WMEOpenData v2.1 (20140106)

Postby NorfolkMustard » Fri Jan 10, 2014 7:29 am

The delay will be your computer's cache or the DNS server of your ISP

I've prodded opendns for you so anyone using that service for DNS will get routed ok.

On your PC you can start > run > cmd > ipconfig /flushdns
Stu
AM (L4): England wiki | Australia wiki
NorfolkMustard
Area Manager
Area Manager
 
Posts: 734
Joined: Thu Mar 25, 2010 7:44 am
Location: Blighty
Has thanked: 122 times
Been thanked: 146 times

Re: [Script] WMEOpenData v2.2 (20140111)

Postby NorfolkMustard » Sat Jan 11, 2014 12:13 pm

Thanks Chris. Chrome WS is offering v2.1 currently
Stu
AM (L4): England wiki | Australia wiki
NorfolkMustard
Area Manager
Area Manager
 
Posts: 734
Joined: Thu Mar 25, 2010 7:44 am
Location: Blighty
Has thanked: 122 times
Been thanked: 146 times

Re: [Script] WMEOpenData v2.2 (20140111)

Postby NorfolkMustard » Sat Jan 11, 2014 12:22 pm

Thanks. Took a couple of mins to sync I suppose ("Details" tab on WS shows the version)
Stu
AM (L4): England wiki | Australia wiki
NorfolkMustard
Area Manager
Area Manager
 
Posts: 734
Joined: Thu Mar 25, 2010 7:44 am
Location: Blighty
Has thanked: 122 times
Been thanked: 146 times

Re: [Script] WMEOpenData v2.4 (20140518)

Postby NorfolkMustard » Sun May 18, 2014 10:54 am

Ta
Stu
AM (L4): England wiki | Australia wiki
NorfolkMustard
Area Manager
Area Manager
 
Posts: 734
Joined: Thu Mar 25, 2010 7:44 am
Location: Blighty
Has thanked: 122 times
Been thanked: 146 times

PreviousNext

Return to United Kingdom

Who is online

Users browsing this forum: No registered users