Hi Ron,
One option would be to insert an HTTP header in each request sent to the pool(s) with the port the client made a request to. You could do this with a custom HTTP profile using the 'header to insert' option. Put the entry as: Port: [TCP::local_port]. To ensure the client can't manipulate this, you could configure the header name you're inserting also in the Header to Erase field in the HTTP profile.
The developers could then generate the application's references to itself using HTTP for clientside port 80 requests and HTTPS for clientside port 443 requests.
Aaron