<?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 Another Dang Blog &#187; Web Resources</title>
	<atom:link href="http://blog.lopau.com/category/web-resources/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.lopau.com</link>
	<description>A tech blog about web development, graphic designs, freelancing, cloud computing, mobile development, innovations and seo.</description>
	<lastBuildDate>Thu, 06 Oct 2011 03:01:41 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Create a Web Service using SOAP</title>
		<link>http://blog.lopau.com/create-a-web-service-using-soap/</link>
		<comments>http://blog.lopau.com/create-a-web-service-using-soap/#comments</comments>
		<pubDate>Mon, 05 Sep 2011 14:49:58 +0000</pubDate>
		<dc:creator>lopau</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[SalesForce]]></category>
		<category><![CDATA[Web Resources]]></category>
		<category><![CDATA[force.com]]></category>
		<category><![CDATA[soap]]></category>

		<guid isPermaLink="false">http://blog.lopau.com/?p=1502</guid>
		<description><![CDATA[This week one of the requirements for our client was to have a force.com application communicate with an external web service running on PHP to generate a barcode sequence. I&#8217;ll teach how I was able to setup the web service using NuSOAP and a document/literal as rcp/encoded is not supported by force.com. My goal was [...]]]></description>
			<content:encoded><![CDATA[<p>This week one of the requirements for our client was to have a force.com application communicate with an external web service running on PHP to generate a barcode sequence. I&#8217;ll teach how I was able to setup the web service using NuSOAP and a document/literal as rcp/encoded is not supported by force.com. My goal was to make the task easier on php side so from force.com it would make a request by passing a string delimited by an asterisk and pipe. We process the string and return it back as url for the barcode image. I wont be covering barcode creation though in this tutorial but only the web service and sample client.<br />
<span id="more-1502"></span></p>
<p>
<!-- Begin Google Adsense code -->
<div class="googleads">
<script type="text/javascript"><!--
google_ad_client = "pub-4515932012590505";
/* 200x200, created 10/29/08 */
google_ad_slot = "3929428513";
google_ad_width = 200;
google_ad_height = 200;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
</div>
<!-- End Google Adsense code -->
<br />
e.g. Name*2|Mr.*3</p>
<p>The web service will parse the string convert it to an array. You can ofcourse pass any other type of string with a delimiter. </p>
<p>Here is how the server is.</p>
<div class="codesnip-container" >// Pull in the NuSOAP code<br />
require_once(&#8216;lib/nusoap.php&#8217;);<br />
// Create the server instance<br />
$server = new soap_server();<br />
$server->configureWSDL( &#8216;servicename&#8217;, &#8216;urn:servicename&#8217;, &#8221;, &#8216;document&#8217;);<br />
myRegister($server,&#8217;DoSomething&#8217;,array(<br />
	&#8216;in&#8217; => array(<br />
		&#8216;sf-parameters&#8217; =>  &#8216;xsd:string&#8217;),<br />
	&#8216;out&#8217; => array(&#8216;Pass&#8217; => &#8216;xsd:string&#8217;)<br />
));<br />
//if in safe mode, raw post data not set:<br />
if (!isset($HTTP_RAW_POST_DATA)) $HTTP_RAW_POST_DATA = implode(&#8220;\r\n&#8221;, file(&#8216;php://input&#8217;));<br />
$server->service( $HTTP_RAW_POST_DATA);<br />
function myRegister( &#038;$server, $methodname, $params) {<br />
	$server->register($methodname, $params["in"], $params["out"],<br />
&#8216;urn:servicename&#8217;, // namespace<br />
	$server->wsdl->endpoint .&#8217;#&#8217;. $methodname, // soapaction<br />
&#8216;document&#8217;, // style<br />
&#8216;literal&#8217;, // use<br />
&#8216;Generate Barcode Sequence URL&#8217; // documentation<br />
	);<br />
}<br />
function DoSomething($params) {<br />
	$string = $params;<br />
	$list = explode(&#8220;|&#8221;, $string);<br />
	//make associative array<br />
	$result = array();<br />
	foreach($list as $key=>$values) {<br />
		$result[] = explode(&#8220;*&#8221;, $values);<br />
	}</p>
<p>	//creates the string<br />
	$bcStr = &#8220;&#8221;;<br />
	foreach($result as $values) {<br />
		$bcStr .= $values[0];<br />
		for ($i = 1; $i < = $values[1]; $i++) {<br />
			$bcStr .= "\t";<br />
		}<br />
	}</p>
<p>	return array('Pass'=> $bcStr);<br />
}</p></div>
<p>You are instantiating a class of the NuSOAP server and configuring it with WSDL. You also create two functions,, one handles the $server->register method which takes the argument incoming request and the outgoing response and the $server->wsdl with arguments defining the server as a document/literal. </p>
<p>Then for my task purpose the incoming delimited string is converted to an associative array and then converted back to string with the proper formatting I require ($bcStr), if you have barcode class you can pass that string and a barcode image should be generated from it. That however is not covered on this tutorial.</p>
<p>Next is simple php client to test the web service out.</p>
<div class="codesnip-container" ><?php<br />
// Pull in the NuSOAP code<br />
require_once('lib/nusoap.php');<br />
// Create the client instance<br />
$ns="urn:servicename";<br />
$client = new nusoap_client('http://localhost/soap_server/hellowsdl2.php?wsdl', true);<br />
if ( $client->getError() ) {<br />
	print &#8220;Soap Constructor Error:
<pre>".
	$client->getError()."</pre>
<p>&#8220;;<br />
}<br />
$params=array(&#8220;sf-parameters&#8221;=>&#8221;Name*2|Mr.*3&#8243;);<br />
$result = $client->call( &#8220;DoSomething&#8221;, array(&#8220;parameters&#8221;=>$params), $ns);<br />
if ($client->fault) {<br />
	//soap_fault<br />
	print &#8220;<br />
<h2>Soap Fault: </h2>
<pre>(". $client->fault->faultcode .")  ".
	$client->fault->faultstring. "</pre>
<p>&#8220;;<br />
}<br />
elseif ( $client->getError() ) {<br />
	print &#8220;<br />
<h2>Soap Error: </h2>
<pre>". $client->getError() ."</pre>
<p>&#8220;;<br />
}<br />
else {<br />
	print &#8220;<br />
<h2>Result: </h2>
<pre>". $result["Pass"] ."</pre>
<p>&#8220;;<br />
}<br />
print &#8216;<br />
<h2>Details:</h2>
<hr />&#8216;.<br />
&#8216;<br />
<h3>Request</h3>
<pre>' .
htmlspecialchars( $client->request, ENT_QUOTES) .'</pre>
<p>&#8216;.<br />
&#8216;<br />
<h3>Response</h3>
<pre>' .
htmlspecialchars( $client->response, ENT_QUOTES) .'</pre>
<p>&#8216;.<br />
&#8216;<br />
<h3>Debug</h3>
<pre>' .
htmlspecialchars( $client->debug_str, ENT_QUOTES) .'</pre>
<p>&#8216;;<br />
?></p></div>
<p>This time I instantiated a <strong>nusoap_client</strong> note that underscore _ as I got stuck on this earlier and got PHP complaining when it was just <strong>nusoapclient</strong>. Next I created the string params to be passed to the DoSomething method via $client->call.</p>
<p>Then from here we goback to our force.com app we make a soap request to the webservice and it returns with the response we need. On Force.com make sure you add your web service the Remote Site Settings under Setup > Administrative Setup > Security Controls. </p>
<p>Kudos for the resource and solution for task from the original author <a href="http://mleiv.com/php-nusoap-documentliteral-web/">mleiv blog&#8217;s.</a></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.lopau.com/create-a-web-service-using-soap/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>3D Augmented Reality platform(QR+AR) for iPhone, iPad, Android, BB</title>
		<link>http://blog.lopau.com/3d-augmented-reality-platformqrar-for-iphone-ipad-android-bb/</link>
		<comments>http://blog.lopau.com/3d-augmented-reality-platformqrar-for-iphone-ipad-android-bb/#comments</comments>
		<pubDate>Sun, 04 Sep 2011 06:00:52 +0000</pubDate>
		<dc:creator>lopau</dc:creator>
				<category><![CDATA[Mobile Development]]></category>
		<category><![CDATA[Web Resources]]></category>
		<category><![CDATA[Augmented Reality]]></category>

		<guid isPermaLink="false">http://blog.lopau.com/?p=1494</guid>
		<description><![CDATA[Technology is really moving fast, saw this in my mailing list and is truly amazing. Its a 3D Augmented reality field solution that works on smartphones. AR Jewelry &#8211; Platform for demonstration of products (jewelry, toys etc) using the 3D Augmented Reality technology. The list of products in this application is downloaded from Internet allowing [...]]]></description>
			<content:encoded><![CDATA[<p>Technology is really moving fast, saw this in my mailing list and is truly amazing. Its a 3D Augmented reality field solution that works on smartphones.</p>
<p>AR Jewelry &#8211; Platform for demonstration of products (jewelry, toys etc) using the 3D Augmented Reality technology.</p>
<p><iframe title="YouTube video player" class="youtube-player" type="text/html" width="425" height="344" src="http://www.youtube.com/embed/hlc-UKjBXVM" frameborder="0" allowFullScreen="true"> </iframe> </p>
<p>The list of products in this application is downloaded from Internet allowing to add dynamically new products to the server and demonstrate them to users.</p>
<p>Ready to licence it(as white label) to third parties(advertising agencies, jewelry/toys etc producers etc) etc.</p>
<p>More AR solutions: <a href="http://ar23d.com ">http://ar23d.com </a></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.lopau.com/3d-augmented-reality-platformqrar-for-iphone-ipad-android-bb/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Consuming Social Media Theory</title>
		<link>http://blog.lopau.com/consuming-social-media-theory/</link>
		<comments>http://blog.lopau.com/consuming-social-media-theory/#comments</comments>
		<pubDate>Wed, 06 Apr 2011 14:18:27 +0000</pubDate>
		<dc:creator>lopau</dc:creator>
				<category><![CDATA[apple]]></category>
		<category><![CDATA[Ipad]]></category>
		<category><![CDATA[Web Resources]]></category>

		<guid isPermaLink="false">http://blog.lopau.com/?p=1217</guid>
		<description><![CDATA[With all the social media found in the web its easy to get hanged up and unknowingly spend alot more time on consuming media like reading RSS feeds, checking Facebook, Twitter, reading blogs, etc than getting real work done. I just saw a video shared to me on Facebook made by Ed Dale on how [...]]]></description>
			<content:encoded><![CDATA[<p>With all the social media found in the web its easy to get hanged up and unknowingly spend alot more time on consuming media like reading RSS feeds, checking Facebook, Twitter, reading blogs, etc than getting real work done.</p>
<p>I just saw a video shared to me on Facebook made by <a href="http://www.challenge.co/">Ed Dale</a> on how he keeps his edge by consuming social media in the most efficient manner and using the right technology. I very like much his approach and theory on how and when you should consume social media which is pretty simple but very much overlooked. </p>
<p>When in front of the computer you should be working and developing, consume social media when not working like when on the bed, sala or doing something else. </p>
<p> Ed uses the available resources like an Ipad which is designed to consume content and use it efficiently which he access or read for later when not in front of the computer.</p>
<p>Check out his vid below.</p>
<div class="codesnip-container" ><iframe title="YouTube video player" width="480" height="390" src="http://www.youtube.com/embed/EfjLnXez4UI" frameborder="0" allowfullscreen></iframe></div>
<p>Now I want an Ipad. Planning to get one when Ipad 2 becomes available here in the Philippines.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.lopau.com/consuming-social-media-theory/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Word Wrap on Eclipse</title>
		<link>http://blog.lopau.com/word-wrap-on-eclipse/</link>
		<comments>http://blog.lopau.com/word-wrap-on-eclipse/#comments</comments>
		<pubDate>Mon, 21 Dec 2009 15:24:40 +0000</pubDate>
		<dc:creator>lopau</dc:creator>
				<category><![CDATA[Web Resources]]></category>

		<guid isPermaLink="false">http://blog.lopau.com/?p=540</guid>
		<description><![CDATA[Over the past few months I&#8217;ve changed my working environment(IDE) for PHP from Dreamweaver, which I have been using for the last past years with occasional use of PHP Designer 2007, 2008. It did the work but I wanted more features and tools. Then I switched to ZendStudio built on Eclipse. It was complete and [...]]]></description>
			<content:encoded><![CDATA[<p>Over the past few months I&#8217;ve changed my working environment(IDE) for PHP from Dreamweaver, which I have been using for the last past years with occasional use of PHP Designer 2007, 2008. It did the work but I wanted more features and tools. Then I switched to ZendStudio built on Eclipse. It was complete and powerful but I find it not close to the Eclipse IDE which I loved on Flex Builder 3 built on Eclipse. So that ended me up in using a more familiar IDE which is Eclipse PDT for PHP. </p>
<p>So far it has been working great and I have all the tools I need. Just one feature missing though is the word wrapping which I rely cause its just a hassle to scroll sideways just to view the codes. Fortunately there  is a workaround to this missing functionality. </p>
<p>Found this alpha plugin if you are interested with getting this feature on Eclipse.</p>
<p><img src="http://blog.lopau.com/wp-content/uploads/2009/12/word_wrap-300x135.jpg" alt="word_wrap" title="word_wrap" width="300" height="135" class="aligncenter size-medium wp-image-805" /></p>
<p><a href="http://ahtik.com/blog/2006/06/18/first-alpha-of-eclipse-word-wrap-released/">http://ahtik.com/blog/2006/06/18/first-alpha-of-eclipse-word-wrap-released/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.lopau.com/word-wrap-on-eclipse/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Turn your face into a manga</title>
		<link>http://blog.lopau.com/turn-your-face-into-a-manga/</link>
		<comments>http://blog.lopau.com/turn-your-face-into-a-manga/#comments</comments>
		<pubDate>Mon, 22 Sep 2008 16:02:08 +0000</pubDate>
		<dc:creator>lopau</dc:creator>
				<category><![CDATA[Web Resources]]></category>
		<category><![CDATA[avatars]]></category>

		<guid isPermaLink="false">http://blog.lopau.com/?p=245</guid>
		<description><![CDATA[Face your manga, is so cute I had to try it for myself. This is as close as the options I can get. I look better in manga than for real. lol. Try it for yourself. Useful avatars in twitter and other social sites.]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.faceyourmanga.com/">Face your manga</a>, is so cute I had to try it for myself. This is as close as the options I can get. I look better in manga than for real. lol.</p>
<p><img class="aligncenter size-full wp-image-246" title="olopsmangmailcom_0e205d67" src="http://blog.lopau.com/wp-content/uploads/2008/09/olopsmangmailcom_0e205d67.jpg" alt="" width="178" height="178" /></p>
<p>Try it for yourself. Useful avatars in twitter and other social sites.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.lopau.com/turn-your-face-into-a-manga/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

