<?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>Rise2Reality Blog</title>
	<atom:link href="http://www.rise2reality.com/blog/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.rise2reality.com/blog</link>
	<description>Software and advertising need no manual</description>
	<lastBuildDate>Wed, 02 Jun 2010 15:23:39 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
		<item>
		<title>A4j:jsFunction on page load</title>
		<link>http://www.rise2reality.com/blog/2010/01/a4j-jsfunction-on-page-load/</link>
		<comments>http://www.rise2reality.com/blog/2010/01/a4j-jsfunction-on-page-load/#comments</comments>
		<pubDate>Fri, 15 Jan 2010 22:38:21 +0000</pubDate>
		<dc:creator>Claudiu</dc:creator>
				<category><![CDATA[Tech]]></category>
		<category><![CDATA[a4j]]></category>
		<category><![CDATA[a4j:jsfunction]]></category>
		<category><![CDATA[jsf]]></category>

		<guid isPermaLink="false">http://www.rise2reality.com/blog/?p=77</guid>
		<description><![CDATA[Problem You need to send some data to the server on page access. One way to do this is by calling an a4j:jsFunction with the appropriate parameters. The problem is that you have to call this function after the page has fully loaded. Solution Use the jQuery(document).ready for this. If you call the function too [...]]]></description>
			<content:encoded><![CDATA[<h3>Problem</h3>
<p>You need to send some data to the server on page access. One way to do this is by calling an a4j:jsFunction with the appropriate parameters.<br />
The problem is that you <em>have to call</em> this function <em>after</em> the page has fully loaded.</p>
<h3>Solution</h3>
<p>Use the jQuery(document).ready for this.<br />
If you call the function too early in an embedded Javascript code it will try to call the @Create method of the bean once again. That second call will probably throw some exceptions which are hard to detect.<br />
Took me some time to figure this out since the console pointed me to the @Create method.</p>
<h3>Update</h3>
<p>After working with seam remoting component I figured out the answer to this behavior. Seam remoting behaves in the same way if used with the most basic settings. It considers the bean to be stateless. After pointing it to use the current conversation everything works ok. The a4j:jsFunction probably doesn&#8217;t have time to set it&#8217;s conversation status before being called in an inline javascript code. Hence the repeated call to the @Create method.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.rise2reality.com/blog/2010/01/a4j-jsfunction-on-page-load/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Paypal with JSF &#8211; Making payments from your Enterprise Application</title>
		<link>http://www.rise2reality.com/blog/2009/12/paypal-with-jsf-making-payments-in-your-enterprise-application/</link>
		<comments>http://www.rise2reality.com/blog/2009/12/paypal-with-jsf-making-payments-in-your-enterprise-application/#comments</comments>
		<pubDate>Tue, 08 Dec 2009 09:52:15 +0000</pubDate>
		<dc:creator>Kingi</dc:creator>
				<category><![CDATA[Tech]]></category>
		<category><![CDATA[enterprise paypal sales package]]></category>
		<category><![CDATA[j2ee]]></category>
		<category><![CDATA[jsf]]></category>
		<category><![CDATA[paypal]]></category>
		<category><![CDATA[paypal with jsf]]></category>
		<category><![CDATA[paypal with seam]]></category>

		<guid isPermaLink="false">http://www.rise2reality.com/blog/?p=56</guid>
		<description><![CDATA[If you have an enterprise application based on J2EE, Seam, Spring or just pure JSF and you want to start charging people for the services or products you provide you can use Paypal&#8217;s services to make credit card or bank transfer payments. The Paypal BuyNow button is a an easy approach to do this. New! [...]]]></description>
			<content:encoded><![CDATA[<p>If you have an enterprise application based on J2EE, Seam, Spring or just pure JSF and you want to start charging people for the services or products you provide you can use Paypal&#8217;s services to make credit card or bank transfer payments. The Paypal BuyNow button is a an easy approach to do this.</p>
<p><span style="color: #800000;"><strong>New!</strong></span> A complete Enteprise Sales Paypal Package is available from us for a small fee of 80EUR or 90USD. If you are interested please <a title="Buy the Enterprise Sales Paypal Package" href="http://www.rise2reality.com/contact" target="_blank">contact us</a> in order to buy this package. Or simply let us know if this information was useful or interesting for you.</p>
<div class="mceTemp">
<dl>
<dt><img class="size-full wp-image-57" src="http://www.rise2reality.com/blog/wp-content/uploads/2009/12/btn_buynow_LG.gif" alt="Paypal Buynow" width="107" height="26" /></dt>
</dl>
</div>
<p>You can use the BuyNow JSF component which wraps the functionality of the Paypal button. The original implementation of the Paypal BuyNow button uses an HTTP form with POST method that sends predefined POST variables to Paypal.</p>
<h3>The JSF Paypal BuyNow component</h3>
<p>Download the <a href="https://blueprints.dev.java.net/servlets/ProjectDocumentList?folderID=4144&amp;expandFolder=4144&amp;folderID=4743">bpcatalog-ee5-ea-0.8-installer.jar</a> and see the reference documentation on <a href="https://blueprints.dev.java.net/complib/v2/buy-now.html">Java Sun Blueprints</a>.<br />
The component can be linked to a backing bean and you can easily send additional post data to Paypal.</p>
<p>First you have to extract the downloaded <em>bpcatalog</em>. The installer should do this automatically; if it doesn&#8217;t just run the jar with the <em>java -jar</em> switch.<br />
In the <em>bpcatalog-ee5-ea-0.8/lib</em> folder you&#8217;ll find the <em>bp-ui-14.jar</em> and <em>shalem-remoting.jar</em> libraries. You will need to include these two libraries into your project. The <em>bp-ui-14.jar</em> is the actual wrapper for the button.</p>
<h3>Fix the tag library</h3>
<p>The JSF component is missing its tag library. In order to include and use it as a JSF component you must insert a <em>taglib.xml </em> file into the <em>bp-ui-14.jar/META-INF</em> folder.</p>
<p>The <em>taglib.xml</em> file should contain the following:</p>
<pre class="xhtml, prettyprint">&lt;?xml version="1.0"?&gt;
&lt;!DOCTYPE facelet-taglib PUBLIC
"-//Sun Microsystems, Inc.//DTD Facelet Taglib 1.0//EN"
"http://java.sun.com/dtd/facelet-taglib_1_0.dtd"&gt;
&lt;facelet-taglib xmlns="http://java.sun.com/JSF/Facelet"&gt;
&lt;namespace&gt;http://java.sun.com/blueprints/ui&lt;/namespace&gt;
&lt;tag&gt;
&lt;tag-name&gt;buyNow&lt;/tag-name&gt;
&lt;component&gt;
&lt;component-type&gt;com.sun.j2ee.blueprints.ui.shopping.BuyNow&lt;/component-type&gt;
&lt;renderer-type&gt;com.sun.j2ee.blueprints.ui.shopping.BuyNow&lt;/renderer-type&gt;
&lt;/component&gt;
&lt;/tag&gt;
&lt;/facelet-taglib&gt;</pre>
<h3>Include it into your JSF page</h3>
<p>Now you&#8217;re ready to use the Paypal button as a JSF component. Include the tag into the namespace of your page template:</p>
<pre class="xhtml, prettyprint">&lt;ui:composition ....
xmlns:bp="http://java.sun.com/blueprints/ui"
..&gt;</pre>
<p>Include the component on your page:</p>
<pre class="xhtml, prettyprint">&lt;bp:buyNow amount="10.00"
itemName="My Product"
business="email@yourapp.com"
quantity="1"
returnUrl="http://yourapp.com/thankyou.page"
paymentCancelledUrl="http://yourapp.com/billing.page"
notifyUrl="http://yourapp.com/ipnscript.page"
type="BuyNow"&gt;</pre>
<p>There are a couple of smaller mistakes in the documentation:</p>
<ul>
<li>notify_url is wrapped as notifyUrl instead of postbackUrl as stated (use notifyUrl=&#8221;http://yourserver/YourIPNProcessingScript&#8221;)</li>
<li>item_number does not send any value to Paypal</li>
</ul>
<p>Another Paypal related common difficulty is parsing the date sent by Paypal. They are formatting it based on US PST/PDT time. The recommended formatting for the date parsing is:</p>
<pre class="java, prettyprint">String PAYPAL_DATE_FORMAT = "HH:mm:ss MMM dd, yyyy z";</pre>
<h3>Creating the pages</h3>
<p>With the help of the <em>return</em>, <em>paymentCancelled </em>and <em>notify </em>URLs Paypal can send messages to your server about events. It can also redirect your customers to the pages you want them to view when an event occurs. When a payment occurs Paypal will invoke the <em>notifyUrl</em> page and send back some POST variables. You will have to process and validate these variables manually as the above component will not do this for you. A method in your backing bean should be able to process the Paypal message. This will be your so called IPN script.</p>
<h3>Processing the Paypal response</h3>
<p>The <em>notifyUrl</em> parameter tells Paypal where to send a message which notifies you of the event initiated by a paying customer. The <em>PaypalProcessBean</em> will take care of processing this message by checking whether the data of the transaction is correct. You can then proceed with providing the service to your customer.</p>
<p>You can process the POST variables sent by Paypal by reading them from the <em>FacesContext</em>:</p>
<pre class="java, prettyprint">FacesContext facesContext = FacesContext.getCurrentInstance();
HashMap&lt;String, String&gt; IPNPaypalVariables = new HashMap&lt;String, String&gt;();
IPNPaypalVariables.putAll(facesContext.getExternalContext()
.getRequestParameterMap());</pre>
<h3>Validating the transaction</h3>
<p>Paypal suggests that in order to verify the data which is being posted back you need to send back all these POST variables in the exact order starting with and additional <em>cmd=_notify-validate</em> parameter.<br />
Paypal responds with a VERIFIED or INVALID message depending on the correctness of the information you have posted earlier. If you received the VERIFIED message the transaction was correct. Now you can rest assured it wasn&#8217;t a hacking attempt.</p>
<h3>Conclusion</h3>
<p>If you want to start earning money with your hard work Paypal is an easy to use service from the perspective of your customers. You can easily integrate the Sun Blueprints Library with your favorite enterprise application framework.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.rise2reality.com/blog/2009/12/paypal-with-jsf-making-payments-in-your-enterprise-application/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>iPhone Feedback Survey: Creating Questions about your iPhone App</title>
		<link>http://www.rise2reality.com/blog/2009/11/iphone-feedback-survey-questions-for-iphone-app-developers/</link>
		<comments>http://www.rise2reality.com/blog/2009/11/iphone-feedback-survey-questions-for-iphone-app-developers/#comments</comments>
		<pubDate>Wed, 18 Nov 2009 15:18:06 +0000</pubDate>
		<dc:creator>Endre</dc:creator>
				<category><![CDATA[GoQuestion]]></category>
		<category><![CDATA[iPhone Surveys]]></category>
		<category><![CDATA[goquestion for iphone]]></category>
		<category><![CDATA[iphone]]></category>
		<category><![CDATA[iphone app survey]]></category>
		<category><![CDATA[iphone developer survey]]></category>
		<category><![CDATA[iphone feedback]]></category>
		<category><![CDATA[iphone survey]]></category>
		<category><![CDATA[survey]]></category>

		<guid isPermaLink="false">http://www.rise2reality.com/blog/?p=43</guid>
		<description><![CDATA[So you are an iPhone developer and have your iPhone App. Say you somehow managed to get through ice and brimstone and got through with the approval process. You are selling your iPhone App in the Apple Store. Congrats! What you Want to Achieve Get more buyers for your iPhone App Find out whether you should [...]]]></description>
			<content:encoded><![CDATA[<p>So you are an iPhone developer and have your iPhone App. Say you somehow managed to get through ice and brimstone and got through with the approval process. You are selling your iPhone App in the Apple Store. Congrats!</p>
<h3>What you Want to Achieve</h3>
<ul>
<li><span style="background-color: #ffffff;">Get more buyers for your iPhone App</span></li>
<li><span style="background-color: #ffffff;">Find out whether you should lower or raise the price</span></li>
<li><span style="background-color: #ffffff;">Find out where you should advertise more</span></li>
<li><span style="background-color: #ffffff;">Find out whether your users are satisfied</span></li>
</ul>
<p>In order to get in touch with your users you could probably allow them to contact you and fill out a small feedback survey regarding your App. People generally like putting their opinions out there and this might be really useful for you. You can even share the results to show your newcomers what your current users are thinking. <span style="background-color: #ffffff; ">But which questions should you be asking? We are trying to sum these up and put up a conclusion for you.</span></p>
<h3>Your Survey Questions</h3>
<p>You can easily find out stuff about your App if you get in touch with your users. You should probably ask them some quick but relevant questions in an unobtrusive way.</p>
<ul>
<li><span style="background-color: #ffffff; "><em>How satisfied are you?</em> You should probably be asking this because quality is an essential issue. This can come down to usability, responsiveness, obtrusiveness and even stuff that doesn&#8217;t work. You can ask them to rate these aspects.</span></li>
<li><span style="background-color: #ffffff; "><em>How much time are you spending using our App?</em> You may want to know this because then you can immediately know how relevant the next answers will be.</span></li>
<li><span style="background-color: #ffffff; "><em>Which features do you find useful and which ones do you not? </em>Here is where you find out what you should really keep or throw out. Less is more. Simpicity is powerful.</span></li>
<li><span style="background-color: #ffffff; "><em>Which features should we be adding next? </em>You can sum this up nicely and choose what you will be adding in your next release.</span></li>
<li><span style="background-color: #ffffff; "><em>What do you think of the price?</em> If your monthly sales are going down then you could be adjusting your price accordingly.</span></li>
<li><span style="background-color: #ffffff;"><em>How did you find us?</em> This will tell you where you could be putting in a bit more effort to get your App known.</span></li>
<li><span style="background-color: #ffffff;"><em>Comments, opinions and suggestions.</em> The really useful follow-ups like critique should come from here if your users value your App.</span></li>
</ul>
<p>All in all you could be providing an unobtrusive link to a feedback survey somewhere. It will be their choice if they want to tap on that and help you out or just express their opinion. Don&#8217;t be alarmed of negative critique! That is what you should be collecting. That is where you can learn from.</p>
<h3>Your Opinion</h3>
<p>Please post your opinion on this. We will include this possibility in our <a href="http://www.goquestion.net/iphone/survey-software-for-iphone-developers/">GoQuestion survey platform</a>. You will then be able to include a link to the survey from your iPhone App which they will be able to open directly on their iPhone. From then on you can get to know your users. And keep in touch with them and even follow-up. All of this while you are being professional and unobtrusive. You will be able to sum up these responses in useful visualizations and compare them to the rest of the community to see where you are ranking.</p>
<p>Your own questions and comments are more than welcome! I will be posting a follow-up as soon as we compile a full set of questions.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.rise2reality.com/blog/2009/11/iphone-feedback-survey-questions-for-iphone-app-developers/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Selective rendering of elements in JSF, Ajax4JSF and RichFaces</title>
		<link>http://www.rise2reality.com/blog/2009/09/selective-rendering-of-elements-in-jsf-and-richfaces/</link>
		<comments>http://www.rise2reality.com/blog/2009/09/selective-rendering-of-elements-in-jsf-and-richfaces/#comments</comments>
		<pubDate>Wed, 30 Sep 2009 12:18:24 +0000</pubDate>
		<dc:creator>Claudiu</dc:creator>
				<category><![CDATA[Tech]]></category>
		<category><![CDATA[a4j]]></category>
		<category><![CDATA[c:if]]></category>
		<category><![CDATA[conditional rendering]]></category>
		<category><![CDATA[jsf]]></category>
		<category><![CDATA[rich:togglecontrol]]></category>
		<category><![CDATA[rich:togglepanel]]></category>
		<category><![CDATA[richfaces]]></category>

		<guid isPermaLink="false">http://www.rise2reality.com/blog/?p=3</guid>
		<description><![CDATA[When you need conditional rendering inside an Ajax4JSF &#60;a4j:repeat&#62; the JSF &#60;c:if&#62; tag will not work. You can remedy this problem by using an alternative solution. Problem Inside an &#60;a4j:repeat var="_counter" value="#{bean.list}"&#62; the &#60;c:if&#62; tag will not recognize the _counter variable. You won&#8217;t even notice it doesn&#8217;t work because no errors will be logged. As an alternative [...]]]></description>
			<content:encoded><![CDATA[<p>When you need conditional rendering inside an Ajax4JSF &lt;a4j:repeat&gt; the JSF <code>&lt;c:if&gt;</code> tag will not work. You can remedy this problem by using an alternative solution.</p>
<h3>Problem</h3>
<p>Inside an <code>&lt;a4j:repeat var="_counter" value="#{bean.list}"&gt;</code> the <code>&lt;c:if&gt;</code> tag will not recognize the <code>_counter</code> variable. You won&#8217;t even notice it doesn&#8217;t work because no errors will be logged.<br />
As an alternative you can use the <code>&lt;rich:togglePanel&gt;</code> component.</p>
<h3>Solution</h3>
<p>Let&#8217;s take this example as an alternative to the JSF &lt;c:if&gt; tag:</p>
<pre class="java, prettyprint">&lt;rich:togglePanel id="switch" value="#{beanEntity.selectedPanel}"
            switchType="server"
            initialState="panelOne" stateOrder="panelOne,panelTwo"&gt;
&lt;f:facet name="panelOne"&gt;
      &lt;rich:panel&gt;
      &lt;h:outputtext value="This is the first panel"/&gt;
      &lt;rich:toggleControl value="switch panel"
            for="switch" switchToState="panelTwo"/&gt;
       &lt;/rich:panel&gt;
&lt;/f:facet&gt;

&lt;f:facet name="panelTwo"&gt;
      &lt;rich:panel&gt;
            &lt;h:outputtext value="This is the second panel"/&gt;
            &lt;rich:toggleControl for="switch" value="switch panel"
                  switchToState="panelOne"/&gt;
      &lt;/rich:panel&gt;
&lt;/f:facet&gt;
&lt;/rich:togglePanel&gt;</pre>
<p>You have a few parameters which you can use:</p>
<p>1. <code>switchType</code> which can be either of</p>
<ul>
<li><code>client</code> renders all the panel&#8217;s faces, and switches between them on the client side</li>
<li><code>ajax</code> renders only one panel at a time, and the switch is done by communicating with the server dynamically</li>
<li><code>server</code> renders only one face at a time, the switch is made on page refresh</li>
</ul>
<p>If you need something rendered only if a condition is true, server is the best option.</p>
<p>2. <code>initialState</code> controls what the first rendered panel should be. If it&#8217;s not specified the panels are rendered in the order specified by <code>stateOrder</code>. If that&#8217;s missing also they are rendered in the order the panels are declared.</p>
<p>For switching between panels you can use <code>&lt;rich:toggleControl&gt;</code>. This is similar to a link and has a <code>value</code> attribute (text to be shown). With the <code>id</code> attribute you can style content using css.</p>
<p>3. <code>switchToState</code> specifies to which state should the <code>togglePanel</code> control switch to. If this is not specified it will switch to the next panel in the <code>stateOrder</code> list. A <code>toggleControl</code> can be declared anywhere on the page. Not just inside a <code>togglePanel</code> control. It just needs the <code>for</code> attribute to point to the right component id.</p>
<p>Like in the case of the <code>&lt;c:if&gt;</code> tag, let&#8217;s say you want to render something if <code>#{bean.booleanProperty}</code> is <code>false</code>. You do the boolean check on the bean side. Then you set a bean property (eg. <code>String panelState</code>) to the value of <code>panelOne</code> if the booleanProperty is true. And subsequently to <code>panelTwo</code> if the booleanProperty is false. The togglePanel will have the <code>initialState</code> set to <code>#{bean.panelState}</code>.</p>
<h3>Conclusion</h3>
<p>The <code>&lt;c:if&gt;</code> JSF tag will just refuse  - without any error notice &#8211; to parse the counter variable coming from a wrapping <code>&lt;a4j:repeat&gt;</code> tag. It can be a little bit of a stretch but if you have problems with the <code>&lt;c:if&gt;</code> tag the above solution offers a good way to do conditional rendering.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.rise2reality.com/blog/2009/09/selective-rendering-of-elements-in-jsf-and-richfaces/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>The Rise2Reality Blog</title>
		<link>http://www.rise2reality.com/blog/2009/09/the-rise2reality-company-and-tech-blog/</link>
		<comments>http://www.rise2reality.com/blog/2009/09/the-rise2reality-company-and-tech-blog/#comments</comments>
		<pubDate>Mon, 28 Sep 2009 17:23:38 +0000</pubDate>
		<dc:creator>Endre</dc:creator>
				<category><![CDATA[Company]]></category>

		<guid isPermaLink="false">http://www.rise2reality.com/blog/?p=1</guid>
		<description><![CDATA[Welcome to the Rise2Reality Blog! The Company Blog is going to be the blog where you can find some information out where we are, what we&#8217;re doing and which directions we&#8217;re taking. The Tech Blog is going to be the internal technical blog about enterprise application tricks we are using in order to get things [...]]]></description>
			<content:encoded><![CDATA[<p>Welcome to the Rise2Reality Blog!</p>
<ul>
<li>The Company Blog is going to be the blog where you can find some information out where we are, what we&#8217;re doing and which directions we&#8217;re taking.</li>
<li>The Tech Blog is going to be the internal technical blog about enterprise application tricks we are using in order to get things done.</li>
</ul>
<p>For a start I&#8217;d like to point out the Software Branch of the company is going under the slogan <a title="Simplify Software" href="http://www.rise2reality.com/software-solutions/" target="_blank">simplify software</a>. We will work hard so you can enjoy simplicity. Here we are taking into account the fact that our software should run in the simplest manner very intuitively so that it does not complicate the lives of our customers but yet makes it more productive and simple.</p>
<blockquote><p>&#8220;How do you recognize something that is still technology? A good clue is if it comes with a manual.&#8221; - Douglas Adams</p></blockquote>
<p>Our advertising branch acts as a wrapper for the services you can get from us. While it employs a bucket of creativity <a title="The advertising wrapper" href="http://www.rise2reality.com/advertising-solutions/" target="_blank">the advertising wrapper</a> will sometimes go hand-in-hand with the ideologies which we employ in software. Whatever is filed under advertising will be constituted of a multitude of disciplines starting from photography all the way through to the tangible aspects of advertising. We&#8217;ll go as far as mixing in the right words to emphasize your message to choosing the right blend of colors and geometry in order to provide the feeling you want your audience to open their eyes to.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.rise2reality.com/blog/2009/09/the-rise2reality-company-and-tech-blog/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

