<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-262733752711874688</id><updated>2024-09-04T13:03:11.782-07:00</updated><category term="netsuite"/><category term="oauth"/><category term="sso"/><category term="ajax"/><category term="append"/><category term="back button"/><category term="c9"/><category term="c9.io"/><category term="cloud9"/><category term="concatinate"/><category term="dsHistory"/><category term="fdview"/><category term="fdviewer"/><category term="flash"/><category term="fpdf"/><category term="fpdi"/><category term="lite-server"/><category term="merge"/><category term="node"/><category term="npm start"/><category term="pdf"/><category term="pdf2swf"/><category term="php"/><category term="prototype"/><category term="swf"/><title type='text'>Zeb&#39;s Tech Blog</title><subtitle type='html'>A blog showing off some of the programming tech that I think is really cool.</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://zebulonevans.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/262733752711874688/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://zebulonevans.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Zebulon &quot;Zeb&quot; Evans</name><uri>http://www.blogger.com/profile/15619340177510289955</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='26' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiLtjESNHz8ZPip2_6NjB5CO0-ITNPZdZWNBGLKtHHRgHs4ES71xqd1MyAXHQKWCispJqky_VkIEpYX-J9yQFDK4WyTU0t9IYLFV03Z2OH4pkOgAIIBEMvq_xh0XDv6/s220/2363541388_d2f80eee98_o.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>6</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-262733752711874688.post-7785402647981550782</id><published>2017-04-22T00:32:00.000-07:00</published><updated>2017-04-22T00:39:33.740-07:00</updated><title type='text'>Karate Tour White Belt</title><content type='html'>Just some notes for me that I hope will help other people.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;iframe allowfullscreen=&quot;&quot; class=&quot;YOUTUBE-iframe-video&quot; data-thumbnail-src=&quot;https://i.ytimg.com/vi/rm25sSdsDDs/0.jpg&quot; frameborder=&quot;0&quot; height=&quot;266&quot; src=&quot;https://www.youtube.com/embed/rm25sSdsDDs?feature=player_embedded&quot; width=&quot;320&quot;&gt;&lt;/iframe&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;iframe allowfullscreen=&quot;&quot; class=&quot;YOUTUBE-iframe-video&quot; data-thumbnail-src=&quot;https://i.ytimg.com/vi/0e5wcUqhbtI/0.jpg&quot; frameborder=&quot;0&quot; height=&quot;266&quot; src=&quot;https://www.youtube.com/embed/0e5wcUqhbtI?feature=player_embedded&quot; width=&quot;320&quot;&gt;&lt;/iframe&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;iframe allowfullscreen=&quot;&quot; class=&quot;YOUTUBE-iframe-video&quot; data-thumbnail-src=&quot;https://i.ytimg.com/vi/ZFMCXPSll6U/0.jpg&quot; frameborder=&quot;0&quot; height=&quot;266&quot; src=&quot;https://www.youtube.com/embed/ZFMCXPSll6U?feature=player_embedded&quot; width=&quot;320&quot;&gt;&lt;/iframe&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;iframe allowfullscreen=&quot;&quot; class=&quot;YOUTUBE-iframe-video&quot; data-thumbnail-src=&quot;https://i.ytimg.com/vi/-MRbkuEIhbo/0.jpg&quot; frameborder=&quot;0&quot; height=&quot;266&quot; src=&quot;https://www.youtube.com/embed/-MRbkuEIhbo?feature=player_embedded&quot; width=&quot;320&quot;&gt;&lt;/iframe&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;iframe allowfullscreen=&quot;&quot; class=&quot;YOUTUBE-iframe-video&quot; data-thumbnail-src=&quot;https://i.ytimg.com/vi/CKuAZ_4FYak/0.jpg&quot; frameborder=&quot;0&quot; height=&quot;266&quot; src=&quot;https://www.youtube.com/embed/CKuAZ_4FYak?feature=player_embedded&quot; width=&quot;320&quot;&gt;&lt;/iframe&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;iframe allowfullscreen=&quot;&quot; class=&quot;YOUTUBE-iframe-video&quot; data-thumbnail-src=&quot;https://i.ytimg.com/vi/GiJBsWW4RTQ/0.jpg&quot; frameborder=&quot;0&quot; height=&quot;266&quot; src=&quot;https://www.youtube.com/embed/GiJBsWW4RTQ?feature=player_embedded&quot; width=&quot;320&quot;&gt;&lt;/iframe&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;iframe width=&quot;320&quot; height=&quot;266&quot; class=&quot;YOUTUBE-iframe-video&quot; data-thumbnail-src=&quot;https://i.ytimg.com/vi/v3j7WAXbLik/0.jpg&quot; src=&quot;https://www.youtube.com/embed/v3j7WAXbLik?feature=player_embedded&quot; frameborder=&quot;0&quot; allowfullscreen&gt;&lt;/iframe&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
Stances are here&lt;/div&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
Katas&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
https://www.youtube.com/watch?v=0e5wcUqhbtI&amp;amp;list=PLmU09dDIZfnOVfT3s5cI4HXLKI43brppn&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://zebulonevans.blogspot.com/feeds/7785402647981550782/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/262733752711874688/7785402647981550782' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/262733752711874688/posts/default/7785402647981550782'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/262733752711874688/posts/default/7785402647981550782'/><link rel='alternate' type='text/html' href='http://zebulonevans.blogspot.com/2017/04/karate-tour-white-belt.html' title='Karate Tour White Belt'/><author><name>Zebulon &quot;Zeb&quot; Evans</name><uri>http://www.blogger.com/profile/15619340177510289955</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='26' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiLtjESNHz8ZPip2_6NjB5CO0-ITNPZdZWNBGLKtHHRgHs4ES71xqd1MyAXHQKWCispJqky_VkIEpYX-J9yQFDK4WyTU0t9IYLFV03Z2OH4pkOgAIIBEMvq_xh0XDv6/s220/2363541388_d2f80eee98_o.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://img.youtube.com/vi/rm25sSdsDDs/default.jpg" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-262733752711874688.post-3453963371874439858</id><published>2016-10-17T18:00:00.000-07:00</published><updated>2016-10-17T18:00:23.139-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="c9"/><category scheme="http://www.blogger.com/atom/ns#" term="c9.io"/><category scheme="http://www.blogger.com/atom/ns#" term="cloud9"/><category scheme="http://www.blogger.com/atom/ns#" term="lite-server"/><category scheme="http://www.blogger.com/atom/ns#" term="node"/><category scheme="http://www.blogger.com/atom/ns#" term="npm start"/><title type='text'>Angular 2 Quickstart on Cloud 9</title><content type='html'>&lt;h2&gt;
Angular 2 Quickstart on Cloud 9&lt;/h2&gt;
&lt;div&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjAaXV7vx5osVbbXZWgTcOs2qJ5HlRbhawHy3wu6gFVHRG9drVdc4wiGapTrVs28f-w6dRg5COzCNgKSV1Di5PmGAxrMPJLeuxfZD4FScezZtto9lViQwJXRl_JfMiEZD24DLgN0Lr3rjo/s1600/nodestart.PNG&quot; imageanchor=&quot;1&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;150&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjAaXV7vx5osVbbXZWgTcOs2qJ5HlRbhawHy3wu6gFVHRG9drVdc4wiGapTrVs28f-w6dRg5COzCNgKSV1Di5PmGAxrMPJLeuxfZD4FScezZtto9lViQwJXRl_JfMiEZD24DLgN0Lr3rjo/s400/nodestart.PNG&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;h3&gt;
Introduction&lt;/h3&gt;
&lt;div&gt;
I had some issues getting the &lt;a href=&quot;https://angular.io/docs/ts/latest/quickstart.html&quot; target=&quot;_blank&quot;&gt;Angular 2 Quickstart&lt;/a&gt; app to work on &lt;a href=&quot;https://c9.io/&quot; target=&quot;_blank&quot;&gt;Cloud 9&lt;/a&gt;.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
I followed another tutorial out there. &amp;nbsp;I don&#39;t remember which and it stated to start with a PHP project so I did.&lt;/div&gt;
&lt;h3&gt;
Upgrade Node&lt;/h3&gt;
&lt;div&gt;
First I had to upgrade node.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Run these commands to see if you are at the appropriate version for the Angular 2 Quckstart:&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
node -v&lt;/div&gt;
&lt;div&gt;
npm -v&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
My node version was okay, but my npm version was too low so I upgraded them using these commands:&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
nvm install 5.5.0&lt;/div&gt;
&lt;div&gt;
nvm use 5.5.0&lt;/div&gt;
&lt;div&gt;
nvm alias default v5.5.0&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Everything went fine until I wanted to preview my app. &amp;nbsp;Then things went a little sideways as lite-server defaults to port 3000 and we need 8080 for Cloud 9.&lt;/div&gt;
&lt;h3&gt;
Change the Default Port with lite-server to 8080 for Cloud 9&lt;/h3&gt;
&lt;div&gt;
At this point I created a file in my angular-quickstart directory called bs-config.json and put in this content:&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;div&gt;
{&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; &quot;port&quot;: 8080&lt;/div&gt;
&lt;div&gt;
}&lt;/div&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Now lite-server will start on port 8080 when you run npm start. &amp;nbsp;You can now use the Preview button up top and bring up your app.&lt;br /&gt;
&lt;h3&gt;
Conclusion&lt;/h3&gt;
&lt;/div&gt;
&lt;div&gt;
I hope this saves someone some time!&lt;br /&gt;
&lt;br /&gt;
Now onto the &lt;a href=&quot;https://angular.io/docs/ts/latest/tutorial/&quot; target=&quot;_blank&quot;&gt;Tour of Heros Tutorial&lt;/a&gt;.&lt;br /&gt;
&lt;br /&gt;
Also I&#39;m curious what you all are using. &amp;nbsp;I&#39;m planning on looking into React/Redux, Polymer, as well as Ember. &amp;nbsp;I do like one framework with &quot;all&quot; the tooling I will need thus my attraction to Angular 2.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://zebulonevans.blogspot.com/feeds/3453963371874439858/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/262733752711874688/3453963371874439858' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/262733752711874688/posts/default/3453963371874439858'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/262733752711874688/posts/default/3453963371874439858'/><link rel='alternate' type='text/html' href='http://zebulonevans.blogspot.com/2016/10/angular-2-quickstart-on-cloud-9.html' title='Angular 2 Quickstart on Cloud 9'/><author><name>Zebulon &quot;Zeb&quot; Evans</name><uri>http://www.blogger.com/profile/15619340177510289955</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='26' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiLtjESNHz8ZPip2_6NjB5CO0-ITNPZdZWNBGLKtHHRgHs4ES71xqd1MyAXHQKWCispJqky_VkIEpYX-J9yQFDK4WyTU0t9IYLFV03Z2OH4pkOgAIIBEMvq_xh0XDv6/s220/2363541388_d2f80eee98_o.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjAaXV7vx5osVbbXZWgTcOs2qJ5HlRbhawHy3wu6gFVHRG9drVdc4wiGapTrVs28f-w6dRg5COzCNgKSV1Di5PmGAxrMPJLeuxfZD4FScezZtto9lViQwJXRl_JfMiEZD24DLgN0Lr3rjo/s72-c/nodestart.PNG" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-262733752711874688.post-8946256131767878276</id><published>2012-10-12T12:02:00.002-07:00</published><updated>2012-10-12T12:02:51.051-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="netsuite"/><category scheme="http://www.blogger.com/atom/ns#" term="oauth"/><category scheme="http://www.blogger.com/atom/ns#" term="sso"/><title type='text'>Netsuite SSO OAuth Verify Call Failed</title><content type='html'>My SSO with Netsuite was working fine last night.&amp;nbsp; Today I keep getting Verify Call Failed and Authorization Required.&lt;br /&gt;
&lt;br /&gt;
I checked the history of my files and no code had been changed.&amp;nbsp; I changed my shared secret with no avail.&amp;nbsp; Last time I had problems with that I had a ! in there and it was not working.&lt;br /&gt;
&lt;br /&gt;
So then I checked the timestamps and noticed that the time on my server was about 15 minutes off.&amp;nbsp; Updated the server time and everything started working again.&lt;br /&gt;
&lt;br /&gt;
Hopefully this saves someone a few minutes wondering what the heck is going on.</content><link rel='replies' type='application/atom+xml' href='http://zebulonevans.blogspot.com/feeds/8946256131767878276/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/262733752711874688/8946256131767878276' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/262733752711874688/posts/default/8946256131767878276'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/262733752711874688/posts/default/8946256131767878276'/><link rel='alternate' type='text/html' href='http://zebulonevans.blogspot.com/2012/10/netsuite-sso-oauth-verify-call-failed.html' title='Netsuite SSO OAuth Verify Call Failed'/><author><name>Zebulon &quot;Zeb&quot; Evans</name><uri>http://www.blogger.com/profile/15619340177510289955</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='26' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiLtjESNHz8ZPip2_6NjB5CO0-ITNPZdZWNBGLKtHHRgHs4ES71xqd1MyAXHQKWCispJqky_VkIEpYX-J9yQFDK4WyTU0t9IYLFV03Z2OH4pkOgAIIBEMvq_xh0XDv6/s220/2363541388_d2f80eee98_o.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-262733752711874688.post-4253514366425776403</id><published>2012-10-10T16:24:00.001-07:00</published><updated>2012-10-12T12:03:04.977-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="netsuite"/><category scheme="http://www.blogger.com/atom/ns#" term="oauth"/><category scheme="http://www.blogger.com/atom/ns#" term="sso"/><title type='text'>PHP Netsuite SSO with PHPToolkit.php</title><content type='html'>A quick post to get everyone started without wasting time like I did on getting PHP SSO to work with Netsuite.&lt;br /&gt;
&lt;br /&gt;
The PHPToolkit.php has a couple of bugs in it that would take about 2 minutes to fix up.&amp;nbsp; I&#39;ll show you how.&lt;br /&gt;
&lt;br /&gt;
Another problem is that the sample ssoVerify.php makes calls to a modified version of PHPToolkit.php, but I can&#39;t find that modified version anywhere.&lt;br /&gt;
&lt;br /&gt;
Let&#39;s get started.&amp;nbsp; &lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;
Global Problem&lt;/h3&gt;
First change the globals around with the require at the top of PHPToolkit.php to match this:&lt;br /&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
global $myDirectory;&lt;br /&gt;
global $endpoint;&lt;br /&gt;
require_once &#39;directory_v2011.2.php&#39;;&lt;br /&gt;
$version = &quot;2011_2r1&quot;;&lt;br /&gt;
&amp;nbsp;&lt;/blockquote&gt;
&amp;nbsp;Second change this function to match this:&lt;br /&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
function getNameSpace($complexTypeName, $namespaces=null) {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; global $myDirectory;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; ...&lt;br /&gt;
&amp;nbsp;&lt;/blockquote&gt;
Now we should at least be able to&amp;nbsp;do the SSO.&amp;nbsp; Now onto the problem with makeing webservices calls after we have SSO working.&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;
Calling Netsuite Web Services after SSO&lt;/h3&gt;
The final problem is hinted at by the call in ssoVerify.php that does not match up with the constructor signature in PHPToolkit.php.&lt;br /&gt;
&lt;br /&gt;
From ssoVerify.php:&lt;br /&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
&amp;nbsp;// Sadly soapClient does not use the http portion of the stream_context variable.&lt;br /&gt;
&amp;nbsp;// We have to hack the user_agent HTTP Header Instead.&lt;br /&gt;
&amp;nbsp;$myNSclient = new nsClient( &#39;https://webservices.netsuite.com&#39;,&amp;nbsp;&amp;nbsp;makeOAuthHeaderString($oauth_token));&lt;/blockquote&gt;
&amp;nbsp;Even more sadly is that in PHPToolkit.php nothing is done with the second arguement.&lt;br /&gt;
&lt;br /&gt;
Change PHPToolkit.php to hack the user_agent header like the dev said we would:&lt;br /&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; function __construct ( $host=nsHost::live, $str_auth_header = &quot;&quot; ) {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; global $endpoint;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; global $version;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ...&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; $this-&amp;gt;client = new SoapClient( $host . &quot;/wsdl/v&quot; . $endpoint . &quot;_0/netsuite.wsdl&quot;,&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; array(&amp;nbsp; &quot;location&quot;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; =&amp;gt; $host . &quot;/services/NetSuitePort_&quot; . $endpoint,&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &quot;trace&quot;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; =&amp;gt; 1,&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &quot;connection_timeout&quot;&amp;nbsp;&amp;nbsp;&amp;nbsp; =&amp;gt; 60,&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &quot;typemap&quot;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; =&amp;gt; $typemap,&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &quot;user_agent&quot;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; =&amp;gt; &quot;PHP-SOAP/&quot; . phpversion() . &quot; + NetSuite PHP Toolkit &quot; . $version . &quot;\r\n&quot; . $str_auth_header));&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;br /&gt;
&amp;nbsp;&lt;/blockquote&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
&lt;/blockquote&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
&lt;/blockquote&gt;
</content><link rel='replies' type='application/atom+xml' href='http://zebulonevans.blogspot.com/feeds/4253514366425776403/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/262733752711874688/4253514366425776403' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/262733752711874688/posts/default/4253514366425776403'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/262733752711874688/posts/default/4253514366425776403'/><link rel='alternate' type='text/html' href='http://zebulonevans.blogspot.com/2012/10/php-netsuite-sso-with-phptoolkitphp.html' title='PHP Netsuite SSO with PHPToolkit.php'/><author><name>Zebulon &quot;Zeb&quot; Evans</name><uri>http://www.blogger.com/profile/15619340177510289955</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='26' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiLtjESNHz8ZPip2_6NjB5CO0-ITNPZdZWNBGLKtHHRgHs4ES71xqd1MyAXHQKWCispJqky_VkIEpYX-J9yQFDK4WyTU0t9IYLFV03Z2OH4pkOgAIIBEMvq_xh0XDv6/s220/2363541388_d2f80eee98_o.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-262733752711874688.post-6876431278952571073</id><published>2009-01-12T14:13:00.000-08:00</published><updated>2009-01-12T14:34:35.808-08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="append"/><category scheme="http://www.blogger.com/atom/ns#" term="concatinate"/><category scheme="http://www.blogger.com/atom/ns#" term="fdview"/><category scheme="http://www.blogger.com/atom/ns#" term="fdviewer"/><category scheme="http://www.blogger.com/atom/ns#" term="flash"/><category scheme="http://www.blogger.com/atom/ns#" term="fpdf"/><category scheme="http://www.blogger.com/atom/ns#" term="fpdi"/><category scheme="http://www.blogger.com/atom/ns#" term="merge"/><category scheme="http://www.blogger.com/atom/ns#" term="pdf"/><category scheme="http://www.blogger.com/atom/ns#" term="pdf2swf"/><category scheme="http://www.blogger.com/atom/ns#" term="php"/><category scheme="http://www.blogger.com/atom/ns#" term="swf"/><title type='text'>View PDF Files in Flash using PHP</title><content type='html'>I&#39;m currently working on how to view PDF files in Flash.  The first problem was that of merging or appending PDF files using PHP.  This problem was solved using FPDF &lt;a href=&quot;http://www.fpdf.org/&quot;&gt;http://www.fpdf.org/&lt;/a&gt; with FPDI &lt;a href=&quot;http://www.setasign.de/products/pdf-php-solutions/fpdi/&quot;&gt;http://www.setasign.de/products/pdf-php-solutions/fpdi/ &lt;/a&gt;and the following example from FPDI &lt;a href=&quot;http://www.setasign.de/products/pdf-php-solutions/fpdi/demos/concatenate-fake/&quot;&gt;http://www.setasign.de/products/pdf-php-solutions/fpdi/demos/concatenate-fake/&lt;/a&gt;. &lt;br /&gt;&lt;br /&gt;Now that we have the ability to concatenate PDF files using PHP now onto the converting PDF files to SWF Flash files with a viewer similar to the one at &lt;a href=&quot;http://www.scribd.com&quot;&gt;Scribd&lt;/a&gt;.  Looking into this has led me to many resources.  I think I&#39;m going to use swftools with the pdf2swf from &lt;a href=&quot;http://www.swftools.org/&quot;&gt;http://www.swftools.org/&lt;/a&gt;.  This comes with a viewer and I found the source code for FDVIEW here &lt;a href=&quot;http://www.code4net.com/2005/11/05/fdview/&quot;&gt;http://www.code4net.com/2005/11/05/fdview/&lt;/a&gt; in a comment at the bottom with an example here &lt;a href=&quot;http://www.code4net.com/archives/000114.html#114&quot;&gt;http://www.code4net.com/archives/000114.html#114&lt;/a&gt;. &lt;br /&gt;&lt;br /&gt;With these resources I&#39;m confident that I can use or polish the FDVIEW to achieve the PDF viewing in Flash in a clean way. &lt;br /&gt;&lt;br /&gt;I&#39;ll keep you posted.</content><link rel='replies' type='application/atom+xml' href='http://zebulonevans.blogspot.com/feeds/6876431278952571073/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/262733752711874688/6876431278952571073' title='8 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/262733752711874688/posts/default/6876431278952571073'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/262733752711874688/posts/default/6876431278952571073'/><link rel='alternate' type='text/html' href='http://zebulonevans.blogspot.com/2009/01/view-pdf-files-in-flash-using-php.html' title='View PDF Files in Flash using PHP'/><author><name>Zebulon &quot;Zeb&quot; Evans</name><uri>http://www.blogger.com/profile/15619340177510289955</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='26' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiLtjESNHz8ZPip2_6NjB5CO0-ITNPZdZWNBGLKtHHRgHs4ES71xqd1MyAXHQKWCispJqky_VkIEpYX-J9yQFDK4WyTU0t9IYLFV03Z2OH4pkOgAIIBEMvq_xh0XDv6/s220/2363541388_d2f80eee98_o.jpg'/></author><thr:total>8</thr:total></entry><entry><id>tag:blogger.com,1999:blog-262733752711874688.post-158647235554774606</id><published>2008-04-28T11:01:00.000-07:00</published><updated>2008-04-28T14:39:33.918-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="ajax"/><category scheme="http://www.blogger.com/atom/ns#" term="back button"/><category scheme="http://www.blogger.com/atom/ns#" term="dsHistory"/><category scheme="http://www.blogger.com/atom/ns#" term="prototype"/><title type='text'>Enable the Back Button with dsHistory and prototype in an AJAX Application</title><content type='html'>&lt;span style=&quot;font-size:180%;&quot;&gt;&lt;br /&gt;Introduction&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;A common problem with AJAX applications is that they break the back button functionality from a user&#39;s perspective.  While coding &lt;a href=&quot;http://www.givegroup.com/&quot;&gt;GiveGroup&lt;/a&gt; Craig Tran and I ran into this problem.  Our AJAX application uses the Zend Framework and the prototype JavaScript library.  We looked into a few options to enable the back button support, but they did not seem to blend with our implementation well until we looked into the &lt;a href=&quot;http://code.google.com/p/dshistory/&quot;&gt;dsHistory&lt;/a&gt; library.&lt;br /&gt;&lt;br /&gt;We decided to use dsHistory because it allows us to push function calls with an argument object onto a history stack that will be popped off when the user hits the back button.  This worked very well in our implementation because we could pass the div to update, the controller and action pair to call, and the options array into a function, push it onto the history stack, and then call the Ajax.Updater method to fetch the new content.  When the user hits the back button those old calls and their arguments are popped off the stack and ran again emulating returning to the previous page.&lt;br /&gt;&lt;br /&gt;In this example I&#39;m going to try to keep the code as simple as possible to illustrate the technique we used with dsHistory and prototype.  Due to this it will feel a little contrived, but will give you a good start into seeing how to put it into your own application.&lt;br /&gt;&lt;br /&gt;&lt;span&gt;Requirements:&lt;/span&gt;&lt;br /&gt;&lt;ol&gt;&lt;li&gt;PHP 5 Server ( I would recommend &lt;a href=&quot;http://www.apachefriends.org/en/xampp.html&quot;&gt;XAMMP&lt;/a&gt; if you are new )&lt;br /&gt;&lt;/li&gt;&lt;li&gt;The &lt;a href=&quot;http://code.google.com/p/dshistory/&quot;&gt;dsHistory&lt;/a&gt; JavaScript library version 1&lt;br /&gt;&lt;/li&gt;&lt;li&gt;The &lt;a href=&quot;http://www.prototypejs.org/&quot;&gt;prototype&lt;/a&gt; JavaScript library version 1.6&lt;br /&gt;&lt;/li&gt;&lt;li&gt;A &lt;a href=&quot;http://www.mozilla.com/en-US/firefox/&quot;&gt;modern browser&lt;/a&gt;&lt;/li&gt;&lt;/ol&gt;First we will look at the server side code, then at the client site code.&lt;br /&gt;&lt;br /&gt;&lt;span&gt;&lt;span style=&quot;font-size:130%;&quot;&gt;Server Side - index.php&lt;/span&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;The server side index.php will parse the requested action and serve back the base index page if an action or index was requested.  If a specific action was requested it will serve back just an html snippet to load in the mainContent div.&lt;br /&gt;&lt;pre&gt;&lt;code&gt;&lt;br /&gt;&lt;span style=&quot;font-size:78%;&quot;&gt;&amp;lt;?php&lt;br /&gt;// array of allowed actions&lt;br /&gt;$actionFilter = array( &#39;index&#39;, &#39;welcome&#39;, &#39;content1&#39;, &#39;content2&#39; );&lt;br /&gt;&lt;br /&gt;// get the requested action, if none exists serve the index page&lt;br /&gt;$action = isset($_GET[&#39;action&#39;]) ? $_GET[&#39;action&#39;] : &#39;index&#39;;&lt;br /&gt;&lt;br /&gt;// if an unsupported action is requested return an error message&lt;br /&gt;if( !in_array( $action, $actionFilter ) ){&lt;br /&gt;$action = &#39;error&#39;;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;// based on the action return some content&lt;br /&gt;switch( $action ){&lt;br /&gt;case &#39;welcome&#39;:&lt;br /&gt; echo &quot;This is the initial state of the application.&quot;;&lt;br /&gt; echo &quot;&amp;lt;br /&amp;gt;&amp;lt;a href=\&quot;javascript:navigate(&#39;content1&#39;);\&quot;&amp;gt;next page&amp;lt;/a&amp;gt;&quot;;&lt;br /&gt; break;&lt;br /&gt;case &#39;content1&#39;:&lt;br /&gt; echo &quot;This is content 1.&quot;;&lt;br /&gt; echo &quot;&amp;lt;br /&amp;gt;&amp;lt;a href=\&quot;javascript:navigate(&#39;content2&#39;);\&quot;&amp;gt;next page&amp;lt;/a&amp;gt;&quot;;&lt;br /&gt; break;&lt;br /&gt;case &#39;content2&#39;:&lt;br /&gt; echo &quot;This is content 2.&quot;;&lt;br /&gt; break;&lt;br /&gt;case &#39;index&#39;:&lt;br /&gt; echo file_get_contents(&#39;content.htm&#39;);&lt;br /&gt; break;&lt;br /&gt;default:&lt;br /&gt; echo &quot;An unsupported action was requested.&quot;;&lt;br /&gt; break;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;?&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;span style=&quot;font-size:130%;&quot;&gt;Client Side - content.htm&lt;br /&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;The html coded for our client side is very simple.  In the body it consists of a single div with an id of &#39;mainContent&#39;.  This div will hold the results returned by our server side PHP script.  You will notice that when the page first loads we call navigate(&#39;welcome&#39;) this will then call updateContent with everything the Ajax.Updater needs to know.  The dsHistory script will store the function call with the arguments onto the history stack and we have just set our base state.  From this point the back button will not do anything on the browser until the next call since dsHistory sees the first entry as what it needs to do to bring your application back to its initial state.  You can think of this as everything you would have to do to setup the home page.&lt;br /&gt;&lt;br /&gt;As the user clicks the &#39;next page&#39; links the server will serve the appropriate html snippets and dsHistory will manage the stack.  Notice that the back and forward buttons work like the user would expect.&lt;span style=&quot;font-size:130%;&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;pre&gt;&lt;span style=&quot;font-size:78%;&quot;&gt;&lt;code&gt;&amp;lt;html&amp;gt;&lt;br /&gt;&amp;lt;head&amp;gt;&lt;br /&gt;&amp;lt;title&amp;gt;Fix the Back Button with AJAX, dsHistory, and prototype&amp;lt;/title&amp;gt;&lt;br /&gt;&amp;lt;script type=&quot;text/javascript&quot; language=&quot;javascript&quot; src=&quot;prototype-1.6.0.2.js&quot;&amp;gt;&amp;lt;/script&amp;gt;&lt;br /&gt;&amp;lt;script type=&quot;text/javascript&quot; language=&quot;javascript&quot; src=&quot;dshistory.compressed.js&quot;&amp;gt;&amp;lt;/script&amp;gt;&lt;br /&gt;&amp;lt;SCRIPT&amp;gt;&lt;br /&gt;&amp;lt;!-- Begin to hide script contents from old browsers.&lt;br /&gt;&lt;br /&gt;function navigate( page ){&lt;br /&gt;var params = &quot;action=&quot; + page;&lt;br /&gt;&lt;br /&gt;// in a real application we would have an action, but for our&lt;br /&gt;// purposes we&#39;ll just use a parameter&lt;br /&gt;var args = {&lt;br /&gt; target:&#39;mainContent&#39;,&lt;br /&gt; action: &#39;&#39;,&lt;br /&gt; options: { method: &#39;get&#39;, parameters: params }&lt;br /&gt;};&lt;br /&gt;&lt;br /&gt;updateContent( args );&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;function updateContent( args, historyObject ) {&lt;br /&gt;// store the function that loaded the &#39;page&#39; onto the stack.&lt;br /&gt;// the history object helps us to know if this was called from&lt;br /&gt;// history because if it was we shouldn&#39;t push it on the stack.&lt;br /&gt;if (!historyObject || !historyObject.calledFromHistory) {&lt;br /&gt;   dsHistory.addFunction( updateContent, this, args );&lt;br /&gt; }&lt;br /&gt; // update the page with prototype&lt;br /&gt;new Ajax.Updater(args[&#39;target&#39;], args[&#39;action&#39;], args[&#39;options&#39;]);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;// End the hiding here. --&amp;gt;&lt;br /&gt;&amp;lt;/SCRIPT&amp;gt;&lt;br /&gt;&amp;lt;/head&amp;gt;&lt;br /&gt;&amp;lt;body onLoad=&quot;navigate(&#39;welcome&#39;);&quot;&amp;gt;&lt;br /&gt;&amp;lt;div id=&#39;mainContent&#39;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&amp;lt;/body&amp;gt;&lt;br /&gt;&amp;lt;/html&amp;gt;&lt;br /&gt;&lt;/code&gt;&lt;/span&gt;&lt;/pre&gt;&lt;span style=&quot;font-size:130%;&quot;&gt;Extending the Example&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;With GiveGroup we had some &quot;pages&quot; that required multiple AJAX calls to form.  We had a mainContent and subContent divs and we would sometimes change both based on user interaction and we wanted to treat that set of function calls as a &quot;page&quot; for the user.  If you study the example you can see how it would be easy to add multiple function calls to our implementation on the dsHistory stack.  All you would need to do is modify  the args in updateContent to be an array of the current objects that they are now, and loop over them and call Ajax.Updater for each one.  This way when the args are pushed onto the dsHistory stack they represent one or many AJAX updates to update multiple divs at once.&lt;br /&gt;&lt;br /&gt;We could also extend the example to include JSON responses.  We needed this functionality in GiveGroup as well.  To keep &quot;pages&quot; on the stack that are simple JSON responses from the server make another function similar to updateContent called getResponse and call Ajax.Request instead of Ajax.Updater with your params.  Make sure to the callback function to process your JSON response.&lt;br /&gt;&lt;br /&gt;You could also use dsHistory to push the server responses onto the stack instead of the server requests creating a client side cache so that when the user hits the back and forward buttons the server is not called at all.  You would have to see if this is appropriate for your application, and perhaps we will cover it in a future blog post.&lt;br /&gt;&lt;br /&gt;- Zebulon ( Zeb ) Evans&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-size:180%;&quot;&gt;&lt;span style=&quot;font-size:100%;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;a href=&quot;http://www.givegroup.com/&quot;&gt;&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://zebulonevans.blogspot.com/feeds/158647235554774606/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/262733752711874688/158647235554774606' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/262733752711874688/posts/default/158647235554774606'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/262733752711874688/posts/default/158647235554774606'/><link rel='alternate' type='text/html' href='http://zebulonevans.blogspot.com/2008/04/enable-back-button-with-dshistory-and.html' title='Enable the Back Button with dsHistory and prototype in an AJAX Application'/><author><name>Zebulon &quot;Zeb&quot; Evans</name><uri>http://www.blogger.com/profile/15619340177510289955</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='26' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiLtjESNHz8ZPip2_6NjB5CO0-ITNPZdZWNBGLKtHHRgHs4ES71xqd1MyAXHQKWCispJqky_VkIEpYX-J9yQFDK4WyTU0t9IYLFV03Z2OH4pkOgAIIBEMvq_xh0XDv6/s220/2363541388_d2f80eee98_o.jpg'/></author><thr:total>0</thr:total></entry></feed>