Search This Blog

Thursday, September 30, 2010

Pernikahan Risty Tagor - Rifky Balweel

Gosip pernikahan risty tagor dan rifky balweel kini sedang heboh dibicarakan, ada gosip yang mengatakan bahwa risty tagor telah berbadan dua sehingga pasangan muda ini nekat menikah muda. namun rifky balweel membantah isu tak sedap itu, rencananya pernikahan yang telah 2 bulan di rencanakan oleh pasangan artis ini akan digelar tanggal 2 Oktober 2010, di Graha Pinang, Pondok Pinang, Jakarta

Heidi Klum Video Hot | Single terbaru Seal Download

Heidi klum akan menjadi model video klip sang suami seal untuk single terbarunya. dalam video klip single terbaru seal heidi klum akan berpose bugil alias telanjang. penasaran kan ingin lihat aksi hot heidi klum di single terbaru seal? tentunya tidak sepenuhnya polos. heidi klum yang akan tampil bugil di video klip suami nya seal akan menutupi tubuh mereka dengan bed cover atau selimut. hmm

Gosip pernikahan Happy Salma

Happy salma kabarnya akan segera menikah dengan keturunan raja dan akan memeluk agama hindu, entah kabar pernikahan happy salma ini benar atau tidak. setidaknya foto pernikahan happy salma belum beredar. Artis seksi Happy Salma akan menikah dengan kekasihnya asal Bali, Tjokorda Bagus pada 3 Oktober mendatang. Menikahi Tjokorda Bagus yang keturunan raja, Happy pun dikabarkan sudah menjalani

Tuesday, September 28, 2010

Pernikahan Giring Nidji Chyntia Foto

Foto pernikahan giring nidji dan chyntia sedang dicari banyak orang, banyak juga orang yang bertanya tanya apa alasan giring menikah diam diam dengan chyntia, sehingga timbul gossip bahwa chyntia telah berbadan dua. Foto pernikahan giring nidji dan chyntia yang dilangsungkan sebelum ramadhan 2010 hingga kini belum kami dapatkan, barusan di situs detikhot terdapat foto terbaru giring nidji pasca

Jenny Cortez Mundur dari Glow Management

Jenny cortez dikabarkan akan mundur dari Glow management dan kabarnya juga jenny cortez di denda sebesar 70 juta rupiah karena ketahuan menerima job di luar glow management. Artis yang terkenal hot dan seksi yang pernah menjadi pemberitaan akibat foto ciuman jenny cortez ini kini semakin menambah gossip jenny cortez. berikut berita lengkap mengenai jenny cortez dan juga perseteruannya dengan glow

Friday, September 24, 2010

My Splint

I have been wearing my splint for sometime now and it still doesn't feel comfortable. I wear it 24hours a day and take it off only when i have to eat or drink something other than water. Im still not at ease wearing it, so when I got out publicly i take it off. Its kinda big of a splint so it really shows in my mouth when I talk or even if I don't. Something is just noticeable because it changes my face contour. Anyway, gotta go..

Sunday, September 19, 2010

Tokek Belang Sinta Jojo Download

Tokek Belang adalah judul lagu yang akan dibawakan oleh sinta jojo si keong racun yang akibat aksi lip sync nya di youtube meraih ketenaran, kini sinta dan jojo langung menjelma menjadi artis dadakan, Selain membintangi iklan Sosis So nice dengan gaya lip sybc mereka, kini duo keong racun sinta dan jojo akan menjadi penyanyi betulan loh.


Charlie ST 12 pimpinan MPC alias Manajemen Pangeran Cinta

Zul Zivilia Paksa Istri jadi PSK

Zul Zivilia Pernah memaksa dan menyuruh istrinya untuk menjadi PSK alias Pelacur, selain itu zul zivilia juga pernah mengaku dirinya jomblo dan tidak mengakui keberadaan Fhilia Rahayu Ningsih. Vokalis band Zivilia yang bernama Zulkifli ini kini sedang tersandung kasus KDRT. Istri dari Zul zivilia Fhilia mengaku bahwa dirinya pernah disuruh jadi tukang pijit plus plus oleh zul. Pengakuan Fhilia

Gosip Rianti Cartwright Menikah

Rianti Cartwright menikah? ada gosip terbaru mengenai rianti cartwright si cantik pemeran aisyah dalam ayat ayat cinta ini yang kabarnya menjadi kandidat kuat pengganti Luna maya sebagai Model sabun Lux, kabarnya Rianti Cartwright menikah di amerika dengan kekasihnya Alfonso Nainggolan alias Cas di Amerika Serikat 17 September kemarin, Namun hingga kini belum ada pernyataan resmi dari rianti

