<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-8974011404383827712</id><updated>2024-09-04T21:43:57.366-05:00</updated><title type='text'>Produco</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://produco.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8974011404383827712/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://produco.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/01587006355250633948</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>7</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-8974011404383827712.post-2559740425342950441</id><published>2013-02-16T17:28:00.001-06:00</published><updated>2013-02-16T17:28:31.449-06:00</updated><title type='text'>My wish list for changes to US computer science education</title><content type='html'>I am about 3/4 done with my 3rd degree, this one in computer science. I have been thinking for a long time about the value of this particular degree, my former ones, and university education in general. My thinking on the subject was recently crystalized when I was asked by a recruiter for a well respected startup about personal or open sourced projects I have recently done. I barely have time to sleep, but I go to school full-time, and work full-time, so I am an outlier. That got me thinking about the best use of a student&#39;s time, which is to learn and build up their skills and resume to get a job. Then I started thinking about all the dumb classes I had taken in the past, and that I&#39;ll need to take in the near future (Texas history? Really Texas, get over yourself). I have always been a supporter of a liberal arts education, where you are fed tons of diverse material to make you a well rounded citizen. However, my views have recently evolved: the more I think about it, this should be done in high school. By the time you get to college, specially for a technical degree, you should spend 3-4 years taking courses in your field (or those close to it: math, electrical engineering, etc. for CS). Any other time would be better spend working on projects or doing long term internships where you&#39;ll be able to pick up relevant skills for your career. Here are my reasons:&lt;br /&gt;
&lt;br /&gt;
1) Nowadays, any field, specially a technical one, is so massive one can barely get a handle on it during a lifetime, much less 4 years of school where most of your time is spent on &quot;general ed&quot; courses. I think it would be much better for a student to spend their third year working for a company, getting practical skills. Then coming back in their fourth year to build on that experience with more advanced theoretical knowledge.&lt;br /&gt;
&lt;br /&gt;
2) If you didn&#39;t get US history (or Texas history!) in high school, lets fix that. Not teach it for the 3rd time in your life. I took US history in middle school, high school, and college. Same goes for english, lit, or algebra. If you don&#39;t know what is a verb when you get to a top US school, then someone fucked up along the way. BTW, I know my&amp;nbsp;writing&amp;nbsp;sucks, specially my grammar, but I am not getting a BA in Literature, so&amp;nbsp;tough.&lt;br /&gt;
&lt;br /&gt;
3) The distribution of knowledge is being democratized and changed radically by the internet, mobile phones, social networks, and other technologies. 50 years ago, college may have been the first time you heard a particular argument, or met a person from another country, or were exposed to feminism. But today, you could live in the most backwater town, but if you have access to a phone line, a modem, and a fairly decent computer, you&#39;ll have the same access to knowledge as someone living in NY or London. Ideas today spread further, faster. In the olden days, your college professor may be the only expert on a particular field. Now there are a million blogs, articles, and whole websites devoted to a&amp;nbsp;particular&amp;nbsp;topic.&lt;br /&gt;
&lt;br /&gt;
I know this isn&#39;t going to change overnight: there are accreditation organizations, state legislatures, etc, which are filled with liberal arts major. But I think if we tell them they won&#39;t need to take biology, or physics, or any math past algebra anymore they&#39;ll quickly give in. Point being: Texas, don&#39;t make me take Texas history! I get it, the Alamo sucked. David Crockett said &#39;You can go to Hell, I&#39;m goin&#39; to Texas!&#39;. I have the gist of it.</content><link rel='replies' type='application/atom+xml' href='http://produco.blogspot.com/feeds/2559740425342950441/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/8974011404383827712/2559740425342950441' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8974011404383827712/posts/default/2559740425342950441'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8974011404383827712/posts/default/2559740425342950441'/><link rel='alternate' type='text/html' href='http://produco.blogspot.com/2013/02/my-wish-list-for-changes-to-us-computer.html' title='My wish list for changes to US computer science education'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/01587006355250633948</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8974011404383827712.post-8840693329724050440</id><published>2013-02-16T16:49:00.002-06:00</published><updated>2013-02-16T16:49:13.926-06:00</updated><title type='text'>Location Autocomplete for Google Calendar</title><content type='html'>If you use Google Calendar, check this new Chrome &lt;a href=&quot;http://labs.mitro.co/blog/2013/2/16/location-autocomplete-for-google-calendar&quot; target=&quot;_blank&quot;&gt;extension&lt;/a&gt;. It autocompletes your location info when making a new appointment. They use the FourSquare API.&lt;br /&gt;
&lt;br /&gt;
I have always wanted a feature like that, and I don&#39;t know why Google hasn&#39;t built it. But the guys at Mitro Labs did. So kudos to them.</content><link rel='replies' type='application/atom+xml' href='http://produco.blogspot.com/feeds/8840693329724050440/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/8974011404383827712/8840693329724050440' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8974011404383827712/posts/default/8840693329724050440'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8974011404383827712/posts/default/8840693329724050440'/><link rel='alternate' type='text/html' href='http://produco.blogspot.com/2013/02/location-autocomplete-for-google.html' title='Location Autocomplete for Google Calendar'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/01587006355250633948</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8974011404383827712.post-5854681929506210728</id><published>2013-02-02T13:45:00.003-06:00</published><updated>2013-02-02T13:45:53.757-06:00</updated><title type='text'>Advice for college CS recruiters (and others in general)</title><content type='html'>I feel compel to write this for a few reasons:&lt;br /&gt;
&lt;br /&gt;
1) There are tons of great advice for applicants, Steve Yegge instantly comes to mind:&amp;nbsp;&lt;a href=&quot;http://steve-yegge.blogspot.com/2008/03/get-that-job-at-google.html&quot;&gt;http://steve-yegge.blogspot.com/2008/03/get-that-job-at-google.html&lt;/a&gt;,&amp;nbsp;&lt;a href=&quot;https://sites.google.com/site/steveyegge2/five-essential-phone-screen-questions&quot;&gt;https://sites.google.com/site/steveyegge2/five-essential-phone-screen-questions&lt;/a&gt;. However, I feel there is not much written from the opposite perspective (that I have seen).&lt;br /&gt;
&lt;br /&gt;
2) I am older that most every CS undergrad, I have two previous degrees, and I have been to a gazillion interviews with everyone from Google and Amazon to tiny startups in a shack (almost literally a shack).&lt;br /&gt;
&lt;br /&gt;
3) I started a business after college, and I ran a restaurant with 40something employees reporting to me. So I have been on the other side of the table. Granted, looking back, I did not follow all of these rules all the time myself.&lt;br /&gt;
&lt;br /&gt;
I am targeting this to college recruiters looking for interns and entry-level CS grads, but most of it applies to any kind of recruiting.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Rules 1) Be nice, outgoing, and excited about your company&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
I get it, this is the 10th career fair you have been to in the last 3 weeks. In each one, you spend 6 hours standing on your feet, talking to&amp;nbsp;literally&amp;nbsp;hundreds of 20 year olds. I know after all that there is admin work, networking in the school, interviewing candidates, etc, etc. I know it is hard to be excited by the 300th person who tells you they took a compilers class last semester. But, think about it this way: when you go to Chick-fil-A, or McDonalds, the employee in the counter has been standing there for hours. Talking to hundreds of people. Answering the same stupid question about a BigMac having cheese or not, AND after all that, they have to clean the bathroom. Yet, you would be pissed if you got there and they acted like they didn&#39;t care.&lt;br /&gt;
&lt;br /&gt;
Try to have fun with it, don&#39;t ask the same scripted question, be random. Ask candidates why the sky is blue, then you could have some fun listening to all the random answers. You should probably know the &lt;a href=&quot;http://math.ucr.edu/home/baez/physics/General/BlueSky/blue_sky.html&quot; target=&quot;_blank&quot;&gt;answer&lt;/a&gt; if you are going to take that strategy.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Rule 1.1) Don&#39;t be a douche&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
I know you are a Senior Developer at XYZ company, one of the most&amp;nbsp;prestigious&amp;nbsp;young tech companies with massive growth, and you 3 software patents. You should still be nice,&amp;nbsp;courteous&amp;nbsp; and friendly. I have meet people from Google or Amazon, who have masters from Stanford, and who make an effort seem interested in the 1 billionth candidates. Then there are people in companies, which I &amp;nbsp;am ambivalent or neutral about working for, who act like the simple generic question I ask them is dumb, and a waste of their time. Maybe you are trying to get something done at work, and your boss keeps asking you to do career fairs, or interviews, and you think this is a waste of your time. Maybe you like working for assholish companies to feed some ego issues because daddy didn&#39;t go to your baseball games. Or maybe you want to get hired there to be assholish to the next round of potential employees. I don&#39;t know, just cut it out. I don&#39;t know about other people, but if on one hand I get an offer from a Facebook. And I felt all their employees were assholes. And on the other hand I got an offer from some nameless technology company, but they went out of their way to be nice and friendly, guess where I would work? We are all going to die soon, I rather have fun and enjoy my workplace, as opposed to suffer just to get someone&#39;s name in my resume.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Rule 2) Communicate in a timely manner&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
I know if I fill out the online application at Google, someone is not going to send me a personalized e-mail. I am probably not even going to get a form e-mail in case no one looks at my resume. But, if I interview with your company, be prompt with a response, 2 to 3 weeks should be the latest. And for God&#39;s sake, if you don&#39;t select me, let me know. I am not expecting a phone call, just send me an automated &quot;we are going to move forward with other candidates&quot; e-mail. I have crunched my numbers: out of 10 companies I talked to, I normally get interview offers with 2 to 4 of them, and maybe one will make me an offer. Not getting hired is not going to crush me, but just cutting all communication is assholish (see above). There is a big, local, tech company who interviewed me when I first got back to school. I had no software experience. They did not select me. I e-mailed both the interviewer and the HR rep, no one ever got back to me, ever, not even a form e-mail. Now, I see their postings for Android developers, in which I now have professional experience. Am I going to apply there, or even consider them if they reached out? Hells no.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Rule 3) At least have one developer/engineer&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
I have talked to companies who only have an HR rep. They literally don&#39;t know what technologies are in their products.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Rule 4) Ask technical questions, more than one&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
I have been interviewed for engineering positions where no one asked a technical question. Not even &quot;sum to 10 in a for loop.&quot; Or they ask something like that, and nothing else. This makes me feel like the quality of their employees is not very high, since they just offered me a job without knowing if I can actually code anything. But also, be flexible, I know some brilliant people who freeze under pressure, but could probably hack your corporate network at 2am with enough red bull. Maybe if someone is promising, give them a harder problem to solve at home, with 3 days time, or whatever. I think the way someone writes code tells me more about their abilities as an engineer than knowing if they can enumerate every class and interface in Java Collections.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Rule 5) Don&#39;t try to short change people in your offer&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
I know it sucks, it is 2013, and you need a mobile developer with 1 to 2 years of experience. You are not going to get one for 40% below market value. Know what the position pays and offer that. Don&#39;t make me have to negotiate your low ball offer. I have turned down offers because I didn&#39;t feel like negotiating your BS offer. I know I am generalizing. If you are a startup, I know you can&#39;t pay someone out of college 6 figures like one of the big boys. I know there are tons of intangibles about working in certain types of companies or jobs: you get to make more of an impact at a startup, there is the possibility of a much bigger payoff in the long run if your company is not public, you will have more opportunities for a promotions in the 10K employee company than the 400K one. But if you have 3,000 employees and you make BS enterprise software, don&#39;t offer $50K for an $80K position. You are going to get exactly what you pay for, and you&#39;ll keep making BS enterprise software.&lt;br /&gt;
&lt;br /&gt;
Let me know if I missed a big one.</content><link rel='replies' type='application/atom+xml' href='http://produco.blogspot.com/feeds/5854681929506210728/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/8974011404383827712/5854681929506210728' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8974011404383827712/posts/default/5854681929506210728'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8974011404383827712/posts/default/5854681929506210728'/><link rel='alternate' type='text/html' href='http://produco.blogspot.com/2013/02/advice-for-college-cs-recruiters-and.html' title='Advice for college CS recruiters (and others in general)'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/01587006355250633948</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8974011404383827712.post-3954351592872184408</id><published>2013-02-02T10:43:00.000-06:00</published><updated>2013-02-02T10:43:01.564-06:00</updated><title type='text'>Code formatting for Blogger</title><content type='html'>I had been looking for an easy way to format my code examples here. I tried several solutions. Some did not work at all, others required me to hack the Blogger templates, then remember all these formatting variables. Today I ran into a cool solution that is easy breezy:&amp;nbsp;&lt;a href=&quot;http://formatmysourcecode.blogspot.com/&quot;&gt;http://formatmysourcecode.blogspot.com&lt;/a&gt;. You just paste your code and then copy-paste into your blog.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://produco.blogspot.com/feeds/3954351592872184408/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/8974011404383827712/3954351592872184408' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8974011404383827712/posts/default/3954351592872184408'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8974011404383827712/posts/default/3954351592872184408'/><link rel='alternate' type='text/html' href='http://produco.blogspot.com/2013/02/code-formatting-for-blogger.html' title='Code formatting for Blogger'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/01587006355250633948</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8974011404383827712.post-1133887271389384985</id><published>2013-02-02T10:38:00.003-06:00</published><updated>2013-02-02T10:38:46.442-06:00</updated><title type='text'>Reading server response using HttpURLConnection</title><content type='html'>I have been working on a project with tons of networking. Everything was going well, then I had to read a huge XML file being returned from the server. I implemented&amp;nbsp;the&amp;nbsp;HttpURLConnection class according to most of the code you&#39;ll find online:&lt;br /&gt;
&lt;br /&gt;
&lt;pre style=&quot;background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;&quot;&gt;&lt;code&gt;InputStream response = connection.getInputStream();

