currently i'm creating a SharePoint hosted add-in that allows me to show the Lync presence of a user. i have the code working on my appweb but when i try to render my page with a client webpart i get access denied. This is the code im using
<script type="text/javascript" src="/sites/SP2010/_layouts/1033/init.js"></script>
<script type="text/javascript" src="/sites/SP2010/_layouts/1033/core.js"></script>
<img id="uniqueID" onload="LyncPresence()" showofflinepawn="1" src="/sites/SP2010/_layouts/images/blank.gif" />
<script>
function LyncPresence() {
IMNRC('[email protected]', document.getElementById('uniqueID'));
}
</script>
Im thinking this is a CORS problem but i have no clue how to solve this. All help is welcome :)