Friday, September 17, 2010

Qory Sandioriva Kabur Dari Lokasi Pemotretan

Kabar kalau dirinya bakal dijemput paksa oleh ibunya membuat Putri Indonesia 2009, Qory Sandioriva kabur. Dia pun membatalkan sesi pemotretan yang sudah dijadwalkan Jumat (17/9/2010). Entah apa yang sebenarnya terjadi dengan puteri indonesia 2009 Qory Sandioriva ini, Semakin hari tingkahnya makin aneh saja, Kini qory kerap bersemedi dan membakar dupa hingga muncul dugaan bahwa kini Qory

Thursday, September 16, 2010

Video Joged Bumbung Bali

Video Joged Bumbung erotis kini tengah mewarnai bali dan menggoyang bali, video yang menampilkan aksi erotis penari dengan pakaian khas bali itu dianggap mencemari budaya bali. Aslinya Joged Bumbung adalah tari pergaulan di bali yang dilakukan oleh penari wanita dan mengajak penonton pria untuk menari bersama.


Diduga aksi erotis tari joged bumbung bali ini dilakukan oleh penari dari desa di

Wednesday, September 15, 2010

JSF 2.0 - "Hello World" in Eclipse (with *.xhtml pages)


Requirements:
  • installed Java (description here)
  • installed and configured Eclipse (description here)
  • installed and configured Tomcat for the Eclipse (description here)
You will learn:
  • how to create "Hello World" application in JSF 2.0 using Eclipse
Note 1: The following post and example show classic JSF 2.0 application with a view technology as .xhtml pages. I do not use any additional libraries and extensions for the standard JSF libraries. I don't use (for the time being) templates. JSF implementation used comes from MyFaces.

Note 2: I use standard capabilities of IDE platform to generate the project, without those thousands automated plugins which do everything for the user. Sometimes configuration and usage of a plugin is a "pain in the ..." - in my opinion it is worth to know how to deal with a standard set of tools, and after that there is always a time to faciliate our life ;-)

In this post I will show how to create sample JSF 2.0 application using Eclipse. It will be similar application like in the post about creating sample JSF 1.2 application. But there will be some small differences, especially during generating the project and adding JSF capabilities to it. Let's do it.

Step 1: create new dynamic web project for the Tomcat. It is available in "web" menu section under option "File->New->Project":

Press "Next" to go further and set some basic project's properties:


Step 2:
adding JSF capabilities for the generated project (JSF and JSTL libraries).

This step is the same as step 2 in previous JSF 1.2 example under Eclipse. The main difference prior to version 1.2 is that JSTL libraries are not necessary, unless application uses *.jsp pages with some standard JSP tags, and we have to choose JSF 2.0 MyFaces. JSF 2.0 support for Project Facets was added in Eclipse Helios and above. For previous Eclipse version (like Galileo) only JSF 1.2 was supported and configuration for JSF 2.0 needs to be done in alternative way (see below).

Note: this configuration allows You to use Code Assist for *.xhtml pages. Code Assist allows automatically complete JSF tags when typying by pressing CTRL + Space. It also provides direct access to beans, their methods or fields directly from JSP page - just by click on bean/field name but only when Your beans are directly declared in faces-config.xml file. Unfortunately this is Eclipse bug that You do not have access to beans declared using annotations (see for example https://bugs.eclipse.org/bugs/show_bug.cgi?id=323709). It is still not fixed in Indigo, despite the fact that it should work in 3.4.x, as noted in the bug.

--------------------------------------------
Step 2 - an alternative way:

We do not have to download requires .jar files for JSF, make user libraries from them in Eclipse and add those libraries to the generated project with "Project Facets" screen. The alternative way is to download all required .jar files and copy them into the generated "WebContent\WEB-INF\lib" directory. After that just refresh the whole project by pressing "F5" on the project's root and all libraries should appear in the section named "Web App Libraries" in the project's structure. This is useful when You have newer version of libraries than those offered to download in "Project Facets" by default. 

Is it possible to make a Code Assist also work for this case? Yes it is. You have to enable "Project Facets", then check the option "JavaServer Faces" and then select "Further configuration available...". On the screen You have to select "Disable library configuration" and press OK:



Step 3: the project structure is ready. Creating sample application.

This will be the same application as for version 1.2 with some differences coming from JSF 2.0:

- pages extenstion will be .xhtml instead of .jsp
- we use annotations in backing beans
- there will be no faces-config.xml file (now)


Everything should look like this:


File web.xml has to be changed like shown on screenshot below:


Step 4: deployment and running.

This step is similar to steps 6 and 7 from JSF 1.2 version. After deploying application on the server and starting the server, we have to open a browser and type in URL:

http://localhost:8080/FirstJSF2

That's all. We should have working JSF 2.0 application.

-------------------------------------------
Download source files:

Note: make sure that Java, Eclipse and Tomcat are properly installed and configured for running the project (additional configuration may be required if different directories are used).

Eclipse complete sample project is here (with all required libraries). You can also download a war file located here (just copy it inside webapps folder in Your Tomcat and start Tomcat with the script startup.bat)

JSF 2.0 - "Hello World" in NetBeans (with *.xhtml pages)

Requirements:
  • installed Java (description here)
  • installed and configured NetBeans (description here)
  • installed and configured Tomcat for the NetBeans (description here)
You will learn:
  • how to create "Hello World" application in JSF 2.0 using NetBeans
Note 1: The following post and example show classic JSF 2.0 application with a view technology as .xhtml pages. I do not use any additional libraries and extensions for the standard JSF libraries. JSF implementation used comes from Sun.

Note 2: I use standard capabilities of IDE platform to generate the project, without those thousands automated plugins which do everything for the user. Sometimes configuration and usage of a plugin is a "pain in the ..." - in my opinion it is worth to know how to deal with a standard set of tools, and after that there is always a time to faciliate our life ;-)

