Jump to content

User talk:Paradox-01/Archive1: Difference between revisions

→‎Overview: v1.0 is done; suggestions for improvement are welcome
(→‎Overview: v1.0 is done; suggestions for improvement are welcome)
Line 331: Line 331:
I tried get myself more familiar with the different codes and their mixing, but I would just ending to make hundreds of edits just to learn how to do this or that. So I can't be a great help here. :/ [[User:Paradox-01|paradox-01]] ([[User talk:Paradox-01|talk]]) 22:09, 13 November 2012 (CET)
I tried get myself more familiar with the different codes and their mixing, but I would just ending to make hundreds of edits just to learn how to do this or that. So I can't be a great help here. :/ [[User:Paradox-01|paradox-01]] ([[User talk:Paradox-01|talk]]) 22:09, 13 November 2012 (CET)
:That's okay, I have played around with JS before. I'll spend some time on this soon. --[[User:Iritscen|Iritscen]] ([[User talk:Iritscen|talk]]) 00:42, 14 November 2012 (CET)
:That's okay, I have played around with JS before. I'll spend some time on this soon. --[[User:Iritscen|Iritscen]] ([[User talk:Iritscen|talk]]) 00:42, 14 November 2012 (CET)
Okay, I wrote some quick and dirty code and put it in Common.js. Go to my test space's file type table and you should get descriptions when you hover over each type. This could easily be adjusted to require a click instead of a hover but I liked the idea of a no-click interface. I'm going to step aside now and give you the chance to work with this table type as you see fit. I had to simplify the markup for testing purposes, and you might have some better ideas as to how to arrange the table.
As you'll see, the basic idea is that you attach the class "hovertable" to a wikitable, then you place multiple spans in one large cell of class "hovertable_descrip". Each span is "display:none" and contains the description for one type, which is given as that span's id. Then you declare other cells in the hovertable as class "hovercell" with ids that match the ones in the descrip cell. The JS I wrote attaches event handlers to all hovercells which display their corresponding span in the hovertable_descrip cell when the hovercell receives 'mouseover', and hide the span upon 'mouseout'. --[[User:Iritscen|Iritscen]] ([[User talk:Iritscen|talk]]) 20:22, 16 November 2012 (CET)