Jump to content

Breakthrough: I've managed to enable copying text from Opera Mini on ALL mobile platforms!!

Guest Menneisyys

Recommended Posts

Guest Menneisyys

As has been pointed out in all of my articles dedicated to the excellent, lightweight browser Opera Mini, in addition to the lack of italic characters, probably the biggest problem with it has always been the lack of support for copying text from a Web page.

Now, this is fixed. While the way I've enabled copying is certainly inferior to the excellent copy capabilities of Teashark (see THIS), it's certainly working and, at last, enables anyone to copy anything out of any Web page, regardless of the platform you use. Yeah, it IS revolutionary.

How it works? Pretty easy: I've created a Web application that you need to pass the address (the URL) of the page you'd like to copy contents from. After entering (copying) the address, it presents you the contents of the page in a text area, which is already copy-enabled; that is, you can copy anything from them to your device's clipboard.

As mobile devices, in general, are only able to handle small(er) chunks of text in a text area, the dialog you're presented uses 2000-char-long chunks of text. You can easily switch between the block you're reading by just clicking the appropriate block link (0, 1, 2 etc.) There's also a way to force the application to display the entire page at once; note that, with pages over 10-15 kilochars, this may result in Opera Mini's slowing to crawl. That is, use it if you're absolutely sure your particular model / operating system lets for putting larger texts in an editable text area.

Now, let's see how this all works in practice.

1. add the Web page http://menneisyys.s156.eatj.com to your favorites in Opera Mini (the easiest way of doing this is reading this article in Opera Mini and clicking the link)

2. when you're on a(nother) page you'd like to copy something from, copy the address of the page you'd like to copy text from to the clipboard of your device. This needs to be done in the following way:

a. on Windows Mobile Pocket PC's (but not touchscreen-less Smartphones, where you need an additional app for copying):

a-1: press #1 (if your phone has a hardware dialpad) or go to Menu (left softkey) / Enter Address

a-2: If you haven’t disabled the new auto-completion address input field (the Auto-complete address input checkbox in Settings), press Down and go to Insert symbol… by pressing Up; and select it; you’ll be taken to the address input field of your Java environment. (You’re taken straight here if you disable the new, Opera Mini-specific address input field.)

a-3: select Menu (right softkey) / Current Address

a-4: As you can see, the address of the current page is displayed. Just copy it: highlight it entirely (under Jbed, to do this, click Shift, Ctrl and, finally, the left arrow on the on-screen keyboard) and press Ctrl-C on the virtual keyboard.

b. on Blackberry phones:

b-1: press #1 (if your phone has a hardware dialpad) or go to Menu / Enter Address

b-2: If you haven’t disabled the new auto-completion address input field (the Auto-complete address input checkbox in Settings), roll the trackball down, and, then, up, until you get to Insert symbol…. Now, you'll be taken to the address input field of your Java environment. (You’re taken straight here if you disable the new, Opera Mini-specific address input field.)

b-3: press the Shift button and roll the trackball down until the entire (current) address is selected

b-4: press Menu and select the (default) Copy.

b-5: to exit this dialog, press Back twice.

3. now that you've copied the address of the current page, switch to the previously (in bullet 1) stored page. When it loads, copy the URL of the previous page (the one you'd like to copy text from) to the "Enter the URL to convert" textfield. To do this, start editing the field and,

- on Blackberries, press the hardware Menu button and go down to Paste.

- on Windows Mobile devices, bring up the virtual keyboard and click Ctl, and, then, V

- on Symbian devices, long-press the Pen button until "Paste" is shown over the right softkey. Not releasing the Pen button, press the right softkey.

After some conversion, a new page is displayed, with a huge text area displaying the textual contents of the Web page. If the contents of the page is longer than 2000 characters, only the first 2000 is displayed (not to overburden the phone) and you can select the later ones by clicking 1, 2, ... n at the top of the page. You can also make the system display the entire content entirely, without cutting it in chunks, by clicking the "Click here to see the entire page!" link. Again, use this feature with caution - again, your phone may slow to a crawl, if the midlet manager's text area component is able to edit so huge blocks of text at all).

Finally, if you absolutely don't see anything and/or you'd like to see the entire markup of the page, click "Click this to switch to tag-enabled mode if you don't see anything".

After you've stepped into editing the text area displaying the (given chunk of) text, just look for the expression / URL etc. to copy to the clipboard. Once you've found it, highlight it and copy to the clipboard. This operation is supported on all the major smartphone operating systems and done in the same way as copying the address of the current page to the clipboard.


Currently, the converter is hosted on a free JSP server that needs to be manually restarted every six hour (to force people to purchase a real Web package). That is, when you do check it out, it might not work at all. I will surely move it to another page / service provider if I don't find anyone else to voluntarily host it, depending on the price / conditions. (Currently, I don't really need a JSP/PHP-capable Webpage and, consequently, I've only subscribed to a static one for my database/picture/file back-end at http://www.winmobiletech.com/ ; this is why I can't currently host it myself.)

If you have the bandwidth and you'd like to help Opera Mini users, feel free to host the files yourself. If you have a JSP engine (Tomcat et al.), you'll find the web application (WAR) file HERE. If you only have a PHP or ASP engine, and don't want to struggle with porting the Java app into PHP or ASP, let me know and I convert it instead.


