Identifying App Installations
<p>so there a nice blog to Identifying App Installations using the following code</p>

<pre><code>public class Installation {
    private static String sID = null;
    private static final String INSTALLATION = "INSTALLATION";

    public synchronized static String id(Context context) {
        if (sID == null) {  
            File installation = new File(context.getFilesDir(), INSTALLATION);
            try {
                if (!installation.exists())
                    writeInstallationFile(installation);
                sID = readInstallationFile(installation);
            } catch (Exception e) {
                throw new RuntimeException(e);
            }
        }
        return sID;
    }

    private static String readInstallationFile(File installation) throws IOException {
        RandomAccessFile f = new RandomAccessFile(installation, "r");
        byte[] bytes = new byte[(int) f.length()];
        f.readFully(bytes);
        f.close();
        return new String(bytes);
    }

    private static void writeInstallationFile(File installation) throws IOException {
        FileOutputStream out = new FileOutputStream(installation);
        String id = UUID.randomUUID().toString();
        out.write(id.getBytes());
        out.close();
    }
}
</code></pre>

<p>in a different java class i have a WebView going to a URL as shown</p>

<pre><code>public class Notes extends Activity {

    WebView mWebView;

    /** Called when the activity is first created. */
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.timsnotes);

        mWebView = (WebView) findViewById(R.id.webview3);
        mWebView.getSettings().setJavaScriptEnabled(true);
        mWebView.loadUrl("http://www.somedomain.com/notes.php?phoneid=" + "sID" + "");
        mWebView.setWebViewClient(new HelloWebViewClient());
    }
</code></pre>

<p>but all it passes is the text sID. is there a uses-permission I'm missing to access the sID?</p>
