﻿<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Just A Programmer &#187; php</title>
	<atom:link href="http://www.justaprogrammer.net/tag/php/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.justaprogrammer.net</link>
	<description>We're Just Programmers...</description>
	<lastBuildDate>Sat, 03 Jul 2010 17:15:45 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Trouble building PHP on Windows</title>
		<link>http://www.justaprogrammer.net/2010/01/17/microsoft-wont-tell-zend-how-to-build-php/</link>
		<comments>http://www.justaprogrammer.net/2010/01/17/microsoft-wont-tell-zend-how-to-build-php/#comments</comments>
		<pubDate>Sun, 17 Jan 2010 20:14:54 +0000</pubDate>
		<dc:creator>Justin</dc:creator>
				<category><![CDATA[Just A Programmer]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[OSS]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[Zend]]></category>

		<guid isPermaLink="false">http://www.justaprogrammer.net/?p=75</guid>
		<description><![CDATA[Update: It seems that the facts presented to me in the initial bug report are not correct. I will be revising this article after the facts are settled. For now read the comments. It all started with a simple bug encountered while trying to get PHP and WCF to play nice. Before you know it [...]]]></description>
			<content:encoded><![CDATA[
<div class="topsy_widget_data topsy_theme_blue" style="float: right;margin-left: 0.75em; background: url(data:,%7B%20%22url%22%3A%20%22http%253A%252F%252Fwww.justaprogrammer.net%252F2010%252F01%252F17%252Fmicrosoft-wont-tell-zend-how-to-build-php%252F%22%2C%20%22style%22%3A%20%22big%22%2C%20%22title%22%3A%20%22Trouble%20building%20PHP%20on%20Windows%22%20%7D);"></div>
<p><strong>Update:</strong> It seems that the facts presented to me in the initial bug report are not correct. I will be revising this article after the facts are settled. For now read the comments.</p>
<p>It all started with a <a href="http://bugs.php.net/bug.php?id=50698">simple bug</a> encountered while <a href="http://stackoverflow.com/questions/1933213/connecting-to-a-wcf-service-in-php-that-has-a-a-nettcp-binding-and-a-basichttpbin">trying to get PHP and WCF to play nice</a>. Before you know it I was attempting to compile PHP on windows myself. That&#8217;s when I realized how deep the rabbit hole really goes.</p>
<p>These days I program in PHP and .NET for a living. In a past life I was a unix admin for small ISP where most of the internal unix infrastructure was FreeBSD while the managed customers tended to run Redhat.  Due to the unique path of my IT career, I usually don&#8217;t have a problem compiling open source software primarily targeted for unix on windows. PHP has proven to be a bit of an exception. However, with a little struggle, I got it to compile.</p>
<p>In this case the crux of the struggle was not a lack of documentation, but documentation outdated to the point of being wrong. This is perhaps the one exception to the rule postulated by Dick Brandon, &#8220;Documentation is like sex . . . when it is good, it is very, very good; and when it is bad, it is better than nothing.&#8221; Thankfully, <a href="http://blog.thepimp.net/">Pierre</a> of <a href="http://www.libgd.org/Main_Page">libgd</a> fame <a href="http://marc.info/?l=php-windows&amp;m=126333358531362&amp;w=2">pointed me in the right direction</a> on the mailing list. So being a good netizen, I submitted a <a href="http://bugs.php.net/bug.php?id=50779">bug report</a> so that someone with commit access to the php source repo could straighten the mess out. This was the response I received:</p>
<blockquote><p><span style="color: #333399;"> We don&#8217;t understand the build requirements or system.</span></p>
<p><span style="color: #333399;">You have to ask the Microsoft guys to update that file.<br />
<a rel="nofollow" href="http://no.php.net/manual/en/install.windows.building.php">http://no.php.net/manual/en/install.windows.building.php</a> was one of our<br />
best Windows know-how (not-microsoft-employee) guy shot at documenting<br />
the process, but the feedback he got from Microsoft employees was &#8220;this<br />
is crap. its all wrong&#8221;.</span></p>
<p><span style="color: #333399;">Sorry, we simply do not know how to do this. </span></p></blockquote>
<p>That was a little disheartening. I asked them to mark the readme file as outdated, and I asked them how to contact Microsoft. This was the response I received:</p>
<blockquote><p><span style="color: #333399;"> Updated the file to say its outdated.</span></p>
<p><span style="color: #333399;">As for contacting the Microsoft guys, try surfing around on<br />

http://windows.php.net</span></p>

<p><span style="color: #333399;">We have tried multiple times to get these docs updated, with no luck so<br />
far, and like I said; our last attempt was shot down and they wanted<br />
those docs to be reverted.</span></p>
<p><span style="color: #333399;"><strong><em>I&#8217;m sorry, you are simply on your own here.</em></strong></span></p></blockquote>
<p>So it seems my only resort is to blog about it and hope someone from Microsoft is in earshot. If you care about PHP on windows, spread the word. Spread this article with twitter, digg, reddit, or just plain old email. If you have the ear of anyone in Microsoft give it a bend. I&#8217;ve never attempted blogger activism like this, but I don&#8217;t know what else to do. I much prefer to fix problems myself than delegating or inspiring. However, this is one case where I need to &#8220;have a little help from my friends.&#8221; I don&#8217;t even know what Microsoft finds wrong with the proposed updates to the documentation, so submitting updated documentation seems pointless.</p>

]]></content:encoded>
			<wfw:commentRss>http://www.justaprogrammer.net/2010/01/17/microsoft-wont-tell-zend-how-to-build-php/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>If you have too much free time, use Java.</title>
		<link>http://www.justaprogrammer.net/2007/12/25/if-you-have-too-much-free-time-use-java/</link>
		<comments>http://www.justaprogrammer.net/2007/12/25/if-you-have-too-much-free-time-use-java/#comments</comments>
		<pubDate>Tue, 25 Dec 2007 20:19:56 +0000</pubDate>
		<dc:creator>Tomaj</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[ide]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.justaprogrammer.net/2007/12/25/if-you-have-too-much-free-time-use-java/</guid>
		<description><![CDATA[Now, I am no superstar programmer, this I admit. However, I do believe I am fairly intelligent, and have a decent breadth of knowledge and ability when it comes not just to programming, but IT as a whole. This weekend, I decided to spend a little time attempting to re-invent an intranet app I created [...]]]></description>
			<content:encoded><![CDATA[
<div class="topsy_widget_data topsy_theme_blue" style="float: right;margin-left: 0.75em; background: url(data:,%7B%20%22url%22%3A%20%22http%253A%252F%252Fwww.justaprogrammer.net%252F2007%252F12%252F25%252Fif-you-have-too-much-free-time-use-java%252F%22%2C%20%22style%22%3A%20%22big%22%2C%20%22title%22%3A%20%22If%20you%20have%20too%20much%20free%20time%2C%20use%20Java.%22%20%7D);"></div>
<p>Now, I am no superstar programmer, this I admit.  However, I do believe I am fairly intelligent, and have a decent breadth of knowledge and ability when it comes not just to programming, but IT as a whole.</p>
<p>This weekend, I decided to spend a little time attempting to re-invent an intranet app I created using Java in Applet form, as opposed to the present PHP/Ajax solution.  To provide a little background, the present application is basically an administrative tool which keeps track of computers &amp; users.  It presents several tables identifying e-mail accounts, Southware users, PCs, and the relationships of these various items to each other.  For now, I use PHP5 with Smarty templating, and use XMLHttpRequest calls to update just certain portions of the page instead of reloading the whole thing each time you want to sort a table, or edit a field.</p>
<p>I am pretty pleasd with the solution thus far, however I like to experiment.  Previously, I tried using Flex &#8212; and did OK until the point that I hit what I believe was a limitation of Flex itself, having to do with binding controls to the gridview and having changes propagate back to the control that the edit controls were bound to.  So this time around, I said to myself &#8220;Hey, I took Java back in college and even did my senior project in that!&#8221;.</p>
<p>Can&#8217;t be too hard right? Taking some data, displaying it on a grid, edits, etc.  Boy was I wrong!</p>
<p><strong>CHALLENGE #1 &#8212; Finding a decent IDE</strong></p>
<p>Good luck!  I tried probably 5 different IDEs, and ditched them all for various reasons &#8212; mostly because they weren&#8217;t free.  Finally I ended up with Netbeans, which I happened upon completely by accident, as I was browsing around Sun&#8217;s website.  It&#8217;s actually a pretty nice IDE.  It has several built in project templates, a drag &amp; drop WYSIWYG designer, code completion, etc.  This IDE also had a cool feature where you can easily set up a JDBC connection to several database servers, in my case PostgreSQL.  I was able to connect, browse around the tables (however, you must have a primary key before any tables can be used!?), and bind the tables to various controls for example a list or a data grid.  I had some problems with the IDE though &#8212; I had a tough time wrestling for control.  It wouldn&#8217;t let me delete function declarations, variables, etc.. They were just simply a different shade of gray, and somehow untouchable.</p>
<p><strong>CHALLENGE #2 &#8212; Getting anything done</strong></p>
<p>Once I had finally gotten everything set up with my little project, I tried to compile it.  UHOH it seems it couldn&#8217;t find javax.persistence.  WTF is that you may ask?  Well, apparently it&#8217;s necessary (at least with this IDE) to bind the database to the control.  After another half an hour of searching, I resigned myself to having to download the enterprise edition of the SDK (100+ megs..) and then trying again.   After that was finally done, I tried to run it again&#8230; It compiled, but now it was giving exceptions on start, and it STILL wouldn&#8217;t work..</p>
<p><strong>CHALLENGE #3 &#8212; Debugging!</strong></p>
<p>There may be a nice quick solution for this (if there is, please let me know).  If you&#8217;re writing an applet you should be debugging in your browser right?  Well if you do, then your browser will cache the Applet, and your subsequent rebuilds will not be represented.. I am using firefox, and to counter this, it is suggested you load up your Tools -&gt; Java Console, and hit &#8216;x&#8217; to clear the java cache.. So I did it. And did it again. And again and again.  NO EFFECT!  I discovered I had to exit firefox in its entirety after clearing the cache, then re-launching, and THEN it would show the new applet.  SO, what kind of way to debug is that??  As I said above, i&#8217;m no superstar.. I like to code a little, then check it. Then code, then check.  I just can&#8217;t work like that.  Yes, you can run the program as a regular application then switch to be an applet, but then you have various security permissions issues which may come back to bite you if you&#8217;re not careful no?</p>
<p>The above may not seem particularly frustrating, but all of this came after several hours of playing around with SOAP.  I had gotten one of the functions of my app set up via SOAP, and was going to test that with java.  I was looking around the web, and all the samples I saw were horrible&#8230; They were hand-crafting the request XML, OR using some 3rd party framework to get the job done.   I didn&#8217;t want to do either of those things, so eventually I gave up on SOAP, and that is when I tried the direct database connection.</p>
<p>In closing, those of you out there who are PROs at Java will read this and laugh &#8212; no problem there.  What should be taken away from this though, is that while Java may be perfectly good once you immerse yourself in the intricacies, it is not for the faint of heart, and in the age of integration, polished languages &amp; IDEs, it&#8217;s just not up to the hype.</p>

]]></content:encoded>
			<wfw:commentRss>http://www.justaprogrammer.net/2007/12/25/if-you-have-too-much-free-time-use-java/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
