Netbeans, PHP and "Fest"s
The project I'd talked about a couple of blog posts earlier, was, if you had a look, for managing what are popularly called "fests" (or festivals) in India. A college organizes a few days of competition on various topics, and invites other colleges to participate in the same. My project would've helped institutes out with the same, including the fest's website, and administration. Trouble is, it didn't quite turn out that way... It turns out, our university's server only supports PHP, and not JSP. That support is currently underway, after our departement requested it... Since I was part of the team in-charge of the fest website, I began work on PHP. Boring to do it again, but someone's gotta do it...
Since Netbeans 6.5, released late last year has support for PHP, I decided to give it a try. Another team member prepared the CSS, and a couple of sample pages, and then I got cracking on it. I usually use Notepad++ for PHP, and WAMP, since Internet Explorer is still the numero uno browser out there... Netbeans read the application my friend had made thus far easily... Also, since the WAMP server was in another directory, Netbeans readily volunteered to copy the files to the server, without the metadata Netbeans needs, of course.
Since I'd already worked with JSP in Netbeans, it didn't require much effort to learn the tool. All the features that I wanted were there... syntax highlighting, pop-up documentation, automatic code completion, etc. I found myself using source formatting again and again. Correction of code was easier too. Creating a template came in handy, in order to get all those PHP includes out of the way as a soon as I create a document.
There are some features that I never used though... CSS Preview, Javascript debugging, and the PHP debugger. Call me an old dog, but I'm used to debugging PHP code the conventional way, type it out on the screen. There wasn't a lot of it anyways. During deployment, I just copied the folder from the local server, to our university server. Since the university server's Solaris, I got a few errors I didn't account for. The slashes in a couple of pages were the other way around, so didn't work on Solaris (I know, beginner's mistake...) The GD library wasn't available, so had to use a script that got around that problem. The server had caching enabled, and that created a lot of problems for editing on the server itself. I'll try to verify it on my OpenSolaris installation on Virtualbox, but then the operating versions might differ, but still better than nothing...
That's not Netbeans' issue though. Overall, Netbeans did help to make it smoother, and I'll use it next time too. And, in case you want to visit the website itself, please go on ahead. The fest is called Sankalan :) Do attend if you can!
Posted at 12:35AM Jan 20, 2009 by Aadhar Mittal in Personal | Comments[2]
Creating a project on Java.net
Some of the students at my institute wanted to create projects at Java.net, the website for open-source projects related to java, created by Sun Microsystems. These would be for the India-specific competition, Code for Freedom, where each team of participant(s) has to create an application using at least 3 of Sun's open-source offerings.
After the results of the last competition, where both participants from our institute won 2nd prizes in their respective categories, I don't blame them! We were the only institute from the world to do so, which raises expectations too I guess. After walking a couple of them through the process, I figured it'd just be easier to write a blog post about it. So here we go.
1. Visit java.net
2. Register at the site, and log into your newly created account.
3. Request a project by clicking on the link in the left-hand side toolbar. Use the information available on the Creating a new project help page in order to fill out the forms.
4. After creation, you will be taken directly to your project page, and it will also be listed on the "My pages" page.
5. You can watch the members list of the project, and add more members to the project (after the project has been approved) by clicking on the link given under the title "Participation".
6. Under downloads, you can access the Docs and Files section, and add new files and folders. The documentation goes here.
7. The code, requires access to a repository. For those who don't know what that is, understand that for projects that require teams and versions to be maintained over time (all open-source software?), you need a revision control system. I'll let wikipedia explain the rest. The ones java.net uses are Subversion, and on request, CVS. If you use Netbeans, you can find a tutorial here in order to accomplish the same. Don't forget to download Subversion first though, from the Netbeans-suggested site or the origin. If you don't use Netbeans, and are on Windows, I'd recommend downloading TortoiseSVN and learning how to use it. For other systems, you can download subversion, and search for a third-party client or find out the commands. If you have taken all the steps above, your project should have been successfully uploaded.
You can drop me the new project's link when you do :)
Posted at 03:40AM Jan 13, 2009 by Aadhar Mittal in Personal | Comments[3]