In a previous post I showed how to create a sample JSF 1.2 application using NetBeans. Creating JSF 2.0 application under NetBeans is almost the same as creating JSF 1.2 application - the main difference is just selecting JSF 2.0 version instead of 1.2.
I will show how to create JSF 2.0 sample application similar to JSF 1.2 application.

Step 1: creating and configuring web application.

Now we have to define project name and its location:

After pressing "Next" we have to configure target runtime and context name:

Press "Next" in order to go to the JSF settings screen. Here we have to select JSF 2.0 version:

Step 2: project is configured. This is what NetBeans generated for us:

Just like for version 1.2, project contains all requires libraries and is ready to be deployed on the server.

Step 3: creating application.

This will be the same application as for version 1.2 with some differences coming from JSF 2.0:

- pages extenstion will be .xhtml instead of .jsp
- we use annotations in backing beans
- there will be no faces-config.xml file (now)

Everything should look like this:

Step 4: deploying on server and running.

This step is exactly the same as step 4 from previous post about sample JSF 1.2 application. We also don't have to start the browser manually to see the application. Browser will be started automatically with proper URL pointing to our application.

What next? This simple working project can be used as a base for further learning about JSF. For example we can change the view technology from .jsp to facelets. We can add libraries which extend our standard tags by adding tags with ajax support, i.e RichFaces.

Tuesday, September 14, 2010

Georgina Wilson on the cover of Philippine Tatler

Georgina Wilson is one of the beautiful faces you will see in many Magazines. Here she graces the cover of Philippine Tatler.

Monday, September 6, 2010

Qory Sandioriva Berubah karena Mr R

Belakangan ini gosip tentang qory sandioriva puteri indonesia 2009 yang gagal di miss universe 2010 sedang santer terdengar, dikabarkan qory sandioriva kabur dari rumah dan tidak ingin bertemu dengan orang tuanya. Lebih parah lagi qory juga sempat mengucapkan agar orang tuanya tidak mencampuri hidupnya lagi. bahkan ada juga gosip yang mengatakan Qory sandioriva penganut ilmu hitam. Menurut ibu

Enda Gantikan Pasha jadi Vokalis Ungu di Dahsyat

Enda gitaris ungu menggantikan pasha untuk menjadi vokalis di ajang musik dahsyat, pasalnya pasha tidak bisa hadir dalam acara itu karena terjebak macet. Enda gitaris Ungu terpaksa bernyanyi menggantikan posisi Pasha yang datang terlambat di acara Dahsyat. Meski mulus, Enda mengaku susah sekali.


"Pasha sih bilang oke-oke aja. Tapi gue setengah mati membawakannya," kata Enda seraya bercanda saat

Sunday, September 5, 2010

Gosip Julia Perez Gaston Castano

Bagaimana kabar hubungan jupe-gaston? kabarnya julia perez dan gaston mengakali proses ketemuan mereka selama bulan puasa yaitu setelah berbuka puasa, karena julia perez yang seksi itu khawatir akan libidonya yang tinggi. Julia Perez alias Jupe sadar libidonya tinggi. Takut puasa batal, Jupe memutuskan baru mau bertemu kekasihnya, Gaston Castano saat berbuka puasa. Wuah ternyata julia perez

