title: How do I use cordova inappbrowser to open links in Ionic/Angular hybrid app
body: <p>I am working on a hybrid mobile app using Ionic Framework and AngularJS. I am using Ionic Creator &amp; Ionic Lab. In my app, I have several buttons that link to external resources (webpages, mailto: links, pdf files etc). The links work fine when I test them within the browser (Ionic Lab). However, when I test the app in an Android virtual device or an actual device, none of the links are working.</p>
  
  <p>I found a question where someone had a similar issue:</p>
  
  <pre><code>/questions/33627061/ionic-simple-href-not-working-on-android-device
  </code></pre>
  
  <p>I tried Implementing all the proposed solutions from adding to config.xml:</p>
  
  <pre><code>&lt;allow-navigation href="*" /&gt;
  </code></pre>
  
  <p>Installing cordova inappbrowser plugin via:</p>
  
  <pre><code>$sudo cordova plugin add cordova-plugin-inappbrowser
  </code></pre>
  
  <p>I tried using ng-click="some_function()" instead of href, then defining the function in my controller.</p>
  
  <p>The OP on that question finally resolved his issue by commenting out/uncommenting from index.html:</p>
  
  <pre><code>&lt;!-- cordova script (this will be a 404 during development) --&gt;
  &lt;script src="cordova.js"&gt;&lt;/script&gt;
  </code></pre>
  
  <p>Looking at my browser console logs there was a 404 not found for cordova.js, so I manually added it to www/ from the platform_www/ directory for android, as well as cordova_plugins.js</p>
  
  <p>However after trying all this, the links are still not working. In my consol logs I now get an error saying:</p>
  
  <pre><code>GET http://localhost:8100/plugins/cordova-plugin-inappbrowser/www/inappbrowser.js 404 (Not Found)
  Uncaught Error: Module cordova-plugin-inappbrowser.inappbrowser does not exist. http://localhost:8100/cordova.js Line: 1421
  </code></pre>
  
  <p>But the thing is inappbrowser.js is in that folder!</p>
  
  <p>Please help! I'm at wits end and have no idea what to do next. I have uploaded the sample code I'm working with on github: </p>
  
  <p><a href="https://github.com/chmod-777/link-test" rel="nofollow">https://github.com/chmod-777/link-test</a></p>
  
  <p>Software versions:</p>
  
  <p>Linux mint 17.1
  node v0.12.2
  npm 2.7.4
  cordova 6.2.0
  ionic 1.7.14</p>