Add static mapping for this mac address button links to wrong page
The add static mapping for this mac address button used to take one to the static mapping entry page at /services_dhcp_edit.php?if=lan with the mac pre-filled. Very convenient.
now the button takes you to /services_dhcp.php . Not as convenient.
#2 Updated by David Gessel almost 5 years ago
well that is very weird. I opened chrome and tested, it worked correctly. I switched to a firefox tab, selected DHCP leases and got the same artifact (incorrect operation) reloaded, and it worked correctly. I restarted firefox between the first and second test.
Definitely cannot be reliably replicated even on my system. I'll make sure to screen grab the hover if I see it again.
#4 Updated by David Gessel almost 5 years ago
- File 01_shortURL.PNG 01_shortURL.PNG added
- File 02_establishing_connection.PNG 02_establishing_connection.PNG added
- File 03_destination.PNG 03_destination.PNG added
A little testing - I can get it to happen pretty reliably in both Chrome and Firefox. What I noticed was that the destination URL as revealed by text below fills out over the course of a few hundred msec and isn't quite complete when you first hover. If you click before it is fully formed, it takes you to an incomplete URL and that defaults to
01 - Click before the URL is fully worked out:
02 - the browser tries to go that URL, which....
03 - fails and defaults to services_dhcp.php
#5 Updated by Phillip Davis almost 5 years ago
Have you defined DHCP pools?
Do the effected entries have DHCP addresses issued from the pool(s)?
I can see that the code in status_dhcp_leases.php that calculates which interface each IP address comes from, is not going to work with IP addresses that have come from a pool.
#6 Updated by David Gessel almost 5 years ago
Yes, they are all fine. If I hover over the plus button for more than a few MSEC, the URL fills out completely and then I get the correct and expected result.
I suspect this is ultimately neither particularly important nor particularly easy to fix. I have a pretty large DHCP pool attached to a tiny little logic supply fanless computer. I doubt there is enough delay in a more appropriately balanced system to permit catching the link before it is fully constructed. It is more likely to be merely interesting that it is possible to do so than a real bug.
#7 Updated by Phillip Davis almost 5 years ago
So I don't know what your bug is - that is really weird if the link has "if=" with no interface, but then the interface value comes after a while - e.g. "if=lan".
There is a bug if you have multiple DHCP pools. The interface corresponding to IP addresses in the extra pools are not resolved back to the interface they are in, and that makes it go wrong in the way it is in your screen shots.
This should fix it: