Travel Mapping

Web Design Discussion => General Web Design Discussion => Topic started by: Jim on May 18, 2017, 10:15:30 am

Title: Traveler Rankings by Region
Post by: Jim on May 18, 2017, 10:15:30 am
I've made a first pass at adding traveler rankings to the region page. It's currently available for a first look at URLs like:

http://tmtest.teresco.org/user/regiontest.php?units=miles&u=terescoj&rg=CA

Scroll to the bottom when you get there.

Don't use the controls on the page to switch users or regions, since they'll go to the old version of this page.  Edit the URL to try out different regions.  I have some ideas for improvement but I'd like to hear yours.

Once the version of the site with the units switching capabilities goes live, I'll make this the default region.php for tmtest for continued development and testing.  Once we're happy with what this one does, I intend to do the same on system.php.  I'm also thinking how best to do something similar on a per-route or per-connected route basis.
Title: Re: Traveler Rankings by Region
Post by: si404 on May 18, 2017, 10:57:39 am
It would be nice to be able to click the names on the list to see their travels.
Title: Re: Traveler Rankings by Region
Post by: mapcat on May 18, 2017, 12:05:04 pm
It would be nice to be able to click the names on the list to see their travels.
Agreed.

The routes traveled column sometimes includes an entry of "0" at the end: here's one (http://tmtest.teresco.org/user/regiontest.php?units=miles&u=mapcat&rg=VT). Clicking on the column head doesn't sort, even though hovering highlights it. If you're going to activate sorting, only one username column should be necessary.

Also, it would look better if the rows lined up across the tables.

General idea: while it's nice to have the option of viewing just active, or active + preview, having dual columns everywhere is a little overwhelming. Could active / active + preview be a universal user selection like units?
Title: Re: Traveler Rankings by Region
Post by: michih on May 18, 2017, 02:41:02 pm
Thanks :)

There are 4 tables with partially a lot of rows. I think there should be a link on top to jump to the tables (like an index).
Or tabs like I've suggested for system/region stats? Maybe more effort but I'm sure it's much better, e.g. to jump back from 4th to 3rd table etc.

"Travelers in Region CA" table:
- Only the first table has links!? I prefer to have a (hidden) link for all columns like, e.g. like stat.php
- I miss the rank index
- 4 tables within 1 table... Mapcats idea might be a solution or like stat.php with space between the tables?
Title: Re: Traveler Rankings by Region
Post by: Jim on May 18, 2017, 03:34:47 pm
Yes, I just put the links in the first table for now.  I'm not happy with the layout yet or how the links look.  I think it is kind of busy but my primary focus is on making the information available first then will make it look nicer.  The main reason for separating out the clinched distance from the route counts is that they come out of the DB in different ways and I am not sure I know enough SQL to get them out together in a convenient way.  They'll probably be in separate tables for now.  As for lining things up, that will be a low priority for me in part because I am not very good at CSS.

I'm actively working on it, so don't be surprised if things break from time to time. 
Title: Re: Traveler Rankings by Region
Post by: Jim on May 18, 2017, 04:22:17 pm
The main reason for separating out the clinched distance from the route counts is that they come out of the DB in different ways and I am not sure I know enough SQL to get them out together in a convenient way.

I have an idea how to do this, hope to try it tonight.  It looks like PHP supports multidimensional associative arrays, and that would make this more efficient and convenient, if they work the way I think they do...
Title: Re: Traveler Rankings by Region
Post by: Jim on May 18, 2017, 04:32:28 pm
I've removed the "regiontest.php" version of this.  Further development and testing can be done at URLs like

http://tmtest.teresco.org/user/region.php?units=miles&u=terescoj&rg=CA

and you should be able to use the controls to change users, regions, units, etc.
Title: Re: Traveler Rankings by Region
Post by: compdude787 on May 18, 2017, 09:30:39 pm
I didn't realize I was in the top five for WA! Anyway, I'd suggest making it a bit more obvious that you can scroll down to see all the tables. On my 1600x900 monitor in Chrome, all I can see without scrolling is the map, so for the longest time, that's all that I thought this page contained. I was like "uhhh, where's the rankings?" until I looked at the OP and saw that you had to scroll down to the bottom to see the rankings.
Title: Re: Traveler Rankings by Region
Post by: mapcat on May 18, 2017, 10:00:34 pm
Looks a lot better tonight. Other than the sorting, there seem to be no problems.
Title: Re: Traveler Rankings by Region
Post by: Jim on May 18, 2017, 10:23:39 pm
I think things are in much better shape now.  The table sorting has me stumped right now.  The two tables at the bottom are almost identical but the active only is sortable while the active+preview isn't.  I'm done with it for tonight, and I will put it on the production server probably tomorrow.  While it's not perfect, I think it's at least an improvement over what's out there from before.
Title: Re: Traveler Rankings by Region
Post by: Jim on May 20, 2017, 08:54:15 pm
This is now on the production server.  I hope to give system.php the same treatment next.
Title: Re: Traveler Rankings by Region
Post by: yakra on May 21, 2017, 12:52:25 am
I liked the CHM approach of having travregion.php (http://cmap.m-plex.com/stat/travregion.php?c=usa&rg=me&sort=) and travsystem.php (http://cmap.m-plex.com/stat/travsystem.php?sys=usame) as separate pages. IMO it's clunky & unintuitive to have this unrelated info contained on the same page as stats for a single user. That said though, I'm happy to have this info and will take it in whatever form I can get it for now. Again, thanks for coding this stuff.

Also, if the map area weren't used up showing travels for a single user, CHM-style "heat maps" of everyone's collective travels in the region/system would be, uhh... hot!

Edit: typos
Title: Re: Traveler Rankings by Region
Post by: michih on May 21, 2017, 03:05:27 am
I agree with yakra (btw: travregion.php and travregion.php? one should be system...) but I'd prefer one page with two tabs as said before.

I still miss the rank index in the "Travelers in Region" table and I'm a little bit confused by the "TOTAL CLINCHABLE" row. The info is important but it isn't an user. I don't know (and I guess I wouldn't understand) how it's implemented but it's already different (e.g. no link) to the other rows. Is it possible to put it to the end, last row? And exclude it from sorting? Maybe even a different color?