BufferedReader reader = new BufferedReader(new InputStreamReader(response));

String line = &quot;&quot;;

while ((line = reader.readLine()) != null) {

    serverResponseMessage += line;

}

response.close()
&lt;/code&gt;&lt;/pre&gt;
&lt;br /&gt;
However, this was taking more than 2 minutes to download. When I looked at the Android LogCat, I would see all the lines being parsed, so it was receiving the data quickly, but it was spending 2 minutes in that while loop. I spent hours trying to first figure out the time issue was due to the while loop, then looking for a better solution. I could not find a solution anywhere, in fact the Android HttpURLConnection docs give examples using BufferedReader. Finally, I decided to parse it using a a byte array buffer. This cut the time to parse the same exact data to less than 5 seconds, a huge improvement. I am not sure why the BufferedReader implementation gives such an inferior performance.&lt;br /&gt;
&lt;br /&gt;
&lt;pre style=&quot;background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;&quot;&gt;&lt;code&gt;InputStream response = connection.getInputStream();

ByteArrayBuffer baf = new ByteArrayBuffer(50);
            
int bytesRead = -1;
byte[] buffer = new byte[1024];
while ((bytesRead = response.read(buffer)) &amp;gt;= 0) {
    // process the buffer, &quot;bytesRead&quot; have been read, no more, no less
    baf.append(buffer, 0, bytesRead);
}
response.close();
&lt;/code&gt;&lt;/pre&gt;
&lt;br /&gt;
This cut the time to parse the exact same data to less than 5 seconds, a huge improvement. I am not sure why the BufferedReader implementation gives such an inferior performance.</content><link rel='replies' type='application/atom+xml' href='http://produco.blogspot.com/feeds/1133887271389384985/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/8974011404383827712/1133887271389384985' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8974011404383827712/posts/default/1133887271389384985'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8974011404383827712/posts/default/1133887271389384985'/><link rel='alternate' type='text/html' href='http://produco.blogspot.com/2013/02/reading-server-response-using.html' title='Reading server response using HttpURLConnection'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/01587006355250633948</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8974011404383827712.post-5045502590315095399</id><published>2013-01-07T13:37:00.001-06:00</published><updated>2013-02-10T13:33:58.207-06:00</updated><title type='text'>Opening external links inside an IBM Worklight Android app</title><content type='html'>Recently, I wrote a &lt;a href=&quot;http://produco.blogspot.com/2013/01/opening-external-links-inside-ibm.html&quot; target=&quot;_blank&quot;&gt;post detailing how to add the PhoneGap plugin ChildBrowser to a Worklight iOS app&lt;/a&gt;. Here, I will follow up with the steps I took to add a ChilBrowser to the Android version of the app. I am using the WL 5.0.5 plugin for Eclipse Indigo Java EE.&lt;br /&gt;
&lt;br /&gt;
1) Simon MacDonald&#39;s post: &lt;a href=&quot;http://simonmacdonald.blogspot.com/2011/05/installing-childbrowser-plugin-on.html&quot;&gt;http://simonmacdonald.blogspot.com/2011/05/installing-childbrowser-plugin-on.html&lt;/a&gt;&amp;nbsp;was a great reference. As well as &lt;a href=&quot;https://github.com/phonegap/phonegap-plugins/tree/master/Android/ChildBrowser&quot; target=&quot;_blank&quot;&gt;README&lt;/a&gt; file for the plugin in GitHub.&lt;br /&gt;
&lt;br /&gt;
2) Download the plugin from the GitHub referenced in step 1. I am using the one in folder 2.0.0.&lt;br /&gt;
&lt;br /&gt;
3) I am assuming you know how to add the Android&amp;nbsp;environment&amp;nbsp;to your project and hit &quot;Run As &amp;gt; Build All and Deploy&quot; to get the Android project dumped into your workspace.&lt;br /&gt;
&lt;br /&gt;
4) Add the Package &quot;com.phonegap.plugins.childBrowser&quot; and drop the ChildBrowser.java file.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjvHSIIJY5aPRQ3-XZeWp4MPc7jronq62jdePuBj2WXAnVg5OAL4_pv4LrubB2daP8Dg519msthJLGe72uHYHq7m92f8rUGZeZUTQ0s_LaIba64-Sagq1Z7iyPvBibfWXlS5ECmOoqQ548r/s1600/Screen+Shot+2013-01-07+at+1.08.48+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjvHSIIJY5aPRQ3-XZeWp4MPc7jronq62jdePuBj2WXAnVg5OAL4_pv4LrubB2daP8Dg519msthJLGe72uHYHq7m92f8rUGZeZUTQ0s_LaIba64-Sagq1Z7iyPvBibfWXlS5ECmOoqQ548r/s320/Screen+Shot+2013-01-07+at+1.08.48+PM.png&quot; width=&quot;233&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
5) In your WL app drop the &quot;childbrowser&quot; folder with images under the &quot;www&quot; file in the plugin&amp;nbsp;hierarchy&amp;nbsp;in your &quot;WL project/apps/WL app/android/images&quot; folder. If you don&#39;t have an images folder, create one. Then add the &quot;childbrowser.js&quot; file in the&amp;nbsp;&quot;WL project/apps/WL app/android/js&quot; folder.&amp;nbsp;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEihUGDQnpxmyofcFiS8InTXmI32LuOx-BqiUHLTjEH-KE1_FUz3PjfjRlIInvQOOpTNbk2hIQ8Aymh6Ur1kSQigFyaHVEEhtlmAxt6qyHIunfOsMYQJ9r5dTCFcIoil91jnjEvMR3AEEinH/s1600/Screen+Shot+2013-01-07+at+1.12.29+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;320&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEihUGDQnpxmyofcFiS8InTXmI32LuOx-BqiUHLTjEH-KE1_FUz3PjfjRlIInvQOOpTNbk2hIQ8Aymh6Ur1kSQigFyaHVEEhtlmAxt6qyHIunfOsMYQJ9r5dTCFcIoil91jnjEvMR3AEEinH/s320/Screen+Shot+2013-01-07+at+1.12.29+PM.png&quot; width=&quot;146&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
6) In your Android project, go edit the &quot;res/xml/config.xml&quot; file by adding &quot;&lt;span class=&quot;s1&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;plugin&lt;/span&gt;&lt;span class=&quot;s3&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s4&quot;&gt;name&lt;/span&gt;&lt;span class=&quot;s3&quot;&gt;=&lt;/span&gt;&quot;ChildBrowser&quot;&lt;span class=&quot;s3&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s4&quot;&gt;value&lt;/span&gt;&lt;span class=&quot;s3&quot;&gt;=&lt;/span&gt;&quot;com.phonegap.plugins.childBrowser.ChildBrowser&quot;&lt;span class=&quot;s1&quot;&gt;/&amp;gt;&quot; inside your plugins tags.&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;span class=&quot;s1&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiK2IbJomYQ7FaRzdTlOYdfhzTC99L_iSLkF4wzS_oKyFYxpl-ujJZLo0g45Lu8QjttQ5LIoV0LroeDSDYzhoznssYGG5vP3_UG2G9Cu0nLzHCC24LBC0zOVckcz-CFC9ieR6jLp8yj2id5/s1600/Screen+Shot+2013-01-07+at+1.15.45+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;123&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiK2IbJomYQ7FaRzdTlOYdfhzTC99L_iSLkF4wzS_oKyFYxpl-ujJZLo0g45Lu8QjttQ5LIoV0LroeDSDYzhoznssYGG5vP3_UG2G9Cu0nLzHCC24LBC0zOVckcz-CFC9ieR6jLp8yj2id5/s320/Screen+Shot+2013-01-07+at+1.15.45+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;span class=&quot;s1&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
7) In your AndroidManifest.xml add inside your application tag:&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&gt;
&lt;/div&gt;
&lt;pre style=&quot;background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;&quot;&gt;&lt;code&gt; &amp;lt;activity android:label=&quot;@string/app_name&quot; android:name=&quot;com.phonegap.DroidGap&quot;&amp;gt;
         &amp;lt;intent-filter&amp;gt;
         &amp;lt;/intent-filter&amp;gt;
 &amp;lt;/activity&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&gt;
