Howard has already hinted at this, but I'll be foolish enough to ask ... is your setup like this?
Circuit (you call it a line) A -> upstream provider who uses public IP blocks of 65.x.x.x.
Circuit B -> *different* upstream provider who uses public IP blocks of 205.x.x.x.
One router for both circuits? Or is there a router per circuit? There are two interfaces on each router or NICS on the router if single router that are configured for their respective upstream IP blocks. Your firewall box sits between the routers and all other switches/ servers/workstations you have internally ... including the Moodle server which has a private IP address in it. Does that firewall box have two NIC's in it? eth0 -> Circuit A router and eth1 -> Circuit B router?
So you are talking about a 'failover' system for your entire network, which, if not automated and setup ahead a time will take a few minutes, or longer, to establish connectivity.
If that's the case, you'll need to use a single FQDN for your Moodle ... or Joomla, or WP box internally. Internal DNS stays the same ... no reason to change server IP addresses they are private IP's anyway, but you will need an *external* failover DNS solution.
Google for that ... failover DNS.
'spirit of sharing', Ken