<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Ashwin K Shenoy</title>
    <description>The latest articles on DEV Community by Ashwin K Shenoy (@ashwinkshenoy).</description>
    <link>https://dev.to/ashwinkshenoy</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F193531%2F2f5255b9-e7d8-4f51-ad1c-4916adeb6991.jpg</url>
      <title>DEV Community: Ashwin K Shenoy</title>
      <link>https://dev.to/ashwinkshenoy</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/ashwinkshenoy"/>
    <language>en</language>
    <item>
      <title>Php Send Mail</title>
      <dc:creator>Ashwin K Shenoy</dc:creator>
      <pubDate>Fri, 17 Apr 2020 03:28:12 +0000</pubDate>
      <link>https://dev.to/ashwinkshenoy/php-send-mail-49e4</link>
      <guid>https://dev.to/ashwinkshenoy/php-send-mail-49e4</guid>
      <description>&lt;p&gt;I agree that many newbies don't use Php nowadays. But this post is for noobs like me at Php :)&lt;/p&gt;

&lt;p&gt;After installing Sendmail on ubuntu server 14.04 / 16.04, I tried sending mail from my PHP script and it was painfully slow. I thought I had not configured Apache / Nginx properly. Me being a noob at this tried to delete the snapshot and reinstalled with ubuntu 14.04 (earlier one being ubuntu 16). Still, the issue persisted. After a lot of googling I kind of figured a solution.&lt;/p&gt;

&lt;p&gt;Initially determine the hostname of your server by typing:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight plaintext"&gt;&lt;code&gt;hostname
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;



&lt;p&gt;This will reveal your hostname.&lt;/p&gt;

&lt;p&gt;Then go to &lt;code&gt;/etc/hosts&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo vi /etc/hosts
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;



&lt;p&gt;Modify the line with IP to read as:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight plaintext"&gt;&lt;code&gt;127.0.0.1    localhost localhost.localdomain ashwin
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;



&lt;p&gt;(where “ashwin” is my server’s hostname, you should add your server’s hostname — duh!)&lt;/p&gt;

&lt;p&gt;Finally, I ran&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo sendmailconfig
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;



&lt;p&gt;Answer Y to all the questions asked to rebuild/reload Sendmail configuration.&lt;/p&gt;

&lt;p&gt;That’s it, Send Mail started working!&lt;/p&gt;

&lt;p&gt;Hope this helps for people who struggled with installing a new server in Digital Ocean / AWS and trying to send mail!&lt;/p&gt;

&lt;p&gt;That’s the end of this blog post! &lt;br&gt;
Thanks for reading! If you like it, please hit ♥️&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Block ads on Spotify App</title>
      <dc:creator>Ashwin K Shenoy</dc:creator>
      <pubDate>Thu, 11 Jul 2019 06:51:51 +0000</pubDate>
      <link>https://dev.to/ashwinkshenoy/block-ads-on-spotify-app-3147</link>
      <guid>https://dev.to/ashwinkshenoy/block-ads-on-spotify-app-3147</guid>
      <description>&lt;p&gt;Everyone loves Spotify and sometimes during development, but are tired of its ads that keep coming between songs. Here is a way to block ads through your host file be it Windows or Mac.&lt;/p&gt;

&lt;p&gt;Host Content:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight plaintext"&gt;&lt;code&gt;# — Spotify Ad Block
127.0.0.1 media-match.com
127.0.0.1 adclick.g.doublecklick.net
127.0.0.1 googleads.g.doubleclick.net
127.0.0.1 http://www.googleadservices.com
127.0.0.1 pagead2.googlesyndication.com
127.0.0.1 desktop.spotify.com
127.0.0.1 pubads.g.doubleclick.net
127.0.0.1 audio2.spotify.com

127.0.0.1 crashdump.spotify.com
127.0.0.1 adeventtracker.spotify.com
127.0.0.1 log.spotify.com
127.0.0.1 analytics.spotify.com
127.0.0.1 ads-fa.spotify.com
127.0.0.1 audio-ec.spotify.com
127.0.0.1 heads-ec.spotify.com
127.0.0.1 prod.spotify.map.fastlylb.net
127.0.0.1 sto3.spotify.com
127.0.0.1 spclient.wg.spotify.com
127.0.0.1 upgrade.spotify.com
# — Spotify Ads Block End
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;



&lt;p&gt;Add the above contents in your host file.&lt;/p&gt;

&lt;p&gt;In Windows&lt;/p&gt;

&lt;p&gt;Go to &lt;code&gt;C:\Windows\System32\drivers\etc&lt;/code&gt; . Open the hosts' file as administrator and add the above contents to it. (You could open notepad/Sublime/Atom as administrator and browse to open the hosts' file.)&lt;/p&gt;

&lt;p&gt;Note: Incase the newly added mappings are not working try restarting Windows to take effect&lt;/p&gt;

&lt;p&gt;In Mac&lt;/p&gt;

&lt;p&gt;To find the hosts file, open Finder and, in Finder's menu bar, select Go &amp;gt; Go to Folder. In the box, type the following location and press Return.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;/private/etc/hosts&lt;/code&gt;&lt;br&gt;
To open it, simply double-click and it will display the file's contents in TextEdit (or the text editor of your choice). Add the host content in it and save.&lt;/p&gt;

&lt;p&gt;In most cases, the new mapping should work immediately, but if you're not seeing the correct behavior, you may need to flush your DNS cache. For OS X Lion and OS X Mountain Lion, open Terminal and use the following command. Note that you’ll need to enter your admin password to execute it:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;sudo killall -HUP mDNSResponder&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;For OS X Mavericks +, use this command instead:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;dscacheutil -flushcache; sudo killall -HUP mDNSResponder&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;You could also launch Terminal, type the following command, and press Return. As with all sudo commands, you'll need to also enter your admin password to execute it:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;sudo nano /private/etc/hosts&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;When you're done making changes, press Control-X to exit the editor, Y to save, and Return to overwrite the existing hosts' file. As mentioned earlier, make sure to flush your DNS cache if you notice that your new mappings aren’t working properly.&lt;/p&gt;

&lt;p&gt;Do let me know if it works or needs any change in the host file contents in the comment section below.&lt;/p&gt;

&lt;p&gt;Write. Share what you know/ how to fix/break/fix things :)&lt;/p&gt;

&lt;p&gt;I love the Web. ❤️❤️❤️&lt;/p&gt;

</description>
      <category>blockads</category>
      <category>spotify</category>
    </item>
  </channel>
</rss>
