Skip to Main Content

APEX

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Javascript - Interactive Report

Brett ChMar 31 2014 — edited Apr 2 2014

Hello all,

Application Express 4.2.4.00.08

I have run into an issue using Javascript within an Interactive Report.

I am using this Javascript function to compare 2 strings and highlight the differences between the two texts.

http://ejohn.org/files/jsdiff.js  (using diffString function).


Overall, I need to populate a column value with this function.  I am not sure if the following is the most optimal, but this is currently what I have gotten to work to an extent. (If there is something better, I am gladly willing to learn)


select

t.NEW_VALUE

,t.OLD_VALUE

,'<script>javascript:document.write(diffString("'||t.OLD_VALUE||'","'||t.NEW_VALUE||'"));</script>' as DIFF_VALUE

from AUDIT_TRAIL t



This works fine when the page is loaded.  However, when the user searches, the loading symbol appears and the screen turns all white. The only thing on the screen is DIFF_VALUE for the row i searched on (just the value).  If I click the back button or re-submit the current URL, the report loads with all the columns and with the specified search.  This happens the same way for pagination.  To test, I copied the entire page but used Classic report (instead of interactive).  In the Report Attributes, I set the "Enable PPR" to "No" and this fixed the pagination issue.  Is there something I can do to the interactive report?

Thank you,

Brett 




This post has been answered by DannyD on Mar 31 2014
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 30 2014
Added on Mar 31 2014
4 comments
1,278 views