Thursday, September 2, 2010

JSF 1.2 - "Hello World" in NetBeans (with *.jsp pages)


Requirements:
  • installed Java (description here)
  • installed and configured NetBeans (description here)
  • installed and configured Tomcat for the NetBeans (description here)
You will learn:
  • how to create "Hello World" application in JSF 1.2 using NetBeans

Note 1: The following post and example show classic JSF 1.2 application with a view technology as .jsp pages. I do not use any additional libraries and extensions for the standard JSF libraries.

Note 2: I use standard capabilities of IDE platform to generate the project, without those thousands automated plugins which do everything for the user. Sometimes configuration and usage of a plugin is a "pain in the ..." - in my opinion it is worth to know how to deal with a standard set of tools, and after that there is always a time to faciliate our life ;-)

In the previous post I described how to generate working sample of JSF 1.2 application using Eclipse and its capabilities. I decided to check how it looks like using NetBeans. And this was a nice surprise for me - it is easier than in Eclipse. I will show how to generate a working JSF application similar to application created under Eclipse.

Assumptions:
1. Installed Java (description here).
2. Installed and configured NetBeans (description here).
3. Installed and configured Tomcat for the NetBeans (description here).

Step 1: creating and configuring web application.

Press "Next" and on the next screen configure some basic options like name and directory for the project.



Press "Next" and on the next screen configure runtime for the project.

Press "Next" and on the next screen add JSF capabilities to the project. Select "JavaServer Faces" option and set up JSF 1.2 libraries.

Step 2: project is configured.

Screenshot below shows the project structure generated by NetBeans.


That's all. Project is ready to deploy on the server. You don't need to add and configure JSF or JSTL libraries like under Eclipse. Those libraries are already in the project. Anyway in order to show that everything works the same we will modify generated project and write some piece of an application like under Eclipse.


Step 3: creating application.

Now we are ready to implement some sample JSF application. First we should create a package named com.firstjsf.backingbeans in the "Source Packages" directory. Second we should create two classes inside the package named HelloMessageBean and WelcomeBean. Third we should modify generated faces-config.xml file by adding there our classes and navigation rules. Everything should look like this:

In the faces-config.xml file we created entries for the navigation rules for not existing yet web pages. Let's create those web pages (index.jsp and message.jsp) in the Web Pages directory:


Step 4: deploying on server and running the application.

We have to click only one icon - NetBeans will start the Tomcat with our application deployed:



Results of application running can be visible in the console. We don't have to directly tell the Tomcat what application to deploy like under Eclipse - this step is done automatically. Moreover we don't have to start the browser manually to see the application. Browser will be also started automatically with proper URL pointing to our application.

What next? This simple working project can be used as a base for further learning about JSF. For example we can change the view technology from .jsp to facelets. We can add libraries which extend our standard tags by adding tags with ajax support, i.e RichFaces.

Wednesday, September 1, 2010

JSF 1.2 - "Hello World" in Eclipse (with *.jsp pages)

Requirements:
  • installed Java (description here)
  • installed and configured Eclipse (description here)
  • installed and configured Tomcat for the Eclipse (description here)
You will learn:
  • how to create "Hello World" application in JSF 1.2 using Eclipse
Note 1: The following post and example show classic JSF 1.2 application with a view technology as .jsp pages. I do not use any additional libraries and extensions for the standard JSF libraries.

Note 2: I use standard capabilities of IDE platform to generate the project, without those thousands automated plugins which do everything for the user. Sometimes configuration and usage of a plugin is a "pain in the ..." - in my opinion it is worth to know how to deal with a standard set of tools, and after that there is always a time to faciliate our life ;-)
Many publications and tutorials about JSF (Java Server Faces) very briefly descibe the configuration of development environment for the described examples. Many times I saw such situation: after few sentences about "how amazing is JSF" there was a simple list of JSF tags with their attributes described. Or at the beginning there was an example of "Hello World" application and every line of code was described and explained.
I think that is what is missing is the lack of an example of complete project with its directory structure and an information how to create this project and deploy on the web server. I saw some examples where the project structure was shown, but for the building and deploying application user had to use Ant and type some commands. Great, but we need Ant, when we have Ant, we need to be familiar with it to write build.xml file, then we need something else and so on and so on.
This is of course OK if we want to write everything from scratch by hand. But wouldn't it better just to start our IDE, make some clicks and have a complete and working project ready for further development?
Let's see how it looks like in Eclipse IDE.

Step 1: creating dynamic web project for the Tomcat.

