0

I have array of words:

['apple', 'mango', 'orange']

And i have an iFrame on my page (in the same domain) and i need to highlight all matches of these words in it. Moreover i need to change style of these words (change some text styles and handle click event on them)

Is any solutions for this? Search in PDF js working perfect https://mozilla.github.io/pdf.js/web/viewer.html

how i can implement the same ?

Rajesh
  • 24,354
  • 5
  • 48
  • 79
lemmer
  • 1
  • 1
  • 1
    Can you pass these values to iFrame and is the code of page inside iFrame accessible to you? – Rajesh Apr 07 '17 at 09:33
  • is the iframed page under the same domain? – Ari Apr 07 '17 at 09:36
  • @KeepMove Yes. Its been stated in question. – Rajesh Apr 07 '17 at 09:37
  • @Rajesh yes, the code into iframe is accessible for me. I can paste some script into inner page. – lemmer Apr 07 '17 at 09:47
  • Then you should look for searching the document and highlight the words. You can check following link for reference: http://stackoverflow.com/questions/119441/highlight-a-word-with-jquery – Rajesh Apr 07 '17 at 10:33

0 Answers0