You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Title [PATCH] Improve html of mod_mirrorbrain
Priority feature Status resolved
Superseder Nosy List nick, poeml
Assigned To poeml Keywords mod_mirrorbrain
msg427 (view) Author: nick Date: 2013-07-14.15:57:19
The detailed files auto put of mod_mirrorbrain is not the most beatiful html in
the world and is also not very suitable for css styling. While it is possible to
rewrite it with javascript (kde did this), its probably a better solution to do
this in the module itself.
So, an attempt that will suit kde (haven't asked, but I'm pretty sure it does)
and (more importantly) Xfce since I maintain that installation.
Changes in the patch:
Use heads to create categories in the html (h2 for title, h3 for main groups,
h4 for subs).
Make a more complete "File information" group with a link for direct download
(KDE has this, kinds nice if you style it to a button).
Do not show Torrent information (torrent/magnet links and btih hash) if no
MirrorBrainTorrentTrackerURL is set in the apache configuration.
Add css classes and ids for webdesigners (divs around sections and some spans
to markup the file info).
Less invasive h2 header (only the name, not the full patch since it gets
excessively long in some deep-tree situations).
Drop the google map image, but only provide a link (50x50 is not showing any
information imho). Did a bit of styling in the uri to make a bigger, nicer map.
Fix incorrect html when no mirror is found.
Move mirrorbrain powered-by link to bottom of the html.
Fixed compiler warnings (%d -> %zu for format '%d' expects argument of type
'int', but argument 3 has type 'size_t' warnings).
Warning about unused newmirror variable.
I think the results is a nicer layout for users even in the plain layout and
will provide much better capabilities for webdesigners to integrate mirrorbrain
into their layout.
Did some testing (running at archive.xfce.org) and the resulted output was all
ok and html valid, but since we have a limited number of mirrors, not all types
of mirror array have been tested. But what could go wrong with copy-past hu?
I separated it from the other changed you did (like fixing the compiler warnings), so
it can be applied to the current SVN trunk. (I happened to fix the compiler warnings
already when I ran into then recently, not being aware of the details of your patch.)
It is a large patch and difficult to review in full length, but I'm sure it's a big
step forward also for other users, even though it might force some to update their
setups. But the better possibilities to adjust the looks should pay it back, I think.
In testing, I found something which -I think- was better before: the Google map
shows the entire world now, even when only a few mirrors in one country are
marked. That makes the data hard to see. Also it gives the false impression that
there all mirrors are concentrated in some part of the world, because only a
selection of ~10 mirrors is shown (also due to length of the URL constraints).
I get only positive feedback! I'm releasing 2.18.0 now.
Thanks again, Nick!
History
Date User Action Args
2014-02-04 19:31:03 poeml set status: testing -> resolved
messages: + msg519
2014-02-01 21:55:12 nick set messages: + msg507
2014-01-31 01:30:16 poeml set messages: + msg498
2014-01-31 01:29:23 poeml set messages: + msg497
2014-01-22 23:14:21 poeml set messages: + msg468
status: chatting -> testing
2014-01-22 22:45:40 poeml set assignedto: poeml
messages: + msg467
nosy: + poeml
2014-01-13 05:01:35 poeml set title: Improve html of mod_mirrorbrain ->
[PATCH] Improve html of mod_mirrorbrain
2013-07-15 15:24:11 nick set status: unread -> chatting
messages: + msg428
2013-07-14 15:57:19 nick create
(end of migrated issue)
The text was updated successfully, but these errors were encountered:
Issue migrated (2015-06-05) from old issue tracker http://mirrorbrain.org/issues/issue123
mod_mirrorbrain.patch nick, 2013-07-14.15:57:19 text/x-patch
msg427 (view) Author: nick Date: 2013-07-14.15:57:19
The detailed files auto put of mod_mirrorbrain is not the most beatiful html in
the world and is also not very suitable for css styling. While it is possible to
rewrite it with javascript (kde did this), its probably a better solution to do
this in the module itself.
So, an attempt that will suit kde (haven't asked, but I'm pretty sure it does)
and (more importantly) Xfce since I maintain that installation.
Changes in the patch:
h4 for subs).
(KDE has this, kinds nice if you style it to a button).
MirrorBrainTorrentTrackerURL is set in the apache configuration.
to markup the file info).
excessively long in some deep-tree situations).
information imho). Did a bit of styling in the uri to make a bigger, nicer map.
'int', but argument 3 has type 'size_t' warnings).
I think the results is a nicer layout for users even in the plain layout and
will provide much better capabilities for webdesigners to integrate mirrorbrain
into their layout.
Did some testing (running at archive.xfce.org) and the resulted output was all
ok and html valid, but since we have a limited number of mirrors, not all types
of mirror array have been tested. But what could go wrong with copy-past hu?
Example output here:
http://archive.xfce.org/xfce/4.10/src/Thunar-1.4.0.tar.bz2.mirrorlist
msg428 (view) Author: nick Date: 2013-07-15.15:24:11
Also available at github (https://github.com/nschermer/mod_mirrorbrain).
OT: would be nice if this was in fact hosted at github, makes contributions
easier. Just my opinion tho.
msg467 (view) Author: poeml Date: 2014-01-22.22:45:40
Great patch. I like it! Thank you so much.
I separated it from the other changed you did (like fixing the compiler warnings), so
it can be applied to the current SVN trunk. (I happened to fix the compiler warnings
already when I ran into then recently, not being aware of the details of your patch.)
It is a large patch and difficult to review in full length, but I'm sure it's a big
step forward also for other users, even though it might force some to update their
setups. But the better possibilities to adjust the looks should pay it back, I think.
Committed!
http://svn.mirrorbrain.org/viewvc/mirrorbrain?view=revision&revision=8334
msg468 (view) Author: poeml Date: 2014-01-22.23:14:21
I also applied commit 6a10d15b18617db10f172a8188f6345dd9962dae from
https://github.com/nschermer/mod_mirrorbrain now, which is a needed adjunct IMO.
msg497 (view) Author: poeml Date: 2014-01-31.01:29:23
In testing, I found something which -I think- was better before: the Google map
shows the entire world now, even when only a few mirrors in one country are
marked. That makes the data hard to see. Also it gives the false impression that
there all mirrors are concentrated in some part of the world, because only a
selection of ~10 mirrors is shown (also due to length of the URL constraints).
See this example:
http://maps.google.com/maps/api/staticmap?size=640x512¢er=0,0&visual_refresh=true&scale=2&maptype=roadmap&sensor=false&markers=color:red|47.000000,8.000000&markers=color:yellow|label:1|48.766998,9.183000&markers=color:yellow|label:2|50.771000,6.105000&markers=color:yellow|label:3|51.533001,9.933000&markers=color:yellow|label:4|51.966999,7.633000&markers=color:yellow|label:5|51.533001,9.933000&markers=color:yellow|label:6|52.220001,6.891000&markers=color:yellow|label:7|47.333000,13.333000&markers=color:yellow|label:8|52.167000,10.550000&markers=color:yellow|label:9|52.266998,10.533000
Removing "¢er=0,0" scales the relevant part of the map to the entire window,
which I like much more because it really shows details:
http://maps.google.com/maps/api/staticmap?size=640x512&visual_refresh=true&scale=2&maptype=roadmap&sensor=false&markers=color:red|47.000000,8.000000&markers=color:yellow|label:1|48.766998,9.183000&markers=color:yellow|label:2|50.771000,6.105000&markers=color:yellow|label:3|51.533001,9.933000&markers=color:yellow|label:4|51.966999,7.633000&markers=color:yellow|label:5|51.533001,9.933000&markers=color:yellow|label:6|52.220001,6.891000&markers=color:yellow|label:7|47.333000,13.333000&markers=color:yellow|label:8|52.167000,10.550000&markers=color:yellow|label:9|52.266998,10.533000
msg498 (view) Author: poeml Date: 2014-01-31.01:30:16
P.S. Don't just click on the above links, you have to copy and paste them in
complete.
msg507 (view) Author: nick Date: 2014-02-01.21:55:12
It gives a better picture in this case, I agree. I tested this with our mirror
list and also there it gives a better zoom level.
msg519 (view) Author: poeml Date: 2014-02-04.19:31:03
I get only positive feedback! I'm releasing 2.18.0 now.
Thanks again, Nick!
(end of migrated issue)
The text was updated successfully, but these errors were encountered: