I\'m getting this error:
extensions::lastError:133 Unchecked runtime.lastError while running tabs.executeScript: Cannot access contents of url \"data:text/html,c
Indeed, the "Offline" page, or any other error page shown is treated as a Chrome internal page instead of its "original" URL. As such, you can't inject into such pages to change them for security reasons. Imagine for a moment that an extension would be able to interact with SSL warning pages - you really, really don't want that.
If your goal is to provide some sort of alternative error page, you need to hook a listener for such navigation errors and redirect to your own page.
I would recommend looking at webNavigation
and webRequest
API.