<?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>Trustap Test Store</title>
	<atom:link href="http://blog.pepa.info/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.pepa.info</link>
	<description>Petr 'PePa' Pavel</description>
	<lastBuildDate>Fri, 17 Jun 2016 13:55:21 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.1</generator>
	<item>
		<title>nivoSlider transition effects list and gallery</title>
		<link>http://blog.pepa.info/php-html-css/tools/nivoslider-transition-effects-list-and-gallery/</link>
					<comments>http://blog.pepa.info/php-html-css/tools/nivoslider-transition-effects-list-and-gallery/#respond</comments>
		
		<dc:creator><![CDATA[Petr 'PePa' Pavel]]></dc:creator>
		<pubDate>Fri, 17 Jun 2016 13:51:15 +0000</pubDate>
				<category><![CDATA[Tools]]></category>
		<guid isPermaLink="false">http://blog.pepa.info/?p=534</guid>

					<description><![CDATA[The official nivoSlider documentation misses two transition effects and provides no visual demonstration of what they do. I&#8217;m here to fix this. nivoSlider Effects Demo All nivoSlider Effects sliceDown sliceDownLeft sliceDownRight sliceUp sliceUpLeft sliceUpRight sliceUpDown sliceUpDownLeft fold fade random slideInRight slideInLeft boxRandom boxRain boxRainReverse boxRainGrow boxRainGrowReverse]]></description>
										<content:encoded><![CDATA[<p>The official <a href="http://docs.dev7studios.com/article/13-nivo-slider-settings" target="_blank">nivoSlider documentation</a> misses two transition effects and provides no visual demonstration of what they do. I&#8217;m here to fix this.</p>
<div>
<link rel="stylesheet" href="/nivo-slider.css" type="text/css" scoped>
<style scoped>
  .nivo-directionNav a {
    font-size: 30px;
    display: inline-block;
    margin: 0 10px;
  }
  .nivo-controlNav a {
    font-size: 20px;
    margin-right: 6px;
    display: inline-block;
  }
  .nivo-directionNav a:hover,
  .nivo-controlNav a {
    text-decoration: none;
  }
</style>
<p><script src="//ajax.googleapis.com/ajax/libs/jquery/1.10.1/jquery.min.js" type="text/javascript"></script><br />
<script src="/jquery.nivo.slider.pack.js" type="text/javascript"></script></p>
<h2 style="margin-bottom: 10px;">nivoSlider Effects Demo</h2>
<div id="slider" class="nivoSlider">
  <img decoding="async"
    src="https://placehold.it/450x200/69D2E7?text=sliceDown" data-transition="sliceDown" alt=""><img decoding="async"
    src="https://placehold.it/450x200/A7DBD8?text=sliceDownLeft" data-transition="sliceDownLeft" alt=""><img decoding="async"
    src="https://placehold.it/450x200/E0E4CC?text=sliceDownRight" data-transition="sliceDownRight" alt=""><img decoding="async"
    src="https://placehold.it/450x200/F38630?text=sliceUp" data-transition="sliceUp" alt=""><img decoding="async"
    src="https://placehold.it/450x200/FA6900?text=sliceUpLeft" data-transition="sliceUpLeft" alt=""><img decoding="async"
    src="https://placehold.it/450x200/69D2E7?text=sliceUpRight" data-transition="sliceUpRight" alt=""><img decoding="async"
    src="https://placehold.it/450x200/A7DBD8?text=sliceUpDown" data-transition="sliceUpDown" alt=""><img decoding="async"
    src="https://placehold.it/450x200/E0E4CC?text=sliceUpDownLeft" data-transition="sliceUpDownLeft" alt=""><img decoding="async"
    src="https://placehold.it/450x200/F38630?text=fold" data-transition="fold" alt=""><img decoding="async"
    src="https://placehold.it/450x200/FA6900?text=fade" data-transition="fade" alt=""><img decoding="async"
    src="https://placehold.it/450x200/A7DBD8?text=slideInRight" data-transition="slideInRight" alt=""><img decoding="async"
    src="https://placehold.it/450x200/E0E4CC?text=slideInLeft" data-transition="slideInLeft" alt=""><img decoding="async"
    src="https://placehold.it/450x200/F38630?text=boxRandom" data-transition="boxRandom" alt=""><img decoding="async"
    src="https://placehold.it/450x200/FA6900?text=boxRain" data-transition="boxRain" alt=""><img decoding="async"
    src="https://placehold.it/450x200/69D2E7?text=boxRainReverse" data-transition="boxRainReverse" alt=""><img decoding="async"
    src="https://placehold.it/450x200/A7DBD8?text=boxRainGrow" data-transition="boxRainGrow" alt=""><img decoding="async"
    src="https://placehold.it/450x200/E0E4CC?text=boxRainGrowReverse" data-transition="boxRainGrowReverse" alt="">
</div>
</div>
<p><script type="text/javascript">
  $(window).load(function() {
    $('#slider').nivoSlider({
      prevText: '&laquo;',
      nextText: '&raquo;'
    }).data('nivoslider').stop();
  });
</script></p>
<h2>All nivoSlider Effects</h2>
<ul>
<li>sliceDown</li>
<li>sliceDownLeft</li>
<li>sliceDownRight</li>
<li>sliceUp</li>
<li>sliceUpLeft</li>
<li>sliceUpRight</li>
<li>sliceUpDown</li>
<li>sliceUpDownLeft</li>
<li>fold</li>
<li>fade</li>
<li>random</li>
<li>slideInRight</li>
<li>slideInLeft</li>
<li>boxRandom</li>
<li>boxRain</li>
<li>boxRainReverse</li>
<li>boxRainGrow</li>
<li>boxRainGrowReverse</li>
</ul>
]]></content:encoded>
					
					<wfw:commentRss>http://blog.pepa.info/php-html-css/tools/nivoslider-transition-effects-list-and-gallery/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Composer not autoloading your package?</title>
		<link>http://blog.pepa.info/php-html-css/composer/composer-not-autoloading-your-package/</link>
					<comments>http://blog.pepa.info/php-html-css/composer/composer-not-autoloading-your-package/#comments</comments>
		
		<dc:creator><![CDATA[Petr 'PePa' Pavel]]></dc:creator>
		<pubDate>Mon, 16 May 2016 11:45:50 +0000</pubDate>
				<category><![CDATA[Composer]]></category>
		<guid isPermaLink="false">http://blog.pepa.info/?p=529</guid>

					<description><![CDATA[I needed to link a GitHub hosted library into my project with composer. It was my own fork of a library that was abandoned. I didn&#8217;t want to register it with packagist.com because it already is infested with weeds of this kind. Conveniently, the library already had composer.json so I just needed to edit my [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>I needed to link a GitHub hosted library into my project with composer. It was my own fork of a library that was abandoned. I didn&#8217;t want to register it with packagist.com because it already is infested with weeds of this kind. Conveniently, the library already had composer.json so I just needed to edit my project&#8217;s composer.json and link to the library. Easy I thought.</p>
<p><span id="more-529"></span></p>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">{
</div>
</li>
<li class="li1">
<div class="de1">&#8230;
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &quot;repositories&quot;: [
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; {
</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &quot;type&quot;: &quot;package&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &quot;package&quot;: {
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &quot;name&quot;: &quot;xpavp03/nette-csv-response&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &quot;version&quot;: &quot;dev-patch-1&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &quot;source&quot;: {
</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &quot;type&quot;: &quot;git&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &quot;url&quot;: &quot;https://github.com/xpavp03/nette-csv-response.git&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &quot;reference&quot;: &quot;origin/patch-1&quot;
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; }
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; }
</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; }
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; ],
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &quot;require&quot;: {
</div>
</li>
<li class="li1">
<div class="de1">&nbsp;&#8230;
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &quot;xpavp03/nette-csv-response&quot;: &quot;dev-patch-1&quot;
</div>
</li>
<li class="li2">
<div class="de2">&nbsp; }
</div>
</li>
<li class="li1">
<div class="de1">&#8230;
</div>
</li>
<li class="li1">
<div class="de1">}
</div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
</ol>
</div>
<p>Well, it did download the files but it also created a Git repository in my vendors structure. I could work around it by excluding it during deployment but I wanted to see if I can fetch the library without it.</p>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1"> &nbsp;&quot;repositories&quot;: [
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; {
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &quot;type&quot;: &quot;package&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &quot;package&quot;: {
</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &quot;name&quot;: &quot;xpavp03/nette-csv-response&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &quot;version&quot;: &quot;dev-patch-1&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &quot;dist&quot;: {
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &quot;type&quot;: &quot;zip&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &quot;url&quot;: &quot;https://github.com/xpavp03/nette-csv-response/archive/patch-1.zip&quot;
</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; }
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; }
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; }
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; ],
</div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
</ol>
</div>
<p>Worked great but, composer didn&#8217;t include this library in its autoloading files. Mhm&#8230;</p>
<p>It turned out that if you link a library as a package composer won&#8217;t look for its composer.json. It didn&#8217;t matter that it existed and had instructions for autoloading &#8211; composer didn&#8217;t expect it there and didn&#8217;t try looking. So the solution was to include autoloading instructions into my project&#8217;s composer.json:</p>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1"> &nbsp;&quot;repositories&quot;: [
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; {
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &quot;type&quot;: &quot;package&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &quot;package&quot;: {
</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; &quot;name&quot;: &quot;xpavp03/nette-csv-response&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &quot;version&quot;: &quot;dev-patch-1&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &quot;dist&quot;: {
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &quot;type&quot;: &quot;zip&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &quot;url&quot;: &quot;https://github.com/xpavp03/nette-csv-response/archive/patch-1.zip&quot;
</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; &nbsp; &nbsp; }
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &quot;autoload&quot;: {
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &quot;classmap&quot;: [&quot;src/&quot;]
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; &nbsp; }
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &nbsp; }
</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &nbsp; }
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; ],
</div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
</ol>
</div>
<p>I wish this was mentioned in the <a href="https://getcomposer.org/doc/05-repositories.md#package-2" target="_blank">documentation</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>http://blog.pepa.info/php-html-css/composer/composer-not-autoloading-your-package/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
			</item>
		<item>
		<title>AltDrive hangs when Creating Shadow Copy [SOLVED]</title>
		<link>http://blog.pepa.info/php-html-css/tools/altdrive-hangs-when-creating-shadow-copy-solved/</link>
					<comments>http://blog.pepa.info/php-html-css/tools/altdrive-hangs-when-creating-shadow-copy-solved/#respond</comments>
		
		<dc:creator><![CDATA[Petr 'PePa' Pavel]]></dc:creator>
		<pubDate>Fri, 17 Jul 2015 11:51:11 +0000</pubDate>
				<category><![CDATA[Tools]]></category>
		<guid isPermaLink="false">http://blog.pepa.info/?p=521</guid>

					<description><![CDATA[I&#8217;ve been struggling with my online backup AltDrive recently. It seemed to continue a backup started a couple of days ago but never getting past the phase of Creating Shadow Copy. When I cancelled the backup process, I was able to start over but still the previous backup continued to hang in the progress window. [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>I&#8217;ve been struggling with my online backup AltDrive recently. It seemed to continue a backup started a couple of days ago but never getting past the phase of Creating Shadow Copy. When I cancelled the backup process, I was able to start over but still the previous backup continued to hang in the progress window. I tried all sorts of things related to shadow copy but with no avail. I uninstalled the client (keeping settings because I didn&#8217;t want to lose backed up data) and installed a fresh version, no change.</p>
<p><span id="more-521"></span>What finally helped was to delete content of <code>C:\Windows\System32\config\systemprofile\AppData\Local\AltdriveWBHomeService\tmp</code>. I suppose the hanging backup was interrupted when I shut the computer down a few days ago, and some files were left in an inconsistent state.</p>
<p>Edit: New location is C:\ProgramData\AltdriveWBHomeService\tmp</p>
]]></content:encoded>
					
					<wfw:commentRss>http://blog.pepa.info/php-html-css/tools/altdrive-hangs-when-creating-shadow-copy-solved/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>An island with a different viewModel</title>
		<link>http://blog.pepa.info/php-html-css/knockout/an-island-with-a-different-viewmodel/</link>
					<comments>http://blog.pepa.info/php-html-css/knockout/an-island-with-a-different-viewmodel/#respond</comments>
		
		<dc:creator><![CDATA[Petr 'PePa' Pavel]]></dc:creator>
		<pubDate>Fri, 05 Jun 2015 21:35:36 +0000</pubDate>
				<category><![CDATA[Knockout]]></category>
		<category><![CDATA[Knockout 3.3.0]]></category>
		<guid isPermaLink="false">http://blog.pepa.info/?p=505</guid>

					<description><![CDATA[I have a multi-page application with a navigation panel that is used across all pages. Each page has its own view model, the panel view model is the same. I could remember to always bind both models but I was hoping there would be a more universal solution. Some way to bind my one-page model [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>I have a multi-page application with a navigation panel that is used across all pages. Each page has its own view model, the panel view model is the same. I could remember to always bind both models but I was hoping there would be a more universal solution. Some way to bind my one-page model to the whole document, and yet have an island of DOM elements automatically bound to a different model.<br />
<span id="more-505"></span></p>
<p>Here&#8217;s what I knew would work, but I didn&#8217;t like:</p>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">&lt;script src=&quot;page-1.js&quot;&gt;&lt;/script&gt;
</div>
</li>
<li class="li1">
<div class="de1">&lt;div id=&quot;navigation-panel&quot; data-bind=&quot;with: navModel&quot;&gt;&#8230;&lt;/div&gt;
</div>
</li>
<li class="li1">
<div class="de1">&lt;div id=&quot;page1&quot; data-bind=&quot;with: page1Model&quot;&gt;&#8230;&lt;/div&gt;
</div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
</ol>
</div>
<p>The trouble is that I have to remember to bind navModel in <code>page-1.js</code> and all page-x scripts.</p>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">span class=&#8221;st0&#8243;>&#8217;navModel&#8217;</span><span class="st0">&#8216;page1Model&#8217;</span</div>
</li>
</ol>
</div>
<p>I didn&#8217;t want <code>page-1.js</code> to care about elements that are on every page.</p>
<h3>Solution 1: Component</h3>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">&lt;script src=&quot;navigation.js&quot;&gt;&lt;/script&gt;
</div>
</li>
<li class="li1">
<div class="de1">&lt;script src=&quot;page-1.js&quot;&gt;&lt;/script&gt;
</div>
</li>
<li class="li1">
<div class="de1">&lt;script type=&quot;text/html&quot; id=&quot;template-navigation&quot;&gt;
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &lt;div id=&quot;navigation-panel&quot;&gt;&#8230;&lt;/div&gt;
</div>
</li>
<li class="li2">
<div class="de2">&lt;/script&gt;
</div>
</li>
<li class="li1">
<div class="de1">&lt;div data-bind=&quot;component: &#8216;navigation&#8217;&quot;&gt;&lt;/div&gt;
</div>
</li>
<li class="li1">
<div class="de1">&lt;div id=&quot;page1&quot;&gt;&#8230;&lt;/div&gt;</div>
</li>
</ol>
</div>
<p>navigation.js:</p>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">span class=&#8221;st0&#8243;>&#8217;navigation&#8217;</span>, <span class="br0">&#123;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;template: <span class="br0">&#123;</span> element: <span class="st0">&#8216;template-navigation&#8217;</span> <span class="br0">&#125;</span>,</div>
</li>
<li class="li1">
<div class="de1">&nbsp;viewModel: NavModel</div>
</li>
<li class="li1">
<div class="de1"><span class="br0">&#125;</span><span class="br0">&#41;</span>;</div>
</li>
</ol>
</div>
<p>page-1.js:</p>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
</ol>
</div>
<p>This worked well but I didn&#8217;t like the extra markup. Also, I actually have several islands and I didn&#8217;t like having to define a component for each.</p>
<h3>Solution 2:  Custom binding handler</h3>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">&lt;script src=&quot;navigation.js&quot;&gt;&lt;/script&gt;
</div>
</li>
<li class="li1">
<div class="de1">&lt;script src=&quot;page-1.js&quot;&gt;&lt;/script&gt;
</div>
</li>
<li class="li1">
<div class="de1">&lt;div id=&quot;navigation-panel&quot; data-bind=&quot;viewModel: navModel&quot;&gt;&#8230;&lt;/div&gt;
</div>
</li>
<li class="li1">
<div class="de1">&lt;div id=&quot;page1&quot;&gt;&#8230;&lt;/div&gt;</div>
</li>
</ol>
</div>
<p>navigation.js:</p>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
</ol>
</div>
<p>page-1.js:</p>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
</ol>
</div>
<p>Nice and smooth. One handler takes care of all islands, all I have to do is to define a global variable for each view model.</p>
]]></content:encoded>
					
					<wfw:commentRss>http://blog.pepa.info/php-html-css/knockout/an-island-with-a-different-viewmodel/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>KO validation with Bootstrap error and feedback? Can do.</title>
		<link>http://blog.pepa.info/php-html-css/knockout/ko-validation-with-bootstrap-error-and-feedback-can-do/</link>
					<comments>http://blog.pepa.info/php-html-css/knockout/ko-validation-with-bootstrap-error-and-feedback-can-do/#respond</comments>
		
		<dc:creator><![CDATA[Petr 'PePa' Pavel]]></dc:creator>
		<pubDate>Wed, 03 Jun 2015 20:01:58 +0000</pubDate>
				<category><![CDATA[Knockout]]></category>
		<category><![CDATA[Knockout 3.3.0]]></category>
		<category><![CDATA[Knockout Validation 2.0.3]]></category>
		<guid isPermaLink="false">http://blog.pepa.info/?p=498</guid>

					<description><![CDATA[I&#8217;ve been struggling to configure Knockout Validation to use Bootstrap error classes and form-control-feedback element. Finally, it&#8217;s working and now I&#8217;m going to brag about it. It&#8217;s quite simple really ;-) &#60;div class=&#34;form-group has-feedback&#34; data-bind=&#34;validationElement: myVar&#34;&#62; &#160; &#60;label class=&#34;control-label&#34; for=&#34;myVarId&#34;&#62;Queue Name&#60;/label&#62; &#160; &#60;input id=&#34;myVarId&#34; class=&#34;form-control&#34; type=&#34;text&#34; data-bind=&#34;textInput: myVar&#34; /&#62; &#60;/div&#62; &#160; &#60;script type=&#34;text/html&#34; id=&#34;myErrorTemplate&#34;&#62;   [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>I&#8217;ve been struggling to configure Knockout Validation to use Bootstrap error classes and form-control-feedback element. Finally, it&#8217;s working and now I&#8217;m going to brag about it. It&#8217;s quite simple really ;-)<br />
<span id="more-498"></span></p>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">&lt;div class=&quot;form-group has-feedback&quot; data-bind=&quot;validationElement: myVar&quot;&gt;
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &lt;label class=&quot;control-label&quot; for=&quot;myVarId&quot;&gt;Queue Name&lt;/label&gt;
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &lt;input id=&quot;myVarId&quot; class=&quot;form-control&quot; type=&quot;text&quot; data-bind=&quot;textInput: myVar&quot; /&gt;
</div>
</li>
<li class="li1">
<div class="de1">&lt;/div&gt;
</div>
</li>
<li class="li2">
<div class="de2">&nbsp;</div>
</li>
<li class="li1">
<div class="de1">&lt;script type=&quot;text/html&quot; id=&quot;myErrorTemplate&quot;&gt;
</div>
</li>
<li class="li1">
<div class="de1">  &lt;span class=&quot;help-block&quot; data-bind=&quot;text: field.error, visible: field.isModified()&quot;&gt;&lt;/span&gt;
</div>
</li>
<li class="li1">
<div class="de1">  &lt;span class=&quot;glyphicon glyphicon-remove form-control-feedback&quot; data-bind=&quot;visible: field.isModified() &amp;amp;&amp;amp; !field.isValid()&quot;&gt;&lt;/span&gt;
</div>
</li>
<li class="li1">
<div class="de1">&lt;/script&gt;</div>
</li>
</ol>
</div>
<p>The interesting javascript part is just the configuration. Your validation rules and model bindings/observables are the usual:</p>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">span class=&#8221;st0&#8243;>&#8217;has-error&#8217;</span>,</div>
</li>
<li class="li1">
<div class="de1">&nbsp; messageTemplate: <span class="st0">&#8216;myErrorTemplate&#8217;</span></div>
</li>
<li class="li1">
<div class="de1"><span class="br0">&#125;</span><span class="br0">&#41;</span>;</div>
</li>
</ol>
</div>
<p>&nbsp;</p>
]]></content:encoded>
					
					<wfw:commentRss>http://blog.pepa.info/php-html-css/knockout/ko-validation-with-bootstrap-error-and-feedback-can-do/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>clearError() in KO Validation updates validity too</title>
		<link>http://blog.pepa.info/php-html-css/knockout/clearerror-in-ko-validation-updates-validity-too/</link>
					<comments>http://blog.pepa.info/php-html-css/knockout/clearerror-in-ko-validation-updates-validity-too/#respond</comments>
		
		<dc:creator><![CDATA[Petr 'PePa' Pavel]]></dc:creator>
		<pubDate>Mon, 01 Jun 2015 15:54:50 +0000</pubDate>
				<category><![CDATA[Knockout]]></category>
		<category><![CDATA[Knockout 3.3.0]]></category>
		<category><![CDATA[Knockout Validation 2.0.3]]></category>
		<guid isPermaLink="false">http://blog.pepa.info/?p=500</guid>

					<description><![CDATA[Let me start with the take-away message: Don&#8217;t clear errors with clearError() if you reuse your form and if you set messagesOnModified to true (default value). Now why. Say you have a Create Thingy form with a field for the new thingy name. Name is obligatory but you don&#8217;t want the creating experience to start [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>Let me start with the take-away message:</p>
<blockquote><p>Don&#8217;t clear errors with clearError() if you reuse your form and if you set messagesOnModified to true (default value).</p></blockquote>
<p>Now why. Say you have a Create Thingy form with a field for the new thingy name. Name is obligatory but you don&#8217;t want the creating experience to start with an error message. So you keep messagesOnModified at true.</p>
<p>User opens the dialog, chooses a name that is invalid and then gives up &#8211; clicks Cancel. Then following a sudden outburst of creativity, he opens the dialog again. At this point, you want the old invalid attempt to be gone, all errors cleared.</p>
<p>My solution was to clear the form values on hidden.bs.modal, reset isModified(false) and get rid of errors with clearErrors(). Well, it turned out that if the user submitted the form immediately, with an empty value, it passed as valid!</p>
<p>The culprit was clearErrors() &#8211; it not only removes the error message but also marks the model as valid! So the right procedure here is to use error(null) instead of clearErrors().</p>
]]></content:encoded>
					
					<wfw:commentRss>http://blog.pepa.info/php-html-css/knockout/clearerror-in-ko-validation-updates-validity-too/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Do you run PhpStorm in 64bit mode?</title>
		<link>http://blog.pepa.info/php-html-css/tools/phpstorm-in-64bit-mode/</link>
					<comments>http://blog.pepa.info/php-html-css/tools/phpstorm-in-64bit-mode/#respond</comments>
		
		<dc:creator><![CDATA[Petr 'PePa' Pavel]]></dc:creator>
		<pubDate>Sun, 21 Sep 2014 12:20:58 +0000</pubDate>
				<category><![CDATA[Tools]]></category>
		<category><![CDATA[PhpStorm 8.0.1]]></category>
		<guid isPermaLink="false">http://blog.pepa.info/?p=495</guid>

					<description><![CDATA[Maybe you only think you do. Check out the About menu item. You should see amd64 in the JRE area and 64-Bit in JVM. The thing is that PhpStorm comes with its own copy of JRE and it will use it unless your environment variables tell it that there&#8217;s Java already installed on your system. [&#8230;]]]></description>
										<content:encoded><![CDATA[<p><img decoding="async" class="alignleft wp-image-496 size-full" style="margin: 10px 10px 0 0;" src="http://blog.pepa.info/wp-content/PhpStormx64.png" alt="" width="301" height="32" srcset="http://blog.pepa.info/wp-content/PhpStormx64.png 301w, http://blog.pepa.info/wp-content/PhpStormx64-300x31.png 300w" sizes="(max-width: 301px) 100vw, 301px" />Maybe you only think you do. Check out the About menu item. You should see amd64 in the JRE area and 64-Bit in JVM.</p>
<p><span id="more-495"></span></p>
<p>The thing is that PhpStorm comes with its own copy of JRE and it will use it unless your environment variables tell it that there&#8217;s Java already installed on your system. For full details look into <code>C:\Program Files (x86)\JetBrains\PhpStorm 8.0.1\bin\PhpStorm.bat</code> but what worked for me was simply to set environment variable JAVA_HOME and run PhpStorm64.exe located in the same directory. In my particular case <code>JAVA_HOME=C:\Program Files\Java\jre1.8.0_20</code>.</p>
]]></content:encoded>
					
					<wfw:commentRss>http://blog.pepa.info/php-html-css/tools/phpstorm-in-64bit-mode/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>The secret of deleting contacts from Constant Contact</title>
		<link>http://blog.pepa.info/php-html-css/constant-contact/deleting-contacts/</link>
					<comments>http://blog.pepa.info/php-html-css/constant-contact/deleting-contacts/#respond</comments>
		
		<dc:creator><![CDATA[Petr 'PePa' Pavel]]></dc:creator>
		<pubDate>Wed, 10 Sep 2014 21:52:51 +0000</pubDate>
				<category><![CDATA[Constant Contact]]></category>
		<guid isPermaLink="false">http://blog.pepa.info/?p=476</guid>

					<description><![CDATA[You can&#8217;t really. An e-mail address in your Constant Contact account tells about your relationship with its owner, the contact. If a recipient becomes fed up with your newsletters and unsubscribes, this information must stick. You must not be allowed to simply delete the address and start over, pretending that nothing has happened. When you [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>You can&#8217;t really. An e-mail address in your Constant Contact account tells about your relationship with its owner, the contact. If a recipient becomes fed up with your newsletters and unsubscribes, this information must stick. You must not be allowed to simply delete the address and start over, pretending that nothing has happened.</p>
<p>When you &#8220;delete&#8221; an e-mail address or a contact using the <dfn title="Constant Contact">CtCt</dfn> website (called GUI) it&#8217;s actually only hidden, remaining in the database. It no longer counts towards your quota so for all practical purposes, we can call it deleted. Now, how do you do that with API?</p>
<p><span id="more-476"></span></p>
<p>First off, do NOT use what the documentation calls <a href="http://developer.constantcontact.com/docs/contacts-api/contacts-resource.html?method=DELETE" target="_blank">deleting an individual contact</a>. You would not hide the contact from GUI &#8211; you would unsubscribe it (and it would even remain visible). There&#8217;s a huge difference between deleting/hiding and unsubscribing. A hidden contact can be brought back to the land of living and sent e-mails to, while an unsubscribed contact cannot &#8211; not without some mouse clicking from the contact himself. Definitely not in an automated way via API.</p>
<p>So if your goal is to give your user an option to subscribe to your newsletter from within your website, then to change his mind and unsubscribe &#8211; and then to change his mind again and subscribe back &#8211; do not use the DELETE method for deleting his CtCt contact because you wouldn&#8217;t be able to subscribe it back.</p>
<p>What you want to do instead, is called <strong>remove from all lists</strong>. Doing it via API is not the same thing as with the website so please bear in mind that I&#8217;m only talking about API now. When you remove a contact from all lists, its status is magically changed to REMOVED &#8211; both the contact&#8217;s and its e-mail address&#8217; status will change. And guess what, it will actually disappear from the website, just as if you clicked More Actions / Delete on the CtCt website. Not very straight forward, is it.</p>
<h3>before</h3>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">{
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &quot;id&quot;: &quot;2009530238&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &quot;status&quot;: &quot;ACTIVE&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &#8230;
</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &quot;email_addresses&quot;: [{
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &quot;id&quot;: &quot;c099b9c0-38df-11e4-8148-d4ae5292c426&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &quot;status&quot;: &quot;ACTIVE&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &#8230;
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; }],
</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &#8230;
</div>
</li>
<li class="li1">
<div class="de1">}
</div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
</ol>
</div>
<h3>after</h3>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">{
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &quot;id&quot;: &quot;2009530238&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &quot;status&quot;: &quot;REMOVED&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &#8230;
</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &quot;email_addresses&quot;: [{
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &quot;id&quot;: &quot;c099b9c0-38df-11e4-8148-d4ae5292c426&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &quot;status&quot;: &quot;REMOVED&quot;,
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; &nbsp; &#8230;
</div>
</li>
<li class="li1">
<div class="de1">&nbsp; }],
</div>
</li>
<li class="li2">
<div class="de2">&nbsp; &#8230;
</div>
</li>
<li class="li1">
<div class="de1">}
</div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
</ol>
</div>
<p>To remove a contact from all lists, <a href="http://developer.constantcontact.com/docs/contacts-api/contacts-resource.html?method=PUT" target="_blank">update it</a> with an empty array for its lists property. The documentation is currently misleading when it says that lists require at least one list. Notice that it&#8217;s referring to method POST which is used for creating a new contact. Not for method PUT, used for updating.</p>
<p>You don&#8217;t have to worry about PUT/POST if you&#8217;re using the SDK. Simply call <a href="https://github.com/constantcontact/php-sdk/blob/development/src/Ctct/ConstantContact.php#L204" target="_blank">updateContact()</a>. Or use <a href="https://github.com/constantcontact/php-sdk/blob/development/src/Ctct/ConstantContact.php#L174" target="_blank">deleteContactFromLists()</a> which calls DELETE on an undocumented service <code>https://api.constantcontact.com/v2/contacts/{contactId}/lists</code>. These methods exist for both ConstantContact class and ContactService class.</p>
<p>Do you wonder what happens when you remove a contact from all lists using the website (GUI)? Nothing magical. Its status, and all its e-mail addresses&#8217; status will remain ACTIVE.</p>
]]></content:encoded>
					
					<wfw:commentRss>http://blog.pepa.info/php-html-css/constant-contact/deleting-contacts/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Paginating in Constant Contact API</title>
		<link>http://blog.pepa.info/php-html-css/constant-contact/paginating-in-constant-contact-api/</link>
					<comments>http://blog.pepa.info/php-html-css/constant-contact/paginating-in-constant-contact-api/#comments</comments>
		
		<dc:creator><![CDATA[Petr 'PePa' Pavel]]></dc:creator>
		<pubDate>Sat, 30 Aug 2014 13:16:39 +0000</pubDate>
				<category><![CDATA[Constant Contact]]></category>
		<guid isPermaLink="false">http://blog.pepa.info/?p=459</guid>

					<description><![CDATA[Some services of Constant Contact API return only a subset of results and you&#8217;re supposed to submit additional requests with a &#8220;next&#8221; parameter to fetch more. The implementation isn&#8217;t exactly straight forward though, and for some reason, CtCt doesn&#8217;t provide any pagination code sample. So here it is, for getContactsFromList(). You can either use ListService [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>Some services of Constant Contact API <a href="https://developer.constantcontact.com/docs/developer-guides/paginated-output.html" title="Developer Guide on paginated output" target="_blank">return only a subset of results</a> and you&#8217;re supposed to submit additional requests with a &#8220;next&#8221; parameter to fetch more. The implementation isn&#8217;t exactly straight forward though, and for some reason, CtCt doesn&#8217;t provide any pagination code sample. So here it is, for getContactsFromList().<br />
<span id="more-459"></span></p>
<p>You can either use ListService directly, or through an overarching ConstantContact object. Note that the <code>$limit</code> parameter will actually return <code>$limit + 1</code> contacts. The max value of 500 will yield 501 contacts.</p>
<h2 style="margin-bottom: 10px;">with ConstantContact object</h2>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1"><span class="coMULTI">/** @var Contact[] $contacts */</span</div>
</li>
</ol>
</div>
<h2 style="margin-bottom: 10px;">ListService directly</h2>
<div class="dean_ch" style="white-space: wrap;">
<ol>
<li class="li1">
<div class="de1">span class=&#8221;st0&#8243;>&#8217;limit&#8217;</span><span class="st0">&#8216;?&#8217;</span><span class="br0">&#41;</span>, <span class="re0">$params</span><span class="br0">&#41;</span>;</div>
</li>
<li class="li1">
<div class="de1"><span class="br0">&#125;</span></div>
</li>
<li class="li1">
<div class="de1">&nbsp;</div>
</li>
</ol>
</div>
]]></content:encoded>
					
					<wfw:commentRss>http://blog.pepa.info/php-html-css/constant-contact/paginating-in-constant-contact-api/feed/</wfw:commentRss>
			<slash:comments>3</slash:comments>
		
		
			</item>
		<item>
		<title>Access denied in mysqldump after ip address change</title>
		<link>http://blog.pepa.info/php-html-css/mysql/access-denied-mysqldump/</link>
					<comments>http://blog.pepa.info/php-html-css/mysql/access-denied-mysqldump/#comments</comments>
		
		<dc:creator><![CDATA[Petr 'PePa' Pavel]]></dc:creator>
		<pubDate>Thu, 17 Jul 2014 12:04:53 +0000</pubDate>
				<category><![CDATA[MySQL]]></category>
		<guid isPermaLink="false">http://blog.pepa.info/?p=450</guid>

					<description><![CDATA[This one was a real hard nut to crack. My workstation ip address has changed and I could no longer connect to my MySQL server remotely. So far nothing new or interesting. I went to cPanel and added my new ip address to &#8220;Remote MySQL&#8221; &#8211; a list of ip addresses that are allowed to [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>This one was a real hard nut to crack. My workstation ip address has changed and I could no longer connect to my MySQL server remotely. So far nothing new or interesting. I went to cPanel and added my new ip address to &#8220;Remote MySQL&#8221; &#8211; a list of ip addresses that are allowed to access the database server remotely. Being a cautious person, I also removed my old ip address while I was there.</p>
<p>So now I could connect remotely both from my IDE (via JDBC) and from my local mysql client but to my surprise, I was still getting access denied from mysqldump. Mhm&#8230;<br />
<span id="more-450"></span></p>
<p><code>mysqldump: Got error: 1045: Access denied for user 'myusername'@'my.new.ip.address' (using password: YES) when using LOCK TABLES</code></p>
<p>I verified that myusername indeed had permissions for locking tables. And I was able to make an alternate dump with <a href="http://www.adminer.org/" target="_blank">Adminer</a> and load the dump into my local database. (There was just one unrelated error with an empty view definition.)</p>
<p>To cut the story short, the problem was in the view. It was defined remotely from my old ip address and it stuck with the view in DEFINER. For the view to work, its definer must have access to the database &#8211; which in my case it didn&#8217;t because I had already revoked access to my old ip address. So now I couldn&#8217;t see the view definition, or use it, getting access denied for the <i>old ip address</i>.</p>
<p>It dawned on me that the &#8220;unrelated error&#8221; in my Adminer dump probably wasn&#8217;t that unrelated. Adminer defines dummy tables for views before dropping them and replacing them with a real view. And the error was triggered when it attempted to create a table with no attributes.</p>
<p>Obviously, it failed to get a definition of the view defined from the old address and thus it couldn&#8217;t get its attributes either.</p>
<p>It&#8217;s really unfortunate that I was getting access denied for my new ip address when dumping with mysqldump while in fact, access was being denied to the old ip address. The whole thing with DEFINER and its ip address seems rather silly, if you ask me.</p>
<p>Anyway, the solution was to recreate the faulty view from my new ip address (I actually used Adminer to create it from localhost) and all was good then.</p>
]]></content:encoded>
					
					<wfw:commentRss>http://blog.pepa.info/php-html-css/mysql/access-denied-mysqldump/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
			</item>
	</channel>
</rss>
