multisite domain mapping url issue

I am having an issue with domain mapping, the mapping feature was installed by a third party, although they only completed half the job. They use the sunrise.php file.

the issue I am seeing is preventing us from using SSL on any of our chosen mutlsites, due to the fact that any images or scripts all seem to be running from the top level multisite.

For example

is our setup, with subdomain being the subsite name.

We then map the domain to that subsite giving us the literal setup.

however when you look in the source code, a lot of code still points to the main top level site

Should the domain mapping not transform those image urls into something more appropriate such as, as that would work, and has done in our tests, its just that the code isnt doing this.

When we map a domain, we use the admin network domain mapping tool to apply the mapped domain to the site ID, in cpanel we create a subdomain that points to the server IP.

are we missing a step?

In addition our caching software Zencache also points to the topsite domain rather than using the mapped domain for some cached scripts.