Open menu "File->New->Project" and in the "web" section find and choose "Dynamic Web Project" and press "Next":


Press "Next" to go further and set some basic project's properties:



After that we should have generated project structure for the web application.

Step 2:
adding JSF capabilities for the generated project.

In order to do this just right click on the project and from the opened context menu choose "Properties" option. Locate the section "Project Facets" and check the option "JavaServer Faces".

Choose "Further configuration required..." option below to configure JSF libraries:


Choose "User Library" type and press marked icon to download JSF libraries. Eclipse Galileo allows to download two implementations of JSF: MyFaces anf from the Sun. Let's choose MyFaces:


Please note that we created a special directory for libraries in the Eclipse workspace - libraries will be downloaded to this directory. After pressing "Next" we have to follow the library installer instructions:



After pressing "Finish", JSF libraries are visible and ready to use in the project.


Step 3: JSTL libraries.

If JSP tags will be used in JSF application, JSTL libraries are required next to automatically downloaded JSF libraries. Unfortunately above automated solution for downloading JSF libraries does not download JSTL libraries, so we have to download them manually. I recommend to create another directory for JSTL libraries next to the JSF downloaded libraries in Eclipse's workspace directory. So create directory "libraries\JSTL" in Eclipse workspace directory, download JSTL libraries from there and put them into that directory. It should look like this:


Now we should create library from the downloaded JSTL files in the Eclipse in order to be able to use them in the project. It will be the similar operation to the creating JSF library - the difference is that we will do it manually. Just open the context menu for the whole project (right click) and go to the "Properties" screen. Then locate "Project Facets" section and find the "Add library" button.


Please note that library list contains JSF libraries added in step 2. Now create new library named "JSTL" like it is shown above, and add .jar files from JSTL directory:


Then make sure that those two libraries (JSF i JSTL) are added to the project (application):


Note: this configuration allows You to use Code Assist for *.jsp pages. Code Assist allows automatically complete JSF tags when typying by pressing CTRL + Space. It also provides direct access to beans, their methods or fields directly from JSP page - just by click on bean/field name.

-------------------------------------------- 
Steps 2 and 3 - an alternative way:

We do not have to download requires .jar files for JSF and JSTL, make user libraries from them in Eclipse and add those libraries to the generated project with "Project Facets" screen. The alternative way is to download all required .jar files and copy them into the generated "WebContent\WEB-INF\lib" directory. After that just refresh the whole project by pressing "F5" on the project's root and all libraries should appear in the section named "Web App Libraries" in the project's structure. This is useful when You have newer version of libraries than those offered to download in "Project Facets" by default.

Is it possible to make a Code Assist also work for this case? Yes it is. You have to enable "Project Facets", then check the option "JavaServer Faces" and then select "Further configuration available...". On the screen You have to select "Disable library configuration" and press OK:



Step 4: the overview of a project.

When steps 1-3 where done as described, the project structure should look like this:


Please note that JSF and JSTL .jar files are visible as user libraries in created in steps 2 and 3.

Step 5: "Hello World" application.

Now we are ready to implement some sample JSF application. First we should create a package named com.firstjsf.backingbeans in the "src" directory. Second we should create two classes inside the package named HelloMessageBean and WelcomeBean. Third we should modify generated faces-config.xml file by adding there our classes and navigation rules. Everything should look like this:


Be careful about small and big letters - names should be exactly as shown above. In the faces-config.xml file we created entries for the navigation rules for not existing yet web pages. Let's create those web pages (index.jsp and message.jsp) in the WebContent directory:


Application is ready.

Step 6: deploying on Tomcat.

At the bottom of a screen locate "Severs" tab. We should have already Tomcat there. Right click on server name to open its context menu, ten choose option "Add and Remove...":


Choose our project and add it to the server by pressing "Add" button:


Step 7: running the application.

Go back to the "Server" tab again and make sure that our project is visible on the server. Then click the marked icon to start the server:


After starting the server we should see that the server state was changed:


After deploying application on the server and starting the server, we have to open a browser and type in URL:

http://localhost:8080/FirstJSF

What next? This simple working project can be used as a base for further learning about JSF. For example we can change the view technology from .jsp to facelets. We can add libraries which extend our standard tags by adding tags with ajax support, i.e RichFaces.

-------------------------------------------
Download source files:

Note: make sure that Java, Eclipse and Tomcat are properly installed and configured for running the project (additional configuration may be required if different directories are used).

Eclipse complete sample project is here. External libraries folder (with JSF and JSTL) is here. You can also download a war file located here (just copy it inside webapps folder in Your Tomcat and start Tomcat with the script startup.bat)