8) Finally, inside your&amp;nbsp;&quot;WL project/apps/WL app/common/filename.html&quot; file add the reference to the childbrowser.js file. I added to the end of the generated html below the other libraries WL adds:&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both;&quot;&gt;
&lt;/div&gt;
&lt;pre style=&quot;background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;&quot;&gt;&lt;code&gt;function wlEnvInit(){
    wlCommonInit();
    // Environment initialization code goes here       
    document.onclick=manageLinks;
}

function manageLinks(event) {
      var link = event.target;
      //go up the family tree until we find the A tag
      while (link &amp;amp;&amp;amp; link.tagName != &#39;A&#39;) {
               link = link.parentNode;
      }
      
       if (link) {
            var url = link.href;
            var linkIsExternal = ((url.indexOf(&#39;http://&#39;) == 0) || (url.indexOf(&#39;https://&#39;) == 0));
            
            if (linkIsExternal) {
                    console.log(&quot;External Link!&quot;);
                   //open inside ChildBrowser;
                   window.plugins.childBrowser.showWebPage(url,{showLocationBar: true, showNavigationBar: true, showAddress: true});
                   return false;
            }
        }

        return true;
}
&lt;/code&gt;&lt;/pre&gt;
&lt;br /&gt;
I hope it helps!&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://produco.blogspot.com/feeds/5045502590315095399/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/8974011404383827712/5045502590315095399' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8974011404383827712/posts/default/5045502590315095399'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8974011404383827712/posts/default/5045502590315095399'/><link rel='alternate' type='text/html' href='http://produco.blogspot.com/2013/01/opening-external-links-inside-ibm_7.html' title='Opening external links inside an IBM Worklight Android app'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/01587006355250633948</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjvHSIIJY5aPRQ3-XZeWp4MPc7jronq62jdePuBj2WXAnVg5OAL4_pv4LrubB2daP8Dg519msthJLGe72uHYHq7m92f8rUGZeZUTQ0s_LaIba64-Sagq1Z7iyPvBibfWXlS5ECmOoqQ548r/s72-c/Screen+Shot+2013-01-07+at+1.08.48+PM.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8974011404383827712.post-2434637032868872248</id><published>2013-01-06T17:29:00.000-06:00</published><updated>2013-02-10T13:36:04.875-06:00</updated><title type='text'>Opening external links inside an IBM Worklight iOS app</title><content type='html'>I am working on an &lt;a href=&quot;http://www-01.ibm.com/software/mobile-solutions/worklight/&quot;&gt;IBM Worklight&lt;/a&gt; project. We have an all in one app: web, iOS, Android. Since Worklight is an HTML/JS/CSS framework, you basically build a web app that gets dropped inside a webview for the mobile platforms. We have links inside this app. But when you click inside the native mobile app, it opens a link in the platform&#39;s browser. Which is not an ideal situation. I recently finished implementing the &lt;a href=&quot;https://github.com/phonegap/phonegap-plugins/tree/master/iOS/ChildBrowser&quot;&gt;PhoneGap Childbrowser&lt;/a&gt; plugin for the iOS app to open external links inside the app. PhoneGap plugin, for Worklight? Yes, Worklight is built on the &lt;a href=&quot;http://cordova.apache.org/&quot;&gt;Cordova&lt;/a&gt; project, which the open-source version of Adobe PhoneGap. Below are the steps I took:&lt;br /&gt;
&lt;br /&gt;
1) Follow the instructions in&amp;nbsp;http://moduscreate.com/opening-all-urls-with-phonegaps-childbrowser-plugin/ to install the plugin.&lt;br /&gt;
&lt;br /&gt;
Of the two guides listed in this page to install the plugin, I found&amp;nbsp;http://blog.digitalbackcountry.com/2012/03/installing-the-childbrowser-plugin-for-ios-with-phonegapcordova-1-5/ to be much better. The guide worked for Cordova 2.2. When installing it according to those instructions, just drop the ChildBrowser.js file inside your project/app/iphone or ipad/js folder. Also, ignore the JS stuff. Just drop the file.&lt;br /&gt;
&lt;br /&gt;
2) In step #4, copy the code as shown, but I made a couple of changes:&lt;br /&gt;
&lt;br /&gt;
- I commented out the [theWebView sizeToFit] since it was preventing scrolling when you returned from the outside link.&lt;br /&gt;
&lt;br /&gt;
I also changed the &quot;childBrowser.modalPresentationStyle = UIModalPresentationFormSheet;&quot; to &quot;childBrowser.modalPresentationStyle = UIModalPresentationFullScreen;&quot; to have the UIWebView take up the whole screen in the iPad.&lt;br /&gt;
&lt;br /&gt;
3) Finally, inside the ChildBrowserViewController.m file I edited the last 3 methods to allow to rotation:&lt;br /&gt;
&lt;br /&gt;
&lt;pre style=&quot;background-color: #eeeeee; border: 1px dashed #999999; color: black; font-family: Andale Mono, Lucida Console, Monaco, fixed, monospace; font-size: 12px; line-height: 14px; overflow: auto; padding: 5px; width: 100%;&quot;&gt;&lt;code&gt;#pragma mark CDVOrientationDelegate
- (BOOL)shouldAutorotate
{
    return YES;
}

- (NSUInteger)supportedInterfaceOrientations
{
    return UIInterfaceOrientationMaskAll;
}

- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
    return YES;
}
&lt;/code&gt;&lt;/pre&gt;
</content><link rel='replies' type='application/atom+xml' href='http://produco.blogspot.com/feeds/2434637032868872248/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/8974011404383827712/2434637032868872248' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8974011404383827712/posts/default/2434637032868872248'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8974011404383827712/posts/default/2434637032868872248'/><link rel='alternate' type='text/html' href='http://produco.blogspot.com/2013/01/opening-external-links-inside-ibm.html' title='Opening external links inside an IBM Worklight iOS app'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/01587006355250633948</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>