Author Archives: Hugo Monteiro

Send file to user using views

There are some simple steps to send a file to the user of your web application using the Play Framework: 1. After the controller is created (what I do is to copy the controller  “Application” and do a refactor rename to the name I want). Create a file named MyController (what I do is to [...]

Posted in Internet, play, Software Development | Tagged , , , , | Leave a comment

Security tips for a web developer

Every web application has two sides. The client side and the server side. Everything on the client side can be changed, and most of the security problems happens when you trust in the client. With a simple proxy (like webscarab) you can edit the fields that were validated using javascript. That’s why you always need [...]

Posted in Internet, play, Software Development | Tagged , , , , | Leave a comment

Leadership Lessons from Dancing Guy

Read transcrip at http://sivers.org/ff . Great Lesson!

Posted in Entrepreneurship | Tagged , , | Leave a comment

Play Framework + Oracle = EASY!

To configure your oracle database using the play framework you need to follow the following steps: Choose the JAR with the drivers according to your oracle’s database version and put in the lib/ directory of your web application Configure your application.conf file,  located inside the conf/ directory In the JPA Configuration Section you have to [...]

Posted in Internet, play, Software Development | Tagged , , , , | 9 Comments

[Play] Iterate over objects using jQuery

What if I want to navigate into each checkbox, radio of my html? You can do it pretty easily using jQuery.each function. In every checkbox element I want to send a post message to my Play Framework. jQuery.each($(‘:checkbox’), function() { $.post(‘@{myPlayMethod()}’, { itemValue: $(this).val() }) }); This code sends the html element value property to [...]

Posted in play | Tagged , , , , | Leave a comment

How to divide your GUI from your processing code?

Many students don’t know how to organize their code. Abstractions and Interfaces makes a difference when developing Java applications. What if your code was divided? For instance, if you have created a network application with a GUI (Graphical User Interface). The first approach is to put the code all together because it’s easier from the beginning. That’s wrong because it’s harder to find an error and you have to read a lot of garbage code like textBox.setValue

Posted in Software Development | Tagged , , , , | Leave a comment

Singleton Design Pattern problems?

The Singleton Pattern ensures a class has only one instance that provides a global point to access it. This design pattern is perfect for maintaining a set of configurations or other variables always available at run-time in your software. public static Singleton getInstance() { if (uniqueInstance == null) { uniqueInstance = new Singleton(); } return [...]

Posted in Software Development | Tagged , , , , | Leave a comment

Entrepreneur, remember what you thought when you were a kid?

Posted in Entrepreneurship | Tagged , , , | Leave a comment

80/20 rule for entrepreneurs

What is the 80/20 rule and why is it so important to entrepreneurs? Wikipedia says: “The principle was suggested by management thinker Joseph M. Juran. It was named after the Italian economist Vilfredo Pareto, who observed that 80% of income in Italy was received by 20% of the Italian population. The assumption is that most [...]

Posted in Entrepreneurship | Tagged , | Leave a comment