Question

3
Replies
59
Views
GAVINHSU Member since 2011 19 posts
Mediatek Inc. China
Posted: 4 months ago
Last activity: 2 months 1 week ago
Solved

Mashup scripts is not loaded properly, pzIncludeMashupScripts responses text/html content type

Hi,

We've just upgraded our PEGA platform from 7.1.8 to 8.3.1, and we're using Mashup to embedded PEGA applications into our own portal.

The Mashup code we're using as below:

<script> src ='<%=webRoot%>/prweb/IAC/?host=<%=host%>&pyActivity=pzIncludeMashupScripts&pzAuth=guest'></script>
<div id="IACGadget"
data-pega-gadgetname ='IACGadget' 
data-pega-action ='OpenWorkByURL' 
data-pega-action-param-query='pyActivity=@baseclass.DoUIAction'
data-pega-action-param-model ='' 
data-pega-action-param-readonly ='false'
data-pega-isdeferloaded ='false' 
data-pega-applicationname ='BPMApp' 
data-pega-threadname ='<%=threadId%>' 
data-pega-resizetype ='stretch' 
data-pega-url ='<%=webRoot%>/prweb/IAC/' 
data-pega-action-param-parameters ="{'pzSkinName':'ApplicationSkin','pyMashupSkeletonName':'pyDefaultMashupSkeleton'}"></div>

Normally this piece of code works fine, except when the session timed out.

We found the pzIncludeMashupScripts was blocked by IAC authentication after session timed out.

So, we're trying to use another way to load Mashup scripts as below:

<script type="text/javascript" src='<%=webRoot%>/prweb/PRServlet/?host=<%=host%>&pyActivity=pzIncludeMashupScripts&pzAuth=guest'></script>

We found that the Mashup scripts can be loaded even after session timed out.

But the Content-Type of response header was set to "Content-Type: text/html;charset=UTF-8", which causes the Mashup not working even the scripts can be loaded.

Please help us with either one of the solutions as below:

  1. How can we change the Content-Type to "Content-Type: text/javascript;charset=UTF-8"?
  2. How can the Mashup scripts be loaded even after session timed out?

Thanks a lot.

Pega Platform 8.3.1 Low-Code App Development Upgrades Manufacturing and High Technology Lead System Architect
Share this page LinkedIn