<p>So my site uses <a href="http://mjijackson.com/shadowbox/" rel="nofollow noreferrer">shadowbox</a> to do display some dynamic text.  Problem is I need the user to be able to copy and paste that text.  </p>

<p>Right-clicking and selecting copy works but <kbd>Ctrl</kbd>+<kbd>C</kbd> doesn't (no keyboard shortcuts do) and most people use <kbd>Ctrl</kbd>+<kbd>C</kbd>?  You can see an example of what I'm talking about <a href="http://mjijackson.com/shadowbox/" rel="nofollow noreferrer">here</a>. </p>

<p>Just go to the "web" examples and click "inline". Notice keyboard shortcuts do work on the "this page" example. The only difference between the two I see is the player js files they use.  "Inline" uses the html.js player and "this page" uses iframe.js.  Also, I believe it uses the mootools library. Any ideas?</p>

[{'answer_id': 58063, 'author': 'Robby Slaughter', 'author_id': 1854, 'author_profile': 'https://Stackoverflow.com/users/1854', 'pm_score': 1, 'selected': False, 'text': '<p>This problem is caused by some JavaScript which eats keyboard events. You can hit the escape key, for example, which is trapped by one of the .js files and causes the shadow box to close. </p>\n\n<p>Your choices are to hack through the files and find the problem, or not use shadowbox. Good luck!</p>\n'}, {'answer_id': 58198, 'author': 'Prestaul', 'author_id': 5628, 'author_profile': 'https://Stackoverflow.com/users/5628', 'pm_score': 3, 'selected': True, 'text': '<p>The best option is to disable keyboard navigation shortcuts in the shadowbox by setting the "enableKeys" option to false (see <a href="http://mjijackson.com/shadowbox/doc/api.html" rel="nofollow noreferrer">this page</a>).</p>\n\n<p>Alternatively you could do what Robby suggests and modify the shadowbox.js file, <strong>but only do this if you need to have the shadowbox keyboard navigation</strong>. I think that you want to search for this block of code and modify it so that it only cancels the default event if one of the shortcuts is used (I\'ve added some line breaks and indention):</p>\n\n<pre><code>var handleKey=function(e){\n    var code=SL.keyCode(e);\n    SL.preventDefault(e);\n    if(code==81||code==88||code==27){\n        SB.close()\n    }else{\n        if(code==37){\n            SB.previous()\n        }else{\n            if(code==39){\n                SB.next()\n            }else{\n                if(code==32){\n                    SB[(typeof slide_timer=="number"?"pause":"play")]()\n                }\n            }\n        }\n    }\n};\n</code></pre>\n\n<p>I think you could change it to look more like this:</p>\n\n<pre><code>var handleKey=function(e){\n    switch(SL.keyCode(e)) {\n        case 81:\n        case 88:\n        case 27:\n            SB.close()\n            SL.preventDefault(e);\n            break;\n\n        case 37:\n            SB.previous()\n            SL.preventDefault(e);\n            break;\n\n        case 39:\n            SB.next()\n            SL.preventDefault(e);\n            break;\n\n        case 32:\n            SB[(typeof slide_timer=="number"?"pause":"play")]()\n            SL.preventDefault(e);\n            break;\n    }\n};\n</code></pre>\n\n<p>This should prevent the shadowbox event handler from swallowing any keystrokes that it doesn\'t care about.</p>\n'}, {'answer_id': 1472998, 'author': 'Community', 'author_id': -1, 'author_profile': 'https://Stackoverflow.com/users/-1', 'pm_score': 0, 'selected': False, 'text': "<p>The solution is to set the enableKeys option to false.  However, this doesn't seem to work on an open() call for inline HTML.  It does work, however, if you set it in your init() call.</p>\n"}]
['https://Stackoverflow.com/questions/50115', 'https://Stackoverflow.com', 'https://Stackoverflow.com/users/5234/']