The source of my converter is really-really small. The two, related files HERE and HERE, should you want to know how it works. The first is the main "landing" page you need to paste the URL to paste text from (it's a static HTML page as there is no need for any dynamic content in it); the second is the actual JSP page doing the work.

Link to comment
Share on other sites

Guest Menneisyys

I've updated my eatj.com account: subscribed to a one-month plan (for $10). Now, the service should start working in 12 hours. There will be no pauses from now on. Feel free to use the service - and don't forget to provide me feedback on what you would welcome.

Also free to provide me with commonly visited pages (CNN etc.) that you think I could provide a more sophisticated engine - for example, only displaying article text and not displaying other stuff.

All in all, feel free to (publicly! NOT IN PRIVATE MESSAGES, they will all be ignored!) ask me to provide new functionality and/or site-based custom processing.

Link to comment
Share on other sites

Guest Menneisyys


In the meantime, based on public feedback (see selurus' and yitzy's requests on Wednesday, 3. June 2009, 18:13:35 and 23:30:15, respectively, at http://my.opera.com/community/forums/topic...mp;t=1244154046 ), I've added the following two front-end pages:

http://menneisyys.s156.eatj.com/i2.html : if you paste the source page URL to this page, you'll be presented by all blocks in order. This way, you'll see (based on the text already visible in the beginning of each textarea) right away in which block you need to look. selurus reported it caused no slowdown on his handset; your mileage, on other handset models / operating systems may vary. That is, if you don't need this kind of breakup and/or it causes too much slowdown and you're sure you can find a given part of the text faster using the traditional links, use the first version instead. (Feedback is welcome!)

http://menneisyys.s156.eatj.com/i3.html : this displays UTF-8 pages properly (most oriental languages like Chinese / Japanese; Hebrew etc.). I've tested it with http://www.haaretz.co.il/hasite/spages/1090414.html (Hebrew) and http://fi.wikipedia.org/wiki/Romanit (Finnish; check out the letter "ž" in word gudžarati after "urdu, hindi, sanskrit ja"). NOTE: it's for UTF-8 source pages ONLY. Do not try to decode e.g. East-European languages using 8859-X with it. I plan to release a version compatible with these traditional, 8-bit encodings as well when I have the time so that charset setting becomes automatic.

As you can see, these front-ends 1. offer an alternative view (displaying the content of the entire page in multiple text areas, keeping in mind the text area editing limits) and 2. allow for copying from UTF-8-encoded pages.


Also in the Opera Mini Community forum, there's a nice tip posted by Yeswap: use "bookmarklets" to speed up invoking the converter. To do this, do the following:

1. from Opera Mini, go to http://o.yeswap.com/

2. click Tools or scroll down to Tools

3. click Copy Page Text

4. (seemingly) the same page reloads; NOW bookmark it as a standard bookmark (Menu / Tools / Add Bookmark or #7 if you have hardware buttons). However, don't save the bookmark yet - just open it for editing!

5. remove "http://o.yeswap.com/?" from the URL so that it becomes java script:location.href='http://menneisyys.s156.eatj.com/om.jsp?q='+encodeURIComponent(location.href'>http://menneisyys.s156.eatj.com/om.jsp?q='+encodeURIComponent(location.href)+'&blocknr=0'

6. now, you can already save the edited bookmark.

7. you can quickly invoke the new bookmark: when you're on a Web page you'd like to copy to the contents to an editable text area (so that you can, later, copy text from), just go to your bookmarks (Menu / Bookmarks or, if you have hardware keys, #2) and click the just-added "Copy Page Text" entry. You'll be immediately taken to the target page - that is, no manual URL pasting is necessary any more! As you can see, this has really made all this very simple.

Note that you can safely change "om.jsp" to either "om2.jsp" or "om3.jsp" in the URL you bookmark (so that it becomes java script:location.href='http://menneisyys.s156.eatj.com/om2.jsp?q='+encodeURIComponent(location.href)+'&blocknr=0' and java script:location.href='http://menneisyys.s156.eatj.com/om3.jsp?q='+encodeURIComponent(location.href)+'&blocknr=0', respectively), should you want to have a direct link to the two new, alternative pages (display all the pages and use UTF-8) I've just added.

Also note that, strictly, you don't have to go to http://o.yeswap.com/ to add the bookmarklets. You can do the same by adding a new bookmark with the above contents (e.g., java script:location.href='http://menneisyys.s156.eatj.com/om2.jsp?q='+encodeURIComponent(location.href)+'&blocknr=0' ). Also, you can name your bookmark anything - not strictly Copy Page Text.

Link to comment
Share on other sites

Guest Menneisyys

I've implemented PDF support.

After a lengthy and careful evaluation of the current Java libraries used for PDF parsing, I've decided to choose Adobe's own one.

To use it,

1. navigate to http://menneisyys.s156.eatj.com/pdf.html and paste the URL to the PDF there.

2. if someone else has some seconds ago checked translated the document, you'll be presented its textual contents, in the usual multiple text areas (see http://menneisyys.s156.eatj.com/i2.html ) right away.

3. if it's the first time in the last few seconds that the document has been converted, you'll be dispatched to Adobe's page. After some 10-20-30 seconds of waiting, the conversion is finished and you'll be shown the textual version of the page.

4. NOW, just press Back until you get back to http://menneisyys.s156.eatj.com/pdf.html . Press the Submit button again. Now that it was just some seconds ago that you made Adobe convert your document, you'll be presented it, already in the text areas.

It's a bit convoluted but "hiding" the Adobe interface and make it even easier would have taken me too much time / effort.

Hope you'll like it <_<

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in

Sign In Now
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.