IP address neat trick
Posted: Sun Jan 22, 2012 10:56 pm
Here's something you might find helpful. We are going to have the IP address of each player in the player dropdown in playlist.jsp assigned to the title. Sounds complicated, but it really isn't. Check it out:
We are going to edit playlist.jsp.
Here is the part we are going to edit:
Right before "value="${player.id}"", add "title='${player.ipAddress}'".
Now, when you open the dropdown and hover over an entry, it will show you the last IP address that was used by that player.
Hope this helps!
We are going to edit playlist.jsp.
Here is the part we are going to edit:
- Code: Select all
<td><select name="player" onchange="location='playlist.view?player=' + options[selectedIndex].value;">
<c:forEach items="${model.players}" var="player">
<option ${player.id eq model.player.id ? "selected" : ""} value="${player.id}">${player.shortDescription}</option>
</c:forEach>
</select></td>
Right before "value="${player.id}"", add "title='${player.ipAddress}'".
Now, when you open the dropdown and hover over an entry, it will show you the last IP address that was used by that player.
Hope this helps!