4 Replies Latest reply on Aug 10, 2016 10:51 PM by nemichandj77332782

    highlight selected text,unhighlight selected text in iframe

    nemichandj77332782

      hi,

      i am developing a phonegap application in which i am using iframe for loading external content which is present in app itself.so now i need to select the text using native page selection and want to highlight that selected text.but i am not able to edit the native textselection menu.so any plugin for editing the menu and highlighting the text when clicked over the button.

       

      plz le  me know plugin or other solution if any availiable.

       

      thanks!

       

      [Asking in the correct forum helps... Moved from non-technical Forum Lounge to specific Program forum... Mod]

        • 1. Re: highlight selected text,unhighlight selected text in iframe
          joe_bowser Adobe Employee (Admin)

          Can you please provide more details as to what you're trying to do.  For example, which platform are you currently trying to implement this on?  If you could provide these details, that would be greatly appreciated.

          • 2. Re: highlight selected text,unhighlight selected text in iframe
            nemichandj77332782 Level 1

            hi joe,

            i am using phonegap for ios,android,windows mobile application.in which i am developing app for book reading.so now the scenario is that i have one html page whcih is looks same like native and i load page in i.e external page using iframe in same html page.in which i want to provide functionality to zoom,highlight,remove highlight  inside iframe same like what we do on webiew for native application using edittext menu.so i want to create textedit menu which should popout when i select text of partciluar page loaded in iframe.when menu pops out i should have option to highlight so that i can highlight line of text.as well as i should be able to remove highlight by selecting text and click on edit text menu button.and is there any way to zoom in and zoom out using pinch zoom in iframe.

             

            i am loading native example which is to be done in phonegap for mobile,ipad etc.

            Screen Shot 2016-08-10 at 11.06.07 AM.png

            this is exactly what i need but its in native.i want this in phonegap for ipad,iphone,android and windows devices.

            thanks

            • 3. Re: highlight selected text,unhighlight selected text in iframe
              kerrishotts Adobe Community Professional

              Is the HTML file you're loading in the iframe a file you provide with the app, or is it an arbitrary website?

               

              Note: The highlighting behavior is not a "natural" feature of web text. You'll have to write code to insert the appropriate elements and styles to highlight selected text (and then undo it). IIRC, PG does not offer a way to edit the popup menu either, so you'll probably need to build your own touch handling and menu.

              • 4. Re: highlight selected text,unhighlight selected text in iframe
                nemichandj77332782 Level 1

                yes.Html file which i am loading in iframe is file i provide with the app.and in iframe for highlighting the text i am using rangy text highlighter which is being also used in above screen shot i.e native code.so i need only plugin which can be used for editing and calling native text edit menu.and i also want to zoom in and zoom out the page loaded in iframe.so plz help me .

                 

                 

                 

                thanks.