<?xml version="1.0" encoding="UTF-8" standalone="no"?><rss xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" version="2.0">

<channel>
	<title>Ashfame | Blog</title>
	<atom:link href="https://blog.ashfame.com/feed/" rel="self" type="application/rss+xml"/>
	<link>https://blog.ashfame.com/</link>
	<description>Putting WordPress to use</description>
	<lastBuildDate>Sat, 21 Feb 2026 17:26:43 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>
<atom:link href="https://pubsubhubbub.appspot.com" rel="hub"/>
<atom:link href="https://pubsubhubbub.superfeedr.com" rel="hub"/>
<atom:link href="https://websubhub.com/hub" rel="hub"/>
<atom:link href="https://blog.ashfame.com/feed/" rel="self"/>
	<atom:link href="https://blog.ashfame.com/?pushpress=hub" rel="hub"/>
<cloud domain="blog.ashfame.com" path="/?rsscloud=notify" port="80" protocol="http-post" registerProcedure=""/>
<site xmlns="com-wordpress:feed-additions:1">2449132</site>	<itunes:explicit>no</itunes:explicit><itunes:subtitle>Putting WordPress to use</itunes:subtitle><itunes:category text="Technology"/><item>
		<title>UAE / Dubai – Remote Work Visa Renewal in 2026</title>
		<link>https://blog.ashfame.com/2026/01/uae-dubai-remote-work-visa-renewal-in-2026/</link>
					<comments>https://blog.ashfame.com/2026/01/uae-dubai-remote-work-visa-renewal-in-2026/#respond</comments>
		
		<dc:creator><![CDATA[Ashfame]]></dc:creator>
		<pubDate>Wed, 14 Jan 2026 13:58:02 +0000</pubDate>
				<category><![CDATA[Uncategorized]]></category>
		<guid isPermaLink="false">https://blog.ashfame.com/?p=1512</guid>

					<description><![CDATA[<p>Sudden worry installed by some rumors around “Remote work visa”, often referred to as “Virtual work visa” not being granted nowadays, I decided to tackle it early on. And when I say early on, I meant right after expiration and within 30 days grace period. To get a general understanding of things, please refer to [&#8230;]</p>
<p>The post <a href="https://blog.ashfame.com/2026/01/uae-dubai-remote-work-visa-renewal-in-2026/">UAE / Dubai – Remote Work Visa Renewal in 2026</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p>Sudden worry installed by some rumors around “Remote work visa”, often referred to as “Virtual work visa” not being granted nowadays, I decided to tackle it early on. And when I say early on, I meant right after expiration and within 30 days grace period.</p>



<p>To get a general understanding of things, please refer to last year&#8217;s post where I explain it in detail &#8211; <a href="https://blog.ashfame.com/2025/02/uae-dubai-remote-work-visa-renewal-in-2025/">UAE / Dubai – Remote Work Visa Renewal in 2025</a></p>



<p>Some research led me to learning about Salama AI platform for quick visa renewals (launched in Feb 2025) but unfortunately it&#8217;s not LIVE anywhere. Maybe it&#8217;s just integrated deeply into the system now (smart.gdrfad.gov.ae + ai.gdrfad.gov.ae). The AI chat was helpful to jog my memory of document requirements, so worth a try.</p>



<p>This year, I first did the medical test (Costs 322.5 AED for 24hrs option). I was being tricked into an unnecessary upsell of getting my recent picture clicked to which I politely but firmly declined. I went to near closing time and found the center pretty empty, which was quite welcoming for a change. Next day, I did the Emirates ID renewal application online (icp.gov.ae) which costs 253.2 AED (34.65 AED cheaper than last year). And next day, headed to my favorite <a href="https://maps.app.goo.gl/Z6PoYA6YzSfBePwA6">Amer Center Al Kifaf</a>, after having a brief chat with the same lady who handled my renewal last time.</p>



<p>She confirmed she had no such news and as long as documents are good, should be all good. I love how this Amer center is not that crowded, people actually attend to you properly. Every counter has a mirrored screen so you can see what&#8217;s actually being done. Sure it&#8217;s pricey, but combined with less crowd and actually comfortable seating/waiting area, I ended up using that area as a co-working space for the next 3 hours. I wanted to hang around in case there was a response on the application so I could easily get that to their attention.</p>



<p>The residency renewal application (which is why I went to Amer) costs 450.91 AED (the same as last year), but I understood the breakdown a bit better or maybe I cared to look. The application itself was 370 AED and the rest (80.91 AED) was their fees on top of it. Usually, Amer centers charge typing fees, which were also there (100 AED within the 370 AED amount), but honestly, it was worth the experience, so I am happy.</p>



<p>Last year, the approval came as soon as I was walking away from the building. But this year, it came during early morning hours, like 4AM. Not sure what&#8217;s up with that, but I will happily take it. The renewal cost this time around was 1026.61 AED.</p>



<p>Also been hearing that now family members you sponsor, their visa can&#8217;t extend yours, which it what I thought would be the case when I came here 4+ yrs ago, but oh well, makes sense. I will know for sure in a month&#8217;s time, at which point I will come and update this post.</p>



<p><em>Update: Family members&#8217; visa still works independently of your own visa, and the duration is a full year from the date your residency is approved. Another tip/hack I discovered is that emirates ID application can advance as soon as medical certificate is updated into the system, which happens as soon as its processed, so no need to wait for full 24hrs. They just delay sending you the PDF for 24hrs.</em></p>



<p>Maybe fresh applications from outside the country are being scrutinized more now. Or maybe their documentation is not convincing enough. I have had my share of bizarre document requests, which also included handling bugs in the forms on the website, but it&#8217;s much easier to apply from within the country. You would pay 650 AED, twice on top of what I mentioned above, but at least you would have the recourse of getting in touch with people if something were to go sideways. Outside of UAE, calls don&#8217;t get picked up and emails goes unanswered.</p>



<p><em>And if you are curious about the 650 AED X 2, once it&#8217;s for applying from within the country because how dare you? ? and another for visa status change &#8211; switching from tourist visa to remote work visa. Being granted a visa doesn&#8217;t mean that you are actually on it, so requires a database row update, which is going to cost you, as many things here.</em></p>



<p>Good luck!</p>
<p>The post <a href="https://blog.ashfame.com/2026/01/uae-dubai-remote-work-visa-renewal-in-2026/">UAE / Dubai – Remote Work Visa Renewal in 2026</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.ashfame.com/2026/01/uae-dubai-remote-work-visa-renewal-in-2026/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">1512</post-id>	</item>
		<item>
		<title>UAE / Dubai – Remote Work Visa Renewal in 2025</title>
		<link>https://blog.ashfame.com/2025/02/uae-dubai-remote-work-visa-renewal-in-2025/</link>
					<comments>https://blog.ashfame.com/2025/02/uae-dubai-remote-work-visa-renewal-in-2025/#respond</comments>
		
		<dc:creator><![CDATA[Ashfame]]></dc:creator>
		<pubDate>Mon, 17 Feb 2025 16:22:52 +0000</pubDate>
				<category><![CDATA[Uncategorized]]></category>
		<guid isPermaLink="false">https://blog.ashfame.com/?p=1482</guid>

					<description><![CDATA[<p>With this post, I hope to document the process and my understanding of the visa process here in UAE. &#8220;Remote work visa&#8221;, is often referred to as &#8220;Virtual work visa&#8221; in different online portals. If your visa sponsor is already &#8220;Dummy sponsor for virtual work&#8221;, you can proceed with renewing it. If not, then you [&#8230;]</p>
<p>The post <a href="https://blog.ashfame.com/2025/02/uae-dubai-remote-work-visa-renewal-in-2025/">UAE / Dubai &#8211; Remote Work Visa Renewal in 2025</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p>With this post, I hope to document the process and my understanding of the visa process here in UAE. &#8220;Remote work visa&#8221;, is often referred to as &#8220;Virtual work visa&#8221; in different online portals.</p>



<p>If your visa sponsor is already &#8220;Dummy sponsor for virtual work&#8221;, you can proceed with renewing it. If not, then you would be forced to cancel first and do a fresh application, since you must switch to this new sponsor label. I had to do this last year.</p>



<p>As of January 2025, it&#8217;s not entirely possible to finish the renewal online. Moreover, I have had quite the luck in running into edge cases with my applications done online, that I prefer to not even bother doing them online as I always end up wasting more time &amp; money.</p>



<p>Essentially, there are three steps involved in obtaining a visa in UAE:</p>



<p>First, you need a medical fitness certificate. This can be done independently of any other application &amp; is valid for 3 months. For visa renewals, X-ray requirement is waived off and its just the blood test.</p>



<p>Second, get your Emirates ID application done. It&#8217;s unintuitive to do the ID application before the visa, but the way this works is, once applied, it waits for the issuance of residency and would move past that step on its own. The delivery address is often wrongly printed on the application, so don&#8217;t worry.</p>



<p>Lastly, get your residency application done, which is called &#8220;Visa stamping&#8221; though there is no actual physical visa that&#8217;s stamped anymore. This is what requires the documents as it&#8217;s the main application for &#8220;visa&#8221; itself.</p>



<p>Documents required list varies from center to center, but generally it&#8217;s your passport, work contract, bank statements showing the credits in the past 3 months &amp; health insurance valid for about a year. Two Amer centers that I recommend going are:</p>



<ul class="wp-block-list">
<li><a href="https://maps.app.goo.gl/Z6PoYA6YzSfBePwA6">Amer Center &#8211; Al Kifaf</a></li>



<li><a href="https://maps.app.goo.gl/cTmLmKpVcVXGyqD67">Amer Center &#8211; DAFZA &#8211; Al Tawar</a></li>
</ul>



<p>I have been treated courteously at both the centers, unlike the one that&#8217;s always downright confusing &amp; humiliating (we all know which one this is).</p>



<p>If you were to optimize the process for time/money, get medical fitness certificate weeks prior to the actual day you wish to renew, whenever you happened to be out of the house. Then, close to the expiry (or expiry of grace period), you can get both EID application and visa stamping application done, in a single visit. If you are able to do applications yourself online, you will save some typing fees (~50-100 AED / application) but only if you are feeling lucky.</p>



<p>I paid 322.5 AED for my medical fitness certificate (24hrs regular option). 287.85 AED for EID application and 450.91 AED for residency application. So, a total of 1061.26 AED. You often pay 1% extra when paying with a domestic card &amp; possibly more if it&#8217;s an international card.</p>



<p>My residency application (visa stamping &#8211; really hoping to drill this in your brain at this point) was approved few minutes of applying.</p>



<p>Grace period after expiry of remote work visa is just 30 days, not 60 days. You can <a href="https://smartservices.icp.gov.ae/echannels/web/client/default.html#/fileValidity">check your file status</a> for this information. It might say, for example, valid until 7th Feb 2025 but read it as last day to leave the country is 6th Feb 2025. As soon as the clock strikes 00:00, welcome to your first day of fine. You are fined for both not having a residency beyond your grace period and not having Emirates ID, which is ~ 75-100 AED / day. 50 AED for residency and 25 AED for EID per day, but I have paid fines as per 100 AED / day, so ¯\_(?)_/¯.</p>



<p>This year, I literally did the renewal on last day of my 30 day grace period, hoping to move the visa expiration date a bit forward, but turns out the visa is renewed as per previous visa&#8217;s expiry and not the actual date its done on, unless you are renewing your visa early, then you get an early date. Nowadays, it can be renewed 90 days early as opposed to only letting you do it in the last 30 days.</p>
<p>The post <a href="https://blog.ashfame.com/2025/02/uae-dubai-remote-work-visa-renewal-in-2025/">UAE / Dubai &#8211; Remote Work Visa Renewal in 2025</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.ashfame.com/2025/02/uae-dubai-remote-work-visa-renewal-in-2025/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">1482</post-id>	</item>
		<item>
		<title>Setting up Caddy PHP MySQL stack for a web server</title>
		<link>https://blog.ashfame.com/2023/02/setting-up-caddy-php-mysql-stack-for-a-web-server/</link>
					<comments>https://blog.ashfame.com/2023/02/setting-up-caddy-php-mysql-stack-for-a-web-server/#respond</comments>
		
		<dc:creator><![CDATA[Ashfame]]></dc:creator>
		<pubDate>Sun, 26 Feb 2023 12:48:24 +0000</pubDate>
				<category><![CDATA[Uncategorized]]></category>
		<guid isPermaLink="false">https://blog.ashfame.com/?p=1373</guid>

					<description><![CDATA[<p>Login into your server as the root user ssh root@xx.xx.xxx.xx Update everything first Set timezone to UTC Set hostname Setup user Add a new user for ourselves, we won&#8217;t be using root user after this initial setup for security purposes. Setup SSH key based login for ourselves Paste your public key and save the file. [&#8230;]</p>
<p>The post <a href="https://blog.ashfame.com/2023/02/setting-up-caddy-php-mysql-stack-for-a-web-server/">Setting up Caddy PHP MySQL stack for a web server</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p>Login into your server as the root user <code>ssh root@xx.xx.xxx.xx</code></p>



<p>Update everything first</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
apt update && apt upgrade
</pre></div>


<p>Set timezone to UTC</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
dpkg-reconfigure tzdata and select UTC
</pre></div>


<p>Set hostname</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
hostnamectl set-hostname caddy-prod
</pre></div>


<h2 class="wp-block-heading">Setup user</h2>



<p>Add a new user for ourselves, we won&#8217;t be using root user after this initial setup for security purposes.</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
adduser ashfame
usermod -aG sudo ashfame
</pre></div>


<p>Setup SSH key based login for ourselves</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
mkdir ~/.ssh; nano ~/.ssh/authorized_keys
</pre></div>


<p>Paste your public key and save the file. Set permissions.</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: plain; title: ; notranslate">
sudo chmod -R 700 ~/.ssh &amp;&amp; chmod 600 ~/.ssh/authorized_keys
</pre></div>


<p>Now update SSH config</p>



<p>In <code>/etc/ssh/sshd_config</code></p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
PermitRootLogin no
PasswordAuthentication no
AddressFamily inet #to allow ipv4 only for ssh connection
</pre></div>


<p>Restart SSH service to bring the changs into effect</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
sudo systemctl restart sshd
</pre></div>


<p>Ensure you can login with your new user without a password and just by your key before killing your root user session.</p>



<h2 class="wp-block-heading">Setup Firewall</h2>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
ufw app list
ufw allow OpenSSH
ufw allow http
ufw allow https
ufw enable
ufw status
</pre></div>


<h2 class="wp-block-heading">Install packages</h2>



<h3 class="wp-block-heading">Install Caddy</h3>



<p>For installing Caddy, lets first install go lang so that we can compile from source, right here on the server (if needed)</p>



<h4 class="wp-block-heading">Install Go lang</h4>



<p>Download the latest archive file</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: plain; title: ; notranslate">
rm -rf /usr/local/go &amp;&amp; tar -C /usr/local -xzf go1.20.linux-amd64.tar.gz
</pre></div>


<p>Add <code>PATH=$PATH:/usr/local/go/bin</code> in <code>$HOME/.profile</code></p>



<h4 class="wp-block-heading">Clone Caddy from Github for compilation and installation</h4>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
git clone https://github.com/caddyserver/caddy.git
cd caddy/cmd/caddy/
go build
sudo mv caddy /usr/bin/
caddy version
sudo chown root:root /usr/bin/caddy
sudo chmod 755 /usr/bin/caddy
</pre></div>


<h3 class="wp-block-heading">Create Caddy user and group</h3>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: plain; title: ; notranslate">
sudo groupadd --system caddy

sudo useradd --system \
--gid caddy \
--create-home \
--home-dir /var/lib/caddy \
--shell /usr/sbin/nologin \
--comment 'Caddy web server' \
caddy
</pre></div>


<h3 class="wp-block-heading">Set Caddy to run via systemd</h3>



<p>Take systemd service file &#8211; https://github.com/caddyserver/dist/blob/master/init/caddy.service<br />and put that at <code>/etc/systemd/system/caddy.service</code></p>



<p>Define Caddyfile at <code>/etc/caddy/Caddyfile</code></p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: plain; title: ; notranslate">
:80

response "Hello world"
</pre></div>


<p>Now, test by loading your IP address of your server and you should see some &#8220;hello world&#8221; output defined in your Caddyfile</p>



<h3 class="wp-block-heading">Install PHP8</h3>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
sudo apt install php8.1-fpm php8.1-cli php8.1-common php8.1-mysql php8.1-zip php8.1-gd php8.1-mbstring php8.1-curl php8.1-xml php8.1-bcmath php8.1-opcache php8.1-readline
</pre></div>


<div class="wp-block-group has-global-padding is-layout-constrained wp-block-group-is-layout-constrained">
<h3 class="wp-block-heading">Install MariaDB for database in place of MySQL</h3>
</div>



<div class="wp-block-group has-global-padding is-layout-constrained wp-block-group-is-layout-constrained"><div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
sudo apt install mariadb-server
sudo mysql_secure_installation
sudo mariadb
</pre></div></div>



<p>Run the following SQL commands:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: sql; title: ; notranslate">
GRANT ALL ON *.* TO 'admin'@'localhost' IDENTIFIED BY 'password' WITH GRANT OPTION;
FLUSH PRIVILEGES;
exit
</pre></div>

<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
sudo systemctl status mariadb
sudo mysqladmin version
</pre></div>


<p>Create more databases and a user for each of them (`sudo mariadb`):</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: sql; title: ; notranslate">
create database food_ashfame_com
CREATE USER 'food_ashfame_com'@'localhost' IDENTIFIED BY 'password';
GRANT ALL ON food_ashfame_com.* TO 'food_ashfame_com'@'localhost' WITH GRANT OPTION;
</pre></div>


<h2 class="wp-block-heading">Create php-fpm user</h2>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
sudo useradd --system \
--gid caddy \
--shell /usr/sbin/nologin \
--comment 'PHP-FPM user' \
php-fpm
</pre></div>


<p>In <code>/etc/php/8.1/fpm/pool.d/www.conf</code>, change:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: plain; title: ; notranslate">
user = php-fpm
group = caddy

# For socket
listen.owner = caddy
listen.group = caddy
listen.mode = 0660
</pre></div>


<p>Configure log file in <code>/etc/php/8.1/fpm/php.ini</code> using <code>error_log</code><br /><code>error_log = /var/log/php_errors.log</code></p>



<p>All configured/resultant config can be viewed in <code>phpinfo()</code>&#8216;s output</p>



<h2 class="wp-block-heading">File permissions</h2>



<p>Since we have configured php to run as <code>php-fpm</code> user and its in <code>caddy</code> group,<br />owners of all our files could be <code>ashfame</code> and group as <code>caddy</code><br />Permission as follows:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: bash; title: ; notranslate">
sudo find . -type f -exec chmod 640 {} +
sudo find . -type d -exec chmod 751 {} +
sudo chmod 640 wp-config.php
sudo chmod 660 wp-content/debug.log
</pre></div>


<p>This is tight enough to not allow WP upgrades, plugin installs etc to not work. Media uploads can be made to work with the following permission:</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: plain; title: ; notranslate">

</pre></div>


<p>There are more things to do, like configure Caddyfile to run your WordPress sites and other services, which I might follow up on later in separate posts.</p>
<p>The post <a href="https://blog.ashfame.com/2023/02/setting-up-caddy-php-mysql-stack-for-a-web-server/">Setting up Caddy PHP MySQL stack for a web server</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.ashfame.com/2023/02/setting-up-caddy-php-mysql-stack-for-a-web-server/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">1373</post-id>	</item>
		<item>
		<title>2020-in-Review: Accidental Gap Year</title>
		<link>https://blog.ashfame.com/2021/01/2020-in-review-accidental-gap-year/</link>
					<comments>https://blog.ashfame.com/2021/01/2020-in-review-accidental-gap-year/#respond</comments>
		
		<dc:creator><![CDATA[Ashfame]]></dc:creator>
		<pubDate>Sat, 02 Jan 2021 22:03:21 +0000</pubDate>
				<category><![CDATA[Blogging]]></category>
		<guid isPermaLink="false">https://blog.ashfame.com/?p=1334</guid>

					<description><![CDATA[<p>Who takes a gap year and not travel? Apparently this crazy guy ?</p>
<p>The post <a href="https://blog.ashfame.com/2021/01/2020-in-review-accidental-gap-year/">2020-in-Review: Accidental Gap Year</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>I remember wrapping up my last consultancy project in October&#8217;19, thinking I will take some time off, play games and chill out for a while before getting back into the game. I have taken such breaks (few weeks to few months at times) a few times in my career where I get to slow down, learn new things and re-assess my direction. Little did I know, what lies ahead of me.</p>
<p><img data-recalc-dims="1" height="405" width="768" decoding="async" src="https://i0.wp.com/blog.ashfame.com/wp-content/uploads/2021/01/After-Earth-Jaden-Smith-volcano.jpg?resize=768%2C405&#038;ssl=1" alt="take a knee" /></p>
<h2>Pre-2020 Context</h2>
<p>I took an entire month to play PUBG PC in November&#8217;19, being competitive and earning a rep in the Indian community, something that I have been doing for the entire year of 2019. Really, I was playing FPS games as a full-time PRO gamer except I wasn&#8217;t streaming or trying to make it as a professional gamer. I was just being me, even in downtime, I am always competitive. It&#8217;s just first nature to me. Who else commits a year or so to things to get really good at it? I have always been fortunate enough to do that.</p>
<p>Journey started in December&#8217;19 when I started to read about how money, stock market &amp; economy works. Even though we all use money everyday, we understand it very little. And why does some people get to move Billions or Trillions of dollars, what&#8217;s going on there? That was my primed entry to the rabbit hole. Luckily, I was well-equipped for the journey that was about to begin. I, unknowingly, started as a full-time researcher, just to learn. Without any worries of keeping food on the table, tapping into the savings reserves, I was more than ready.</p>
<h2>January</h2>
<p>I realised literally everything is approachable, when you start with fundamentals, asking the right questions. There is nothing more to it. Nothing is complicated or impossible, its just a journey that you must go through, figure things out, verify what&#8217;s needed and keep on building your understanding block by block.</p>
<p>I came to know how Stock market is just a legalised version of gambling, wrapped in fancy paper to look as &#8220;investment&#8221; to the masses, where their wealth is stolen by people who understand the game better than everyone else. Gambling otherwise is illegal (speaking for India here), otherwise how would you maintain the monopoly? Banning doesn&#8217;t work, not really. Be it drugs or gambling. As long as there is demand for anything, it will continue to exist. Someone will always be willing to serve that demand &amp; make money.</p>
<p>This was a huge eye-opener for me, as we all are invested into some investment scheme or the other. And as it turns out, it&#8217;s a rigged financial system. How was this allowed? Only, if they wanted it to exist. Who doesn&#8217;t like making money? It&#8217;s a vehicle for freedom. Those who understand this, are better off joining them and making money, instead of blowing the whistle on it. Why? Because people don&#8217;t listen.</p>
<blockquote><p>
  It&#8217;s easier to fool people than to convince them that they have been fooled &#8211; Mark Twain
</p></blockquote>
<h2>February</h2>
<p>We all keep our money in banks, but how do the banks work? Isn&#8217;t that the single most important thing we should know because we trust them to hold our money. Turns out, when you deposit money into a bank, its not your money anymore. You have loaned it out to them. They just have an obligation to pay you back with interest, which is what you earn in your savings account. Ever thought why would a custodian pay you money for security, a service that they provide to you to do your job. Shouldn&#8217;t they be charging you for the services they render?</p>
<p>Internally, it&#8217;s a lot worse. They loan out money they don&#8217;t even have, effectively creating money. Because money is nothing but a giant ledger of who owes how much to whom. And when they fail as a business because of a bad loan, which is a risk they took, the cost of failure is passed on to customers again, by creating more money which leads to reduced purchasing power of the money you possess. How is this anything but criminal? How did we let it get this bad? Some history lessons were next.</p>
<p>Barter -&gt; Commodity money -&gt; Precious metal money -&gt; Paper money (redeemable) -&gt; Fiat money (shit)</p>
<p>Honestly, I can&#8217;t summarise all that learning in a small post, but the essence is that with time, advancement happens and those who understand these shifts can create systems that favour them &amp; bring in huge returns. Sometimes the balance is titled so much in somebody&#8217;s control that they get the power of governing people despite our constitutional / human rights.</p>
<h2>March</h2>
<p>C0VlD news was spreading and I knew it to be the reason to bring in changes that people will accept out of fear. Why has no nation considered it as a possible biological attack and investigated it publicly? Why does a certain organisation dictate the policies that need to be followed everywhere without any internal audit of any kind? Truth has been hijacked.</p>
<p>Another event that locally developed was Yes Bank got into trouble and RBI (central bank of India) had to issue a moratorium to stop withdrawals from the bank. And essentially, all my funds &amp; my parents&#8217; funds were locked. Just like that. Recent learnings became too real, too fast. But I knew, a nation can&#8217;t afford to let their 4th biggest bank go bust without risking a bank run on all banks. And really what&#8217;s the risk with bank runs if their operations are legit? After all, everyone is just trying to withdraw the money they have deposited. What&#8217;s wrong in that? <em>Food for Thought</em></p>
<p>I predicted lockdowns were incoming and positioned myself for a smooth ride out. I got all family members to stock supplies for the next month or so. And when lockdown was announced, the first prediction based on my learnings came to be true &amp; my belief system only grew stronger, like the resonant sound of a tuning fork.</p>
<h2>April</h2>
<p>Why do people in power (legally) get to do so much? Because they control the money supply and they can simply print more when needed, indirectly taxing everyone&#8217;s purchasing power. The real solution can only be hard money, which can&#8217;t be created or produced out of thin air, like Gold. Our money, that used to be linked with equivalent Gold reserves, is a thing of past. So essentially savings require an instrument which is capable of being a good candidate of saving one&#8217;s purchasing power. And Bitcoin stands out solid in being that candidate. So, I started to finally look into what makes Bitcoin a serious candidate. Reading everything that I could find and building my understanding from fundamentals.</p>
<h2>May</h2>
<p>Being a programmer, I was in a unique position to really understand Bitcoin and be sure its not just another scam designed to take people&#8217;s money. Architecture isn&#8217;t that difficult either, it just combines a few technological concepts we already knew together. It was the first truly decentralised monetary system, that nobody could control to do whatever. How it manages to do that, is really remarkable.</p>
<p>Bitcoin stands to prove to be the greatest equalizer and brings back the power back to the people. So many problems of our world, and many of the &#8220;advertised&#8221; world problems are just designed to exist but when controlling elites lose that power, the world will head towards equilibrium, like anything else in this world. You have to keep deploying the force to keep something tilted. Leaving it, brings it back to its stable position eventually. I dived deep into the mechanics of how it functions and can stand to be a solid candidate, even transcending gold, the hardest money we had known until Bitcoin came around. And writing this today, in January 2021, only shows how much it has grown and I am currently writing a book on Bitcoin, among others to come in 2021.</p>
<h2>June</h2>
<p>Being digital money, it&#8217;s easy to steal &amp; hard to protect. So in order to safeguard it, we need to know when the computing devices we have can&#8217;t be trusted. Its so easy to get your computer infected with malware, if you don&#8217;t know what you are doing. Not even experts can protect their systems with full certainty. We can only strive for better and better security. 99.99% is better than 99.9% and so on. During the swing of lockdowns, it&#8217;s not easy to just order a hardware wallet and even if you could, those devices simply can&#8217;t be trusted completely, without verifying it. Some can&#8217;t even be verified to be what they claim to be. So, are you really ready to bet on your life savings with anything but the highest grade of security that you can afford? Also, it should be possible to just put together a simple wallet using hardware parts as the main security offered by Bitcoin comes from the power of mathematics and not computer security alone.</p>
<p><img data-recalc-dims="1" height="576" width="768" decoding="async" src="https://i0.wp.com/blog.ashfame.com/wp-content/uploads/2021/01/EeUTpbEU0AEXL6p.jpeg?resize=768%2C576&#038;ssl=1" alt="Raspberry Pi Hardware Wallet" /></p>
<p>So, I started out to build an open source hardware wallet out of Raspberry Pi, that offers greatest security with highest convenience possible &amp; see how far I could stretch it to be a trustless system. I started doing this entirely on <a href="https://www.youtube.com/channel/UChFuTA2sq4yhXjet1JT3vcw">live streams</a>. First stream was on <a href="https://www.youtube.com/watch?v=HFWwcGc-u2Q&amp;t=243s">June 14, 2020</a>.</p>
<h2>July</h2>
<p>Kept at it, learning more about the Bitcoin internals &amp; cryptography in general. Rabbit holes kept on inviting me and I kept on diving into them to seek answers of the questions that would come to my mind. I had found my <strong>ikigai</strong>, something that I love to do, I am good at, pays me well &amp; does good in the world.</p>
<p><img data-recalc-dims="1" height="770" width="768" decoding="async" src="https://i0.wp.com/blog.ashfame.com/wp-content/uploads/2021/01/Finding-Your-Ikigai-Figure-1.png?resize=768%2C770&#038;ssl=1" alt="Ikigai venn diagram" /></p>
<p>I literally had to study about making my own custom OS that would run in an immutable fashion. Boots up and then disconnects from storage, just processing what its asked for before forgetting everything when switched off. Completely disconnected from any other device on a hardware that doesn&#8217;t even have the hardware for wireless communication (wifi, bluetooth). Studying against different types of Proof Of Concept (POC) Air gap attacks, I was creating something that could change the level of security any common man could afford for their life savings. It was hard, but very fulfilling at the same time.</p>
<h2>August</h2>
<p>80% of the work being done, I was looking towards mid month to finish the first release of the project to the community &amp; looking at, I felt great to progress insanely in just 2 months. I felt ready to change the world and challenge Elon Musk on innovating and building solutions to real problems in the world. Came to the trickiest portion of the project &#8211; signing an actual transaction and I wasn&#8217;t able to wrap my head around it at all. Things started to delay bit by bit, extending the timeline week by week, so I allowed myself more time, and set the mid of next month as the date for the finish line, while I kept on learning it and figure out how transaction signing works. Enough persistence moves mountains, and I knew this from my experience of conscious growth in the past 13 yrs ago.</p>
<h2>September</h2>
<p>Came next month, with some progress but meanwhile I discovered another project, which has done the same thing but miles ahead of me in terms of feature set ready to be used today. Was a little disappointed to begin with, but after talking with them, I realised I can still do it. After all, this is what I will use for myself anyway, and not another system that I haven&#8217;t personally verified. All seem to be right &amp; on track in life.</p>
<p>What I didn&#8217;t realize was how hard I was working non-stop on this quest of figuring this world out, its issues and to build one of the solutions needed in the world to put up a fight against the true evils of the world. I forgot to slow down &amp; like any engine that has been kept on full steam for months, there came the momentum crash. I got burnt out. Burnt out so bad, that I didn&#8217;t even know burning out this bad was even possible. Polarity of the confidence that went a steep climb came crashing down and took me on an emotional rollercoaster. Not to mention the reality of the world, how evil corporations and certain elites are, has snatched away the concept of happy life as we know it. Anxiety took over. I struggled bad, but I knew I would bounce back. I have been derailed but not for forever. But a crash has its recovery cost in terms of time anyway.</p>
<h2>October</h2>
<p>Feeling better, onto the path of recovery and finally figuring out the transaction signing bit, after even producing the sample code to correctly sign a transaction, I never put that piece back into the project and the project is still unfinished. I felt like this to be a pattern in me, where I build cool things but either never advertise them or never come close to finishing it &amp; launching it when I have finally figured out all the challenging bits involved. Almost like a demon inside me that feeds on challenges but as soon as its done feeding, it doesn&#8217;t care to let me finish the project. Looking back at side projects, I realised this is the demon that I am supposed to fight if I am to grow past it.</p>
<p>Combined with a bad attempt of trading in the markets, my productivity took another dive as I was stuck watching charts all day long. Even at night, I would wake up to check the price before going back to sleep. The worst was a period of 3 days, when I felt so exhausted that I just thought I would never do this again. The cost of mental peace is too much for any monetary gains you can possibly hope for.</p>
<p>Often you have to walk the path to realize why wiser people advice you to avoid it. I thought I knew better and could manage, but all markets are always designed to take your money by playing you on a psychological level. Unless you care to understand trading on a professional level, don&#8217;t bother. I made the mistake of diving into something I don&#8217;t fully understand, hoping to ride the wave but ended up derailing myself from the tracks of productivity.</p>
<h2>November</h2>
<p>By now, I have recovered completely more or less, but being able to see the world on such a macro-scale that I can see how the world changes and how big businesses are built as per the future, was magical. A magic that I was hoping to find for a very long time. The initial spark of which was ignited by Vice&#8217;s video <a href="https://www.youtube.com/watch?v=QX3M8Ka9vUA&amp;ab_channel=VICE">The Third Industrial Revolution</a>&#8220;. I know enough now, calling current times as &#8220;Informational Age&#8221; is more accurate.</p>
<p>The next immediate challenge was to pick a fight, as in pick a business to build right now, like today. Even though fortunate enough to find my <em>ikigai</em>, I had tens of ideas that I could work towards, start generating some cash flow which would in turn sustain while I build the big business for future.</p>
<p>Paralysed by choices, starting one thing today and then starting another thing tomorrow before finishing the first theme turned out to be a recurring theme in me again. In my pursuit of being effective with my time, I was caught up in a whirlpool where I would change my mind constantly, forgetting the mind castle I would build one day, only to build another one tomorrow.</p>
<p>Completing one full year of not doing any consultancy work at all and just researching &amp; learning was worth it, but the pressure of drawing from savings reserves felt wrong by now. I needed to start bringing in some money, so that the short term isn&#8217;t compromised for the long term.</p>
<h2>December</h2>
<p>Discussing plans with a friend, he suggested to just take the least frictional path of <em>money</em> instead of the most effective path optimised for long term to get out of this rut. And it made sense. Sometimes building something for the short term, even though seems to be ineffective at first, but can help you stay focussed on your long term goal, is a clear win.</p>
<p>We are humans, our minds is like a citadel &amp; depending on what scenario of life is playing out, you may not be at the best position to make use of whatever you have at your disposal. I realised this, and picked up one of my currently running side project to transform it into a paying tool &amp; be done with that experiment, before figuring out the next least frictional path.</p>
<p>Losing battles against this demon, only made me understand him better. I let it ate many days of December as well, but I have learnt to not over-stress anything &amp; be more with friends &amp; family as I get a chance because I must find my harmony to be everywhere at the same time, by getting really good at serialising tasks for completion. Multi-tasking is a fool&#8217;s tool.</p>
<p>Realising your demons that you have to fight or leave with in harmony can be a super freeing thing. And now I have set out my working schedule as a weekly bar that I got to hit.</p>
<p>40 hrs of focus work in a week. Any overhead or errands or non-productive work stays out of this 40 hrs focussed work. And as long as I can continue to protect these 40 hrs of my time every week, everything shall be fine. Its almost always the inaction that causes anxiousness or doubt. So, my belief system currently stands towards protecting my time &amp; just building things in focussed time slots.</p>
<p>Here&#8217;s how it&#8217;s strictly planned:</p>
<ul>
<li>10 hrs = Consultancy work [To bring in immediate money]</li>
<li>10 hrs = Write books [To share what I know]</li>
<li>15 hrs = Build Micro SAAS</li>
<li>5 hrs  = Write blog posts [like this]</li>
</ul>
<p>I will continue to evolve my systems around how I function the best. As always, following me on Twitter is a good choice to keep up with what I am upto.</p>
<p>Happy new year! Hope this year brings you more happiness &amp; joy than ever &lt;3</p>
<p>The post <a href="https://blog.ashfame.com/2021/01/2020-in-review-accidental-gap-year/">2020-in-Review: Accidental Gap Year</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.ashfame.com/2021/01/2020-in-review-accidental-gap-year/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">1334</post-id>	</item>
		<item>
		<title>Show Ajax loading animation automatically using Pace</title>
		<link>https://blog.ashfame.com/2018/03/show-ajax-loading-animation-automatically-using-pace/</link>
					<comments>https://blog.ashfame.com/2018/03/show-ajax-loading-animation-automatically-using-pace/#respond</comments>
		
		<dc:creator><![CDATA[Ashfame]]></dc:creator>
		<pubDate>Fri, 09 Mar 2018 06:00:42 +0000</pubDate>
				<category><![CDATA[Uncategorized]]></category>
		<guid isPermaLink="false">https://blog.ashfame.com/?p=1298</guid>

					<description><![CDATA[<p>Making Hubspot's Pace library behave &#038; work as advertised</p>
<p>The post <a href="https://blog.ashfame.com/2018/03/show-ajax-loading-animation-automatically-using-pace/">Show Ajax loading animation automatically using Pace</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>There&#8217;s this cool library &#8211; [Pace](http://github.hubspot.com/pace/docs/welcome/) which shows cool animations when pages are loading, ajax requests are loading, your SPAs are changing pages etc. The only issue is it doesn&#8217;t work for all Ajax requests. Blame the defaults.</p>
<p>You need to define the `paceOptions` object for setting some defaults *before* loading the Pace library and that will make it work.</p>
<p>Here is what I am using:</p>
<p><a href="https://gist.github.com/cde19efed9e70ef5bb8778901ced9976" target="_blank"><em>View this code snippet on GitHub.</em></a></p>
<p>Discovered the morning after a frustrated purge of hours the night before. Hope it helped you save time!</p>
<p>The post <a href="https://blog.ashfame.com/2018/03/show-ajax-loading-animation-automatically-using-pace/">Show Ajax loading animation automatically using Pace</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.ashfame.com/2018/03/show-ajax-loading-animation-automatically-using-pace/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">1298</post-id>	</item>
		<item>
		<title>How much traffic does 200+ upvotes in a Product Hunt launch brings?</title>
		<link>https://blog.ashfame.com/2018/02/how-much-traffic-200-upvotes-producthunt-launch-brings/</link>
					<comments>https://blog.ashfame.com/2018/02/how-much-traffic-200-upvotes-producthunt-launch-brings/#respond</comments>
		
		<dc:creator><![CDATA[Ashfame]]></dc:creator>
		<pubDate>Sun, 25 Feb 2018 09:39:06 +0000</pubDate>
				<category><![CDATA[Uncategorized]]></category>
		<guid isPermaLink="false">https://blog.ashfame.com/?p=1293</guid>

					<description><![CDATA[<p>Getting 600+ websites being monitored in less than 2 weeks of launch</p>
<p>The post <a href="https://blog.ashfame.com/2018/02/how-much-traffic-200-upvotes-producthunt-launch-brings/">How much traffic does 200+ upvotes in a Product Hunt launch brings?</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>I launched [SSL Certificate Expiration Alerts](https://alerts.httpscop.com/) (SSL Alerts, as I like to call it) on [Producthunt](https://www.producthunt.com/posts/ssl-alerts) on 13th February 2018 &#038; got 200ish upvotes in one day, putting me at #7 Product of the day.</p>
<p>I had launched on other platforms like Reddit &#038; IndieHackers (Hacker News didn&#8217;t even let me post because my account was very new and I have been a lurker all my life), but nobody cared. So, compared to that, Product Hunt is the best platform to showcase the world what have you build, in my opinion.</p>
<p>Be warned that stats showed below are just an indicative parameter of how much visibility your product can have with so many upvotes. The very nature of product decides the mileage. I launched a free tool that apparently clicked, so I had very good stats. Your&#8217;s paid product that&#8217;s targetted to a niche would perform differently.</p>
<p>Here are 24hrs of PH launch stats:</p>
<p>[<img data-recalc-dims="1" fetchpriority="high" decoding="async" src="https://i0.wp.com/blog.ashfame.com/wp-content/uploads/2018/02/Screen-Shot-2018-02-25-at-2.50.59-PM.png?resize=1262%2C926&#038;ssl=1" alt="24hrs launch stats" width="1262" height="926" class="aligncenter size-full wp-image-1296" />](https://twitter.com/ashfame/status/963707135774179329)</p>
<p><!--
? #7 Product of the Day
? 222 upvotes
? 312 sessions (GA)
??? 153 new users
? 236 websites added

So 49% traffic conversion ?
Server Load: 0.1 ?
--></p>
<p>I should mention that my product literally climbed from being stuck in the bottom-most position in &#8220;Newest&#8221; category to #7. It took a while to get featured, which brings it in &#8220;Popular&#8221; category and hence more visibility. I also got [tweeted](https://twitter.com/ProductHunt/status/963744736057155585) by ProductHunt but I didn&#8217;t get included in the following day&#8217;s newsletter, which means more visibility but it could be even more. I think only Top 5 products get included in the newsletter.</p>
<p>Here is how Google Analytics look like:</p>
<p><img data-recalc-dims="1" decoding="async" src="https://i0.wp.com/blog.ashfame.com/wp-content/uploads/2018/02/Screen-Shot-2018-02-25-at-2.09.57-PM.png?resize=2328%2C892&#038;ssl=1" alt="Google Analytics View" width="2328" height="892" class="aligncenter size-full wp-image-1294" /></p>
<p>The first peak that you see is the PH launch. Its spread across 2 days, because PH launch days work as per San Fransisco (PST time) and I am looking at it from +5.5 GMT.</p>
<p>Curious about the second peak? That&#8217;s when Codrops picked the tool up and included it in #391 issue of Collective in which they curate cool things being made every few days. Surprisingly, it brought good enough traffic that&#8217;s comparable with ProductHunch for my rank (#7).</p>
<p>And as of this moment, I have got 365 users who have added 569 websites to be alerted for SSL certificate expiration.</p>
<p><img data-recalc-dims="1" decoding="async" src="https://i0.wp.com/blog.ashfame.com/wp-content/uploads/2018/02/Screen-Shot-2018-02-25-at-2.25.12-PM.png?resize=1266%2C432&#038;ssl=1" alt="Users acquired + Websites added stats" width="1266" height="432" class="aligncenter size-full wp-image-1295" /></p>
<p>The right column is for this tool, the left column is for the entire product (my primary product &#8211; *https cop*, which is a complete [website health monitoring system](https://httpscop.com), currently a Work In Progress). The free tool simply uses the engine of the primary product <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f642.png" alt="🙂" class="wp-smiley" style="height: 1em; max-height: 1em;" /></p>
<p>Comment or tweet (fastest means of communication) if you have questions or want to chat.</p>
<p>The post <a href="https://blog.ashfame.com/2018/02/how-much-traffic-200-upvotes-producthunt-launch-brings/">How much traffic does 200+ upvotes in a Product Hunt launch brings?</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.ashfame.com/2018/02/how-much-traffic-200-upvotes-producthunt-launch-brings/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">1293</post-id>	</item>
		<item>
		<title>Deploying to AWS lambdas to multiple regions in one go</title>
		<link>https://blog.ashfame.com/2018/02/deploying-lambdas-multiple-regions/</link>
					<comments>https://blog.ashfame.com/2018/02/deploying-lambdas-multiple-regions/#respond</comments>
		
		<dc:creator><![CDATA[Ashfame]]></dc:creator>
		<pubDate>Fri, 23 Feb 2018 07:38:42 +0000</pubDate>
				<category><![CDATA[Uncategorized]]></category>
		<guid isPermaLink="false">https://blog.ashfame.com/?p=1288</guid>

					<description><![CDATA[<p>Deploying your code to AWS Lambdas to multiple regions using a CLI ?</p>
<p>The post <a href="https://blog.ashfame.com/2018/02/deploying-lambdas-multiple-regions/">Deploying to AWS lambdas to multiple regions in one go</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>Building [uptime monitoring](https://httpscop.com) in https cop required me to deploy lambdas to multiple regions and this is my first introduction to the serverless world. I know of a very handy tool [Up](https://github.com/apex/up) to deploy to AWS Lambdas using a CLI without any hassle at all but it doesn&#8217;t support deploying to multiple regions at the time of writing (`Up version v0.5.0`).</p>
<p>After exchanging a few tweets with [TJ](https://twitter.com/tjholowaychuk) (creator of Up) I got to know I can specify `AWS_REGION` as an environment variable while calling Up and that will do the trick. Simply put, instead of defining regions in your `up.json` file, you can specify it at the time of invoking the command, like `AWS_REGION=us-east-1 up`.</p>
<p>So, one can (I did) write a bash script to do the deployments to all regions they desire at will.</p>
<p>Here is a quick [list of all regions](https://docs.aws.amazon.com/general/latest/gr/rande.html) where you can deploy with AWS Lambda:</p>
<table>
<tbody>
<tr>
<td>US East (Ohio)	                </td>
<td>us-east-2</td>
</tr>
<tr>
<td>US East (N. Virginia)	                </td>
<td>us-east-1</td>
</tr>
<tr>
<td>US West (N. California)	                </td>
<td>us-west-1</td>
</tr>
<tr>
<td>US West (Oregon)	                </td>
<td>us-west-2</td>
</tr>
<tr>
<td>Asia Pacific (Tokyo)	                </td>
<td>ap-northeast-1</td>
</tr>
<tr>
<td>Asia Pacific (Seoul)	                </td>
<td>ap-northeast-2</td>
</tr>
<tr>
<td>Asia Pacific (Mumbai)	                </td>
<td>ap-south-1</td>
</tr>
<tr>
<td>Asia Pacific (Singapore)	                </td>
<td>ap-southeast-1</td>
</tr>
<tr>
<td>Asia Pacific (Sydney)	                </td>
<td>ap-southeast-2</td>
</tr>
<tr>
<td>Canada (Central)	                </td>
<td>ca-central-1</td>
</tr>
<tr>
<td>China (Beijing)	                </td>
<td>cn-north-1</td>
</tr>
<tr>
<td>EU (Frankfurt)	                </td>
<td>eu-central-1</td>
</tr>
<tr>
<td>EU (Ireland)	                </td>
<td>eu-west-1</td>
</tr>
<tr>
<td>EU (London)	                </td>
<td>eu-west-2</td>
</tr>
<tr>
<td>EU (Paris)	                </td>
<td>eu-west-3</td>
</tr>
<tr>
<td>South America (Sao Paulo)	                </td>
<td>sa-east-1</td>
</tr>
</tbody>
</table>
<p>Pick the locations and make changes in the following bash script (remove or comment out the regions that you don&#8217;t want):</p>
<p><a href="https://gist.github.com/4a984205fac0e5fb87c4907284d42035" target="_blank"><em>View this code snippet on GitHub.</em></a></p>
<p>Hope that helps you ship!</p>
<p>P.S. &#8211; If you need all AWS Lambdas plotted on a map to see their geographical location, here you go:</p>
<p><figure id="attachment_1290" aria-describedby="caption-attachment-1290" style="width: 2880px" class="wp-caption aligncenter"><img data-recalc-dims="1" loading="lazy" decoding="async" src="https://i0.wp.com/blog.ashfame.com/wp-content/uploads/2018/02/aws-lambdas-on-map.png?resize=2880%2C1800&#038;ssl=1" alt="AWS lambdas marked on a map" width="2880" height="1800" class="size-full wp-image-1290" /><figcaption id="caption-attachment-1290" class="wp-caption-text">AWS lambdas marked on a map</figcaption></figure></p>
<p>The post <a href="https://blog.ashfame.com/2018/02/deploying-lambdas-multiple-regions/">Deploying to AWS lambdas to multiple regions in one go</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.ashfame.com/2018/02/deploying-lambdas-multiple-regions/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">1288</post-id>	</item>
		<item>
		<title>Keeping tab on Google Analytics Realtime view without staring at it</title>
		<link>https://blog.ashfame.com/2018/02/keeping-tab-google-analytics-realtime-view-without-staring/</link>
					<comments>https://blog.ashfame.com/2018/02/keeping-tab-google-analytics-realtime-view-without-staring/#respond</comments>
		
		<dc:creator><![CDATA[Ashfame]]></dc:creator>
		<pubDate>Tue, 13 Feb 2018 15:00:58 +0000</pubDate>
				<category><![CDATA[Uncategorized]]></category>
		<guid isPermaLink="false">https://blog.ashfame.com/?p=1282</guid>

					<description><![CDATA[<p>Contains Embedded Gist of Javascript code + GIF of the end-result in action</p>
<p>The post <a href="https://blog.ashfame.com/2018/02/keeping-tab-google-analytics-realtime-view-without-staring/">Keeping tab on Google Analytics Realtime view without staring at it</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>Today, I have launched [SSL certificate expiration alerts](https://alerts.httpscop.com) on [Producthunt](https://www.producthunt.com/posts/ssl-alerts). It&#8217;s going well, so like anybody else, I am really keen on watching real-time traffic view of Google Analytics. But that&#8217;s stopping me to do more work. So, I looked up and found this cool piece of Javascript code, which you can run in your Browser&#8217;s console and it will keep on alerting you of active users whenever that changes every 5 seconds:</p>
<p><a href="https://gist.github.com/f26072ddbbbbde88e508f89291d2ef8f" target="_blank"><em>View this code snippet on GitHub.</em></a></p>
<p>Hope you enjoyed this little hack!</p>
<p>The post <a href="https://blog.ashfame.com/2018/02/keeping-tab-google-analytics-realtime-view-without-staring/">Keeping tab on Google Analytics Realtime view without staring at it</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.ashfame.com/2018/02/keeping-tab-google-analytics-realtime-view-without-staring/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">1282</post-id>	</item>
		<item>
		<title>Setting cron to be run as root</title>
		<link>https://blog.ashfame.com/2017/01/setting-cron-run-root/</link>
					<comments>https://blog.ashfame.com/2017/01/setting-cron-run-root/#respond</comments>
		
		<dc:creator><![CDATA[Ashfame]]></dc:creator>
		<pubDate>Sun, 22 Jan 2017 17:19:10 +0000</pubDate>
				<category><![CDATA[How To / Tutorials]]></category>
		<guid isPermaLink="false">https://blog.ashfame.com/?p=1244</guid>

					<description><![CDATA[<p>In Linux based distros, its very simple to setup cron for repeated tasks by using `crontab -e` for editing the crontab of the current user as you are logged in. You can view the contents of your crontab by `crontab -l`. But if you need to call something with root privileges, its as simple as [&#8230;]</p>
<p>The post <a href="https://blog.ashfame.com/2017/01/setting-cron-run-root/">Setting cron to be run as root</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>In Linux based distros, its very simple to setup cron for repeated tasks by using `crontab -e` for editing the crontab of the current user as you are logged in. You can view the contents of your crontab by `crontab -l`.</p>
<p>But if you need to call something with root privileges, its as simple as `sudo crontab -e`. This adds your changes to root user&#8217;s crontab. To view root user&#8217;s crontab, you can again do `sudo crontab -l` and you can see the difference.</p>
<p>Bonus tip: The first time you open crontab for editing, it opens it in vim. Those of you who are hardcore guys, know their way around, but they are not reading this anyway. I am not hardcode, I do know basic vim commands, but I like to use nano. If you are on the same boat as me, use this `export EDITOR=nano`. Now go get shit done!</p>
<p>The post <a href="https://blog.ashfame.com/2017/01/setting-cron-run-root/">Setting cron to be run as root</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.ashfame.com/2017/01/setting-cron-run-root/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">1244</post-id>	</item>
		<item>
		<title>Verify sending domain inside Mandrill without email hosting</title>
		<link>https://blog.ashfame.com/2016/11/verify-sending-domain-mandrill-email-hosting/</link>
					<comments>https://blog.ashfame.com/2016/11/verify-sending-domain-mandrill-email-hosting/#comments</comments>
		
		<dc:creator><![CDATA[Ashfame]]></dc:creator>
		<pubDate>Tue, 22 Nov 2016 20:05:58 +0000</pubDate>
				<category><![CDATA[How To / Tutorials]]></category>
		<category><![CDATA[Emails]]></category>
		<category><![CDATA[Mandrill]]></category>
		<guid isPermaLink="false">https://blog.ashfame.com/?p=1227</guid>

					<description><![CDATA[<p>Mandrill has enforced upon us that the only way to verify a sending-domain (domain used to send emails from) is by getting an email sent by them on an email of the sending-domain in use. So, if you use **example.org** or **something.example.org** to send emails, you can now only verify your sending-domain, by receiving an [&#8230;]</p>
<p>The post <a href="https://blog.ashfame.com/2016/11/verify-sending-domain-mandrill-email-hosting/">Verify sending domain inside Mandrill without email hosting</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>Mandrill has enforced upon us that the only way to verify a sending-domain (domain used to send emails from) is by getting an email sent by them on an email of the sending-domain in use. So, if you use **example.org** or **something.example.org** to send emails, you can now only verify your sending-domain, by receiving an email from them on **anyemail@example.org** or **anyemail@something.example.org** in which you have to click on a verification link to validate your ownership of the domain.</p>
<p>Now that&#8217;s not ideal. Add a TXT record is enough for verification purpose, and that&#8217;s essentially the step that proves the ownership of domain through this step only but this is how it is.</p>
<p>The only issue with this approach is that one must have email hosting or an email inbox setup to receive emails on that domain. If you already have a working email on the sending-domain, you don&#8217;t need to read the rest of the post. Simply, enter the working email for verification and get it over with. But if you don&#8217;t, then instead of setting up email hosting somewhere for just verification purpose, you can utilize this trick I discovered. Its quick enough &#038; free alternative to do so by simply using Inbound emails feature in Mandrill accounts.</p>
<p>Here is how to do it:<br />
&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;</p>
<p>Add your domain under &#8220;Inbound domains&#8221;</p>
<p><img data-recalc-dims="1" loading="lazy" decoding="async" src="https://i0.wp.com/blog.ashfame.com/wp-content/uploads/2016/11/Screen-Shot-2016-11-23-at-12.51.01-AM.png?resize=1000%2C346&#038;ssl=1" alt="screen-shot-2016-11-23-at-12-51-01-am" width="1000" height="346" class="aligncenter size-full wp-image-1235" /></p>
<p>Now add MX record for your sending domain as per the instructions</p>
<p><img data-recalc-dims="1" loading="lazy" decoding="async" src="https://i0.wp.com/blog.ashfame.com/wp-content/uploads/2016/11/Screen-Shot-2016-11-23-at-12.51.37-AM.png?resize=878%2C776&#038;ssl=1" alt="screen-shot-2016-11-23-at-12-51-37-am" width="878" height="776" class="aligncenter size-full wp-image-1230" /></p>
<p>Add those MX records in your DNS and then validate those records are reflecting by clicking on &#8220;Test DNS settings&#8221;.</p>
<p>Once confirmed, simply setup a route for that domain, by clicking the arrow on the right of &#8220;Test DNS settings&#8221; link.</p>
<p><img data-recalc-dims="1" loading="lazy" decoding="async" src="https://i0.wp.com/blog.ashfame.com/wp-content/uploads/2016/11/Screen-Shot-2016-11-23-at-12.55.48-AM.png?resize=696%2C606&#038;ssl=1" alt="screen-shot-2016-11-23-at-12-55-48-am" width="696" height="606" class="aligncenter size-full wp-image-1231" /></p>
<p>Configure webhook POST URL to a URL you obtained on [https://requestb.in](https://requestb.in)</p>
<p><img data-recalc-dims="1" loading="lazy" decoding="async" src="https://i0.wp.com/blog.ashfame.com/wp-content/uploads/2016/11/Screen-Shot-2016-11-23-at-12.56.07-AM.png?resize=938%2C322&#038;ssl=1" alt="screen-shot-2016-11-23-at-12-56-07-am" width="938" height="322" class="aligncenter size-full wp-image-1232" /></p>
<p><img data-recalc-dims="1" loading="lazy" decoding="async" src="https://i0.wp.com/blog.ashfame.com/wp-content/uploads/2016/11/Screen-Shot-2016-11-23-at-12.57.20-AM.png?resize=1166%2C676&#038;ssl=1" alt="screen-shot-2016-11-23-at-12-57-20-am" width="1166" height="676" class="aligncenter size-full wp-image-1233" /></p>
<p>Now go to verification of send domains, enter the email address you configured and wait for the email to come at your https://requestb.in/XXXXXXX URL.</p>
<p><img data-recalc-dims="1" loading="lazy" decoding="async" src="https://i0.wp.com/blog.ashfame.com/wp-content/uploads/2016/11/Screen-Shot-2016-11-23-at-12.57.58-AM.png?resize=2198%2C854&#038;ssl=1" alt="screen-shot-2016-11-23-at-12-57-58-am" width="2198" height="854" class="aligncenter size-full wp-image-1234" /></p>
<p>Find the link, copy and paste it in the browser.</p>
<p>And you are done!</p>
<p>The post <a href="https://blog.ashfame.com/2016/11/verify-sending-domain-mandrill-email-hosting/">Verify sending domain inside Mandrill without email hosting</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.ashfame.com/2016/11/verify-sending-domain-mandrill-email-hosting/feed/</wfw:commentRss>
			<slash:comments>5</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">1227</post-id>	</item>
		<item>
		<title>Store Just WordPress Transients Persistently</title>
		<link>https://blog.ashfame.com/2015/04/store-just-transients-persistently/</link>
					<comments>https://blog.ashfame.com/2015/04/store-just-transients-persistently/#respond</comments>
		
		<dc:creator><![CDATA[Ashfame]]></dc:creator>
		<pubDate>Fri, 17 Apr 2015 09:44:00 +0000</pubDate>
				<category><![CDATA[WordPress]]></category>
		<category><![CDATA[Transients]]></category>
		<category><![CDATA[Wishlist]]></category>
		<category><![CDATA[WordPress plugin]]></category>
		<category><![CDATA[WP-CLI]]></category>
		<guid isPermaLink="false">http://blog.ashfame.com/?p=1166</guid>

					<description><![CDATA[<p>WordPress comes with an option of keeping cache in a persistent storage, if provided. It provides a great deal of performance since everything that WordPress was doing repeatedly on each page request now can be saved in the persistent cache storage (APC / Memcached / Redis) and retrieve easily &#038; very fastly without doing much [&#8230;]</p>
<p>The post <a href="https://blog.ashfame.com/2015/04/store-just-transients-persistently/">Store Just WordPress Transients Persistently</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>WordPress comes with an option of keeping cache in a persistent storage, if provided. It provides a great deal of performance since everything that WordPress was doing repeatedly on each page request now can be saved in the persistent cache storage (APC / Memcached / Redis) and retrieve easily &#038; very fastly without doing much work.</p>
<p>The way to activate that is to drop an `object-cache.php` file in your `wp-content` directory which does the heavy lifting for you. Following plugins are available if you want to get started with it:</p>
<p>* APC &#8211; [https://wordpress.org/plugins/apc/](https://wordpress.org/plugins/apc/)<br />
* Memcached &#8211; [https://wordpress.org/plugins/memcached/](https://wordpress.org/plugins/memcached/)<br />
* Redis &#8211; [https://wordpress.org/plugins/redis-cache/](https://wordpress.org/plugins/redis-cache/)<br />
* Another worthy mention, which works with APC / Memcached / Xcache /  &#8211; [https://wordpress.org/plugins/tribe-object-cache/](https://wordpress.org/plugins/tribe-object-cache/)</p>
<p>You don&#8217;t have a reason to not use object caching unless you are stuck with a plugin which doesn&#8217;t follow WordPress standards and causes the site to malfunction when a persistent cache storage is used. An example of such a plugin is Wishlist Member plugin.</p>
<p>It simply doesn&#8217;t work well with persistent object cache because it updates the options table directly by making SQL queries instead of using functions like `get_option()`, `update_option()` etc.</p>
<p>I needed to solve the problem, where we could atleast store some of stuff in the persistent cache &#038; hence improving performance. The site for which this was done, is a learning portal where all members are logged in, hence full pages were generated dynamically every single time. To take off some of the load, I developed a plugin in which transients are stored in memcached (persistent storage) so that they can be retrieved very quickly without making SQL queries to the database.</p>
<p>I suggest you use this plugin or use it as a starting point to build what you need. Plugins of this kind, require installation &#038; verification by a developer since its a very barebones-prototype plugin, which does the job of saving transients and retrieving them quickly.</p>
<p>Plugin&#8217;s repository &#8211; [https://github.com/ashfame/Store-Just-Transients-Persistently](https://github.com/ashfame/Store-Just-Transients-Persistently)</p>
<p>It also overrides wp transient delete-all WP-CLI command so that you can flush transients from both database and memcached (persistent cache storage in use).</p>
<p>Its always a good idea to contribute back your work to the plugin if you build on top of it or extend it, so that other community members can gain from it.</p>
<p>Let me know if you have a question that I can help answer.</p>
<p>The post <a href="https://blog.ashfame.com/2015/04/store-just-transients-persistently/">Store Just WordPress Transients Persistently</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.ashfame.com/2015/04/store-just-transients-persistently/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">1166</post-id>	</item>
		<item>
		<title>Override WP-CLI commands</title>
		<link>https://blog.ashfame.com/2015/04/override-wpcli-commands/</link>
					<comments>https://blog.ashfame.com/2015/04/override-wpcli-commands/#respond</comments>
		
		<dc:creator><![CDATA[Ashfame]]></dc:creator>
		<pubDate>Mon, 13 Apr 2015 14:13:01 +0000</pubDate>
				<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WP-CLI]]></category>
		<guid isPermaLink="false">http://blog.ashfame.com/?p=1162</guid>

					<description><![CDATA[<p>If you already don&#8217;t know about WP-CLI, its a pretty great tool to manage a WordPress install via terminal commands. This essentially gives you a lot of power enabling you to interact with the WordPress install just by commands and not having to interact with UI at all. Read more at [WP-CLI&#8217;s homepage](http://wp-cli.org/). It can [&#8230;]</p>
<p>The post <a href="https://blog.ashfame.com/2015/04/override-wpcli-commands/">Override WP-CLI commands</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>If you already don&#8217;t know about WP-CLI, its a pretty great tool to manage a WordPress install via terminal commands. This essentially gives you a lot of power enabling you to interact with the WordPress install just by commands and not having to interact with UI at all. Read more at [WP-CLI&#8217;s homepage](http://wp-cli.org/).</p>
<p>It can also be extended to add custom commands. The usual way to do can be read in detail here &#8211; [https://github.com/wp-cli/wp-cli/wiki/Commands-Cookbook](https://github.com/wp-cli/wp-cli/wiki/Commands-Cookbook) but the essence is to create a new PHP Class extending from `WP_CLI_Command` and then just add that class as a handler for a command by calling `WP_CLI::add_command()`.</p>
<p>Now for instance, what if you want to redefine an existing wp-cli command? The way to do that is to create a new PHP Class as if you were creating a new custom command, and then instead of extending it from `WP_CLI_Command`, extend it from the PHP Class which defines the command you want to override. Simple enough! Here&#8217;s an example:</p>
<p>`wp transient delete-all` lets you delete all transients from the database. Yes, database. If you know about persistent caching storage options with WordPress like Memcache or APC, then transients are not actually stored in database anymore. They are simply stored in the persistent cache storage. And since the delete-all subcommand of `transient` command only runs a SQL query to delete them from database, it simply does nothing if the site uses persistent cache storage (Object cache drop-in `object-cache.php`, if that reminds you of it).</p>
<p>So you can define a new PHP Class something like this:</p>
<p><a href="https://gist.github.com/b21c223e904da83bedab" target="_blank"><em>View this code snippet on GitHub.</em></a></p>
<p>Pretty straight-forward, right?</p>
<p>Using the same technique, you can add new sub commands to an existing command as well by simply defining a new method.</p>
<p>On the transient issue note, why that shouldn&#8217;t be fixed in WP-CLI itself is a question that intrigues me as well. From a quick look at their Github issues, seems like they want to support it in a way it works correctly with persistent cache storage, but haven&#8217;t got to that place yet. I will see how soon I can create a patch for it and send a pull request.</p>
<p>Have fun with WP-CLI!</p>
<p>The post <a href="https://blog.ashfame.com/2015/04/override-wpcli-commands/">Override WP-CLI commands</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.ashfame.com/2015/04/override-wpcli-commands/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">1162</post-id>	</item>
		<item>
		<title>Filtering transient expiration time in WordPress</title>
		<link>https://blog.ashfame.com/2014/12/filtering-transient-expiration-wordpress/</link>
					<comments>https://blog.ashfame.com/2014/12/filtering-transient-expiration-wordpress/#comments</comments>
		
		<dc:creator><![CDATA[Ashfame]]></dc:creator>
		<pubDate>Sat, 27 Dec 2014 18:54:01 +0000</pubDate>
				<category><![CDATA[WordPress]]></category>
		<guid isPermaLink="false">http://blog.ashfame.com/?p=1146</guid>

					<description><![CDATA[<p>As of now WordPress, doesn&#8217;t offer a filter to control the expiration of the transient while its being set, so I quickly wanted to share a quick snippet I found on Trac, written by Andrew Nacin. Here is the snippet: Basically, `&#8217;set_transient_&#8217; . $transient` hook is fired once the transient gets saved, so it saves [&#8230;]</p>
<p>The post <a href="https://blog.ashfame.com/2014/12/filtering-transient-expiration-wordpress/">Filtering transient expiration time in WordPress</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>As of now WordPress, doesn&#8217;t offer a filter to control the expiration of the transient while its being set, so I quickly wanted to share a quick snippet I found on Trac, written by Andrew Nacin.</p>
<p>Here is the snippet:</p>
<p><a href="https://gist.github.com/3b64e4d2b17a1ee13c09" target="_blank"><em>View this code snippet on GitHub.</em></a></p>
<p>Basically, `&#8217;set_transient_&#8217; . $transient` hook is fired once the transient gets saved, so it saves itself again resulting in recursion as the same hook will be fired again, but before it saves itself again, it checks whether the `$desired_expiration` is different from the `$expiration` with which it&#8217;s being saved. Smart!</p>
<p>On a side note, if you ever need to do this, don&#8217;t use anonymous functions because that takes away the ability to unhook your function by someone else. Its just a quick way to demonstrate the idea.</p>
<p>Concerned Trac Ticket &#8211; [https://core.trac.wordpress.org/ticket/21330](https://core.trac.wordpress.org/ticket/21330)</p>
<p>The post <a href="https://blog.ashfame.com/2014/12/filtering-transient-expiration-wordpress/">Filtering transient expiration time in WordPress</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.ashfame.com/2014/12/filtering-transient-expiration-wordpress/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">1146</post-id>	</item>
		<item>
		<title>Quickest way to get timestamp of a time in a particular timezone in PHP</title>
		<link>https://blog.ashfame.com/2014/05/get-timestamp-particular-timezone-php/</link>
					<comments>https://blog.ashfame.com/2014/05/get-timestamp-particular-timezone-php/#respond</comments>
		
		<dc:creator><![CDATA[Ashfame]]></dc:creator>
		<pubDate>Mon, 12 May 2014 10:29:29 +0000</pubDate>
				<category><![CDATA[programming]]></category>
		<category><![CDATA[Tips n Tricks]]></category>
		<guid isPermaLink="false">http://blog.ashfame.com/?p=1126</guid>

					<description><![CDATA[<p>Playing with timezone conversions can be crazy, it still confuses me every time and I have to wait a minute to run some test code to figure out what&#8217;s it that I am trying to do here. Anyway, the quickest way I have to get timestamp of a time in particular time zone is This [&#8230;]</p>
<p>The post <a href="https://blog.ashfame.com/2014/05/get-timestamp-particular-timezone-php/">Quickest way to get timestamp of a time in a particular timezone in PHP</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>Playing with timezone conversions can be crazy, it still confuses me every time and I have to wait a minute to run some test code to figure out what&#8217;s it that I am trying to do here.</p>
<p>Anyway, the quickest way I have to get timestamp of a time in particular time zone is</p>
<style>.gist table { margin-bottom: 0; }</style>
<div style="tab-size: 8" id="gist10638929" class="gist">
<div class="gist-file" translate="no" data-color-mode="light" data-light-theme="light">
<div class="gist-data">
<div class="js-gist-file-update-container js-task-list-container">
<div id="file-time-php" class="file my-2">
<div itemprop="text"
      class="Box-body p-0 blob-wrapper data type-php  "
      style="overflow: auto" tabindex="0" role="region"
      aria-label="time.php content, created by ashfame on 11:16AM on April 14, 2014."
    ></p>
<div class="js-check-hidden-unicode js-blob-code-container blob-code-content">
<p>  <template class="js-file-alert-template"></p>
<div data-view-component="true" class="flash flash-warn flash-full d-flex flex-items-center">
  <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert">
    <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path>
</svg><br />
    <span><br />
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.<br />
      <a class="Link--inTextBlock" href="https://github.co/hiddenchars" target="_blank">Learn more about bidirectional Unicode characters</a><br />
    </span></p>
<div data-view-component="true" class="flash-action">        <a href="{{ revealButtonHref }}" data-view-component="true" class="btn-sm btn">    Show hidden characters<br />
</a>
</div>
</div>
<p></template><br />
<template class="js-line-alert-template"><br />
  <span aria-label="This line has hidden Unicode characters" data-view-component="true" class="line-alert tooltipped tooltipped-e"><br />
    <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert">
    <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path>
</svg><br />
</span></template></p>
<table data-hpc class="highlight tab-size js-file-line-container" data-tab-size="4" data-paste-markdown-skip data-tagsearch-path="time.php">
<tr>
<td id="file-time-php-L1" class="blob-num js-line-number js-blob-rnum" data-line-number="1"></td>
<td id="file-time-php-LC1" class="blob-code blob-code-inner js-file-line">&lt;?php</td>
</tr>
<tr>
<td id="file-time-php-L2" class="blob-num js-line-number js-blob-rnum" data-line-number="2"></td>
<td id="file-time-php-LC2" class="blob-code blob-code-inner js-file-line">
</td>
</tr>
<tr>
<td id="file-time-php-L3" class="blob-num js-line-number js-blob-rnum" data-line-number="3"></td>
<td id="file-time-php-LC3" class="blob-code blob-code-inner js-file-line">$datetimezone_object = new DateTimeZone(&#39;Pacific/Nauru&#39;); // new DateTimeZone(&#39;PST&#39;);</td>
</tr>
<tr>
<td id="file-time-php-L4" class="blob-num js-line-number js-blob-rnum" data-line-number="4"></td>
<td id="file-time-php-LC4" class="blob-code blob-code-inner js-file-line">$date = DateTime::createFromFormat( &#39;Y-m-d H:i:s&#39;, &#39;2014-04-14 05:00:00&#39;, $datetimezone_object );</td>
</tr>
<tr>
<td id="file-time-php-L5" class="blob-num js-line-number js-blob-rnum" data-line-number="5"></td>
<td id="file-time-php-LC5" class="blob-code blob-code-inner js-file-line">echo $date-&gt;getTimestamp();</td>
</tr>
</table>
</div></div>
</p></div>
</div></div>
<div class="gist-meta">
        <a href="https://gist.github.com/ashfame/e93709b755810168ed37/raw/8c92e99863a3e3a0c1922f479989b82b13730f2b/time.php" style="float:right" class="Link--inTextBlock">view raw</a><br />
        <a href="https://gist.github.com/ashfame/e93709b755810168ed37#file-time-php" class="Link--inTextBlock"><br />
          time.php<br />
        </a><br />
        hosted with &#10084; by <a class="Link--inTextBlock" href="https://github.com">GitHub</a>
      </div>
</p></div>
</div>
<p>`DateTime` and `DateTimeZone` classes are what you need to know when dealing with timezones, ditch any other method of doing conversions in PHP. Seriously, there are no better ways of doing it.</p>
<p>And just a tip, if you already don&#8217;t know, timestamp from different timezones for a single point of time is same. It doesn&#8217;t depend on the timezone. Did you know? <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f642.png" alt="🙂" class="wp-smiley" style="height: 1em; max-height: 1em;" /></p>
<p>Let me know in the comments if you have a question.</p>
<p>The post <a href="https://blog.ashfame.com/2014/05/get-timestamp-particular-timezone-php/">Quickest way to get timestamp of a time in a particular timezone in PHP</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.ashfame.com/2014/05/get-timestamp-particular-timezone-php/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">1126</post-id>	</item>
		<item>
		<title>How to use a single image on Facebook when your website is shared</title>
		<link>https://blog.ashfame.com/2014/05/use-single-image-facebook-website-shared/</link>
					<comments>https://blog.ashfame.com/2014/05/use-single-image-facebook-website-shared/#respond</comments>
		
		<dc:creator><![CDATA[Ashfame]]></dc:creator>
		<pubDate>Sun, 11 May 2014 10:13:26 +0000</pubDate>
				<category><![CDATA[WordPress]]></category>
		<guid isPermaLink="false">http://blog.ashfame.com/?p=1125</guid>

					<description><![CDATA[<p>Ideally, you would want to use context specific images to be shown on Facebook whenever any page of your WordPress website is shared on Facebook, but if for some reason you want only a single image to be shown irrespective of the context, that can be configured using my plugin &#8211; [Facebook Like Thumbnail](http://wordpress.org/plugins/facebook-like-thumbnail/) though [&#8230;]</p>
<p>The post <a href="https://blog.ashfame.com/2014/05/use-single-image-facebook-website-shared/">How to use a single image on Facebook when your website is shared</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>Ideally, you would want to use context specific images to be shown on Facebook whenever any page of your WordPress website is shared on Facebook, but if for some reason you want only a single image to be shown irrespective of the context, that can be configured using my plugin &#8211; [Facebook Like Thumbnail](http://wordpress.org/plugins/facebook-like-thumbnail/) though it specifies context specific images by default.</p>
<p>You need to install the plugin, configure the default image to be used from the settings page. And then paste the following code in your functions.php file:</p>
<style>.gist table { margin-bottom: 0; }</style>
<div style="tab-size: 8" id="gist11682813" class="gist">
<div class="gist-file" translate="no" data-color-mode="light" data-light-theme="light">
<div class="gist-data">
<div class="js-gist-file-update-container js-task-list-container">
<div id="file-facebook-like-thumbnail-force-default-image-everywhere-php" class="file my-2">
<div itemprop="text"
      class="Box-body p-0 blob-wrapper data type-php  "
      style="overflow: auto" tabindex="0" role="region"
      aria-label="facebook-like-thumbnail-force-default-image-everywhere.php content, created by ashfame on 10:04AM on May 11, 2014."
    ></p>
<div class="js-check-hidden-unicode js-blob-code-container blob-code-content">
<p>  <template class="js-file-alert-template"></p>
<div data-view-component="true" class="flash flash-warn flash-full d-flex flex-items-center">
  <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert">
    <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path>
</svg><br />
    <span><br />
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.<br />
      <a class="Link--inTextBlock" href="https://github.co/hiddenchars" target="_blank">Learn more about bidirectional Unicode characters</a><br />
    </span></p>
<div data-view-component="true" class="flash-action">        <a href="{{ revealButtonHref }}" data-view-component="true" class="btn-sm btn">    Show hidden characters<br />
</a>
</div>
</div>
<p></template><br />
<template class="js-line-alert-template"><br />
  <span aria-label="This line has hidden Unicode characters" data-view-component="true" class="line-alert tooltipped tooltipped-e"><br />
    <svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" data-view-component="true" class="octicon octicon-alert">
    <path d="M6.457 1.047c.659-1.234 2.427-1.234 3.086 0l6.082 11.378A1.75 1.75 0 0 1 14.082 15H1.918a1.75 1.75 0 0 1-1.543-2.575Zm1.763.707a.25.25 0 0 0-.44 0L1.698 13.132a.25.25 0 0 0 .22.368h12.164a.25.25 0 0 0 .22-.368Zm.53 3.996v2.5a.75.75 0 0 1-1.5 0v-2.5a.75.75 0 0 1 1.5 0ZM9 11a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z"></path>
</svg><br />
</span></template></p>
<table data-hpc class="highlight tab-size js-file-line-container" data-tab-size="4" data-paste-markdown-skip data-tagsearch-path="facebook-like-thumbnail-force-default-image-everywhere.php">
<tr>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-L1" class="blob-num js-line-number js-blob-rnum" data-line-number="1"></td>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-LC1" class="blob-code blob-code-inner js-file-line">&lt;?php</td>
</tr>
<tr>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-L2" class="blob-num js-line-number js-blob-rnum" data-line-number="2"></td>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-LC2" class="blob-code blob-code-inner js-file-line">
</td>
</tr>
<tr>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-L3" class="blob-num js-line-number js-blob-rnum" data-line-number="3"></td>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-LC3" class="blob-code blob-code-inner js-file-line">/**</td>
</tr>
<tr>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-L4" class="blob-num js-line-number js-blob-rnum" data-line-number="4"></td>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-LC4" class="blob-code blob-code-inner js-file-line"> * Plugin Name: Facebook Like Thumbnail &#8211; Force Default Image everywhere</td>
</tr>
<tr>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-L5" class="blob-num js-line-number js-blob-rnum" data-line-number="5"></td>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-LC5" class="blob-code blob-code-inner js-file-line"> * Plugin URI: https://gist.github.com/ashfame/62f59587aaa5c8ecb1ce</td>
</tr>
<tr>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-L6" class="blob-num js-line-number js-blob-rnum" data-line-number="6"></td>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-LC6" class="blob-code blob-code-inner js-file-line"> * Description: Forces the default image to be used as FB Thumbnail for every page</td>
</tr>
<tr>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-L7" class="blob-num js-line-number js-blob-rnum" data-line-number="7"></td>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-LC7" class="blob-code blob-code-inner js-file-line"> * Author: Ashfame</td>
</tr>
<tr>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-L8" class="blob-num js-line-number js-blob-rnum" data-line-number="8"></td>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-LC8" class="blob-code blob-code-inner js-file-line"> * Author URI: http://ashfame.com/</td>
</tr>
<tr>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-L9" class="blob-num js-line-number js-blob-rnum" data-line-number="9"></td>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-LC9" class="blob-code blob-code-inner js-file-line"> */</td>
</tr>
<tr>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-L10" class="blob-num js-line-number js-blob-rnum" data-line-number="10"></td>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-LC10" class="blob-code blob-code-inner js-file-line">
</td>
</tr>
<tr>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-L11" class="blob-num js-line-number js-blob-rnum" data-line-number="11"></td>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-LC11" class="blob-code blob-code-inner js-file-line">add_filter( &#39;fb_like_thumbnail_shortcircuit&#39;, &#39;force_single_fb_thumbnail&#39; );</td>
</tr>
<tr>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-L12" class="blob-num js-line-number js-blob-rnum" data-line-number="12"></td>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-LC12" class="blob-code blob-code-inner js-file-line">
</td>
</tr>
<tr>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-L13" class="blob-num js-line-number js-blob-rnum" data-line-number="13"></td>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-LC13" class="blob-code blob-code-inner js-file-line">function force_single_fb_thumbnail( $shortcircuit ) {</td>
</tr>
<tr>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-L14" class="blob-num js-line-number js-blob-rnum" data-line-number="14"></td>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-LC14" class="blob-code blob-code-inner js-file-line">	if ( class_exists( &#39;Ashfame_Facebook_Like_Thumbnail&#39; ) &amp;&amp; ! empty( Ashfame_Facebook_Like_Thumbnail::$options[&#39;default&#39;] ) ) {</td>
</tr>
<tr>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-L15" class="blob-num js-line-number js-blob-rnum" data-line-number="15"></td>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-LC15" class="blob-code blob-code-inner js-file-line">		return Ashfame_Facebook_Like_Thumbnail::$options[&#39;default&#39;];</td>
</tr>
<tr>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-L16" class="blob-num js-line-number js-blob-rnum" data-line-number="16"></td>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-LC16" class="blob-code blob-code-inner js-file-line">	}</td>
</tr>
<tr>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-L17" class="blob-num js-line-number js-blob-rnum" data-line-number="17"></td>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-LC17" class="blob-code blob-code-inner js-file-line">
</td>
</tr>
<tr>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-L18" class="blob-num js-line-number js-blob-rnum" data-line-number="18"></td>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-LC18" class="blob-code blob-code-inner js-file-line">	return $shortcircuit;</td>
</tr>
<tr>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-L19" class="blob-num js-line-number js-blob-rnum" data-line-number="19"></td>
<td id="file-facebook-like-thumbnail-force-default-image-everywhere-php-LC19" class="blob-code blob-code-inner js-file-line">}</td>
</tr>
</table>
</div></div>
</p></div>
</div></div>
<div class="gist-meta">
        <a href="https://gist.github.com/ashfame/62f59587aaa5c8ecb1ce/raw/297799823f02456a1df3d4c416f29103768d1d04/facebook-like-thumbnail-force-default-image-everywhere.php" style="float:right" class="Link--inTextBlock">view raw</a><br />
        <a href="https://gist.github.com/ashfame/62f59587aaa5c8ecb1ce#file-facebook-like-thumbnail-force-default-image-everywhere-php" class="Link--inTextBlock"><br />
          facebook-like-thumbnail-force-default-image-everywhere.php<br />
        </a><br />
        hosted with &#10084; by <a class="Link--inTextBlock" href="https://github.com">GitHub</a>
      </div>
</p></div>
</div>
<p>This short-circuits the logic of the plugin and specifies the default image specified in settings to be used for all pages.</p>
<p>I see this use-case as being very limited to what everyone would want, so I don&#8217;t want this to be added as another option in the plugin itself, but it can be achieved using short-circuit opportunity offered by the plugin&#8217;s architecture. Even if you want to plug in custom logic to figure out the image to use, that&#8217;s possible too.</p>
<p>Let me know if you run into any issues.</p>
<p>The post <a href="https://blog.ashfame.com/2014/05/use-single-image-facebook-website-shared/">How to use a single image on Facebook when your website is shared</a> appeared first on <a href="https://blog.ashfame.com">Ashfame | Blog</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.ashfame.com/2014/05/use-single-image-facebook-website-shared/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">1125</post-id>	</item>
	</channel>
</rss>