<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	
	xmlns:georss="http://www.georss.org/georss"
	xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#"
	>

<channel>
	<title>Marcus etc.</title>
	<atom:link href="http://msyk.es/feed/" rel="self" type="application/rss+xml" />
	<link>https://msyk.es</link>
	<description>mainly just another WordPress site</description>
	<lastBuildDate>Sat, 04 Jun 2016 12:46:55 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=5.7.11</generator>
<site xmlns="com-wordpress:feed-additions:1">36956065</site>	<item>
		<title>Role Based Lists for MailPoet Plugin</title>
		<link>https://msyk.es/blog/new-plugin-role-based-lists-mailpoet/</link>
		
		<dc:creator><![CDATA[marcus]]></dc:creator>
		<pubDate>Sat, 04 Jun 2016 12:46:55 +0000</pubDate>
				<category><![CDATA[Uncategorized]]></category>
		<guid isPermaLink="false">http://msyk.es/?p=3737</guid>

					<description><![CDATA[<p>I&#8217;ve been working with the MailPoet plugin recently as a solution for emailing users of a site. One feature I sorely needed was a way to send emails to specific user roles, and alas this wasn&#8217;t possible. I decided to make a plugin and it did the trick. I&#8217;ve consequently shared it on wordpress.org in the hopes that [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://msyk.es/blog/new-plugin-role-based-lists-mailpoet/">Role Based Lists for MailPoet Plugin</a> appeared first on <a rel="nofollow" href="https://msyk.es">Marcus etc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>I&#8217;ve been working with the <a href="https://wordpress.org/plugins/wysija-newsletters/">MailPoet</a> plugin recently as a solution for emailing users of a site. One feature I sorely needed was a way to send emails to specific user roles, and alas this wasn&#8217;t possible.</p>
<p>I decided to make a plugin and it did the trick. I&#8217;ve consequently <a href="https://wordpress.org/plugins/mp-user-roles-sync/">shared it on wordpress.org</a> in the hopes that it helps someone out. This simply creates a list for each WP User role (custom roles included) and keeps the list synced when moving old and new users in and out of these roles.</p>
<p>The post <a rel="nofollow" href="https://msyk.es/blog/new-plugin-role-based-lists-mailpoet/">Role Based Lists for MailPoet Plugin</a> appeared first on <a rel="nofollow" href="https://msyk.es">Marcus etc.</a>.</p>
]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">3737</post-id>	</item>
		<item>
		<title>Weekend Plugin Resurrection</title>
		<link>https://msyk.es/blog/weekend-plugin-resurrection/</link>
		
		<dc:creator><![CDATA[marcus]]></dc:creator>
		<pubDate>Sun, 22 May 2016 16:18:10 +0000</pubDate>
				<category><![CDATA[Plugins]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[news]]></category>
		<guid isPermaLink="false">http://msyk.es/?p=3724</guid>

					<description><![CDATA[<p>This weekend, I&#8217;ve dedicated to resurrecting a few more plugins which were withering away without updates between 5-7 years! These plugins are Disable User Gravatar, Localhost Notify, Cursor Trail They all needed surprisingly little to get back up and working again. Disable User Gravatar and Cursor Trail actually worked out the box but spat out a few PHP [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://msyk.es/blog/weekend-plugin-resurrection/">Weekend Plugin Resurrection</a> appeared first on <a rel="nofollow" href="https://msyk.es">Marcus etc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>This weekend, I&#8217;ve dedicated to resurrecting a few more plugins which were withering away without updates between 5-7 years!</p>
<p>These plugins are <a href="https://wordpress.org/plugins/disable-user-gravatar/">Disable User Gravatar</a>, <a href="https://wordpress.org/plugins/localhost-notify/">Localhost Notify</a>, <a href="https://wordpress.org/plugins/cursor-trail/">Cursor Trail</a><span id="more-3724"></span></p>
<p>They all needed surprisingly little to get back up and working again. Disable User Gravatar and Cursor Trail actually worked out the box but spat out a few PHP errors.</p>
<p>In all cases some reorganization of code, updating it to use some &#8216;best&#8217; practices will have improved functionality and performance. Mostly, they got a clean up, and maintaining them should certainly be a lot less (if any) time-consuming.</p>
<p>The post <a rel="nofollow" href="https://msyk.es/blog/weekend-plugin-resurrection/">Weekend Plugin Resurrection</a> appeared first on <a rel="nofollow" href="https://msyk.es">Marcus etc.</a>.</p>
]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">3724</post-id>	</item>
		<item>
		<title>Meta Tag Manager 2.0</title>
		<link>https://msyk.es/blog/meta-tag-manager-2-0/</link>
		
		<dc:creator><![CDATA[marcus]]></dc:creator>
		<pubDate>Tue, 17 May 2016 20:35:48 +0000</pubDate>
				<category><![CDATA[Plugins]]></category>
		<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[news]]></category>
		<guid isPermaLink="false">http://msyk.es/?p=3711</guid>

					<description><![CDATA[<p>I&#8217;ve just released a new update for Meta Tag Manager, a complete rewrite and bump up to version 2.0. This was my first ever plugin to be submitted to the WordPress repository over 7 years ago! Back in the day, there weren&#8217;t any (or none I found) plugins that would allow you to add meta tags [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://msyk.es/blog/meta-tag-manager-2-0/">Meta Tag Manager 2.0</a> appeared first on <a rel="nofollow" href="https://msyk.es">Marcus etc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>I&#8217;ve just released a new update for Meta Tag Manager, a complete rewrite and bump up to version 2.0.</p>
<p>This was my first ever plugin to be submitted to the WordPress repository over <strong>7 years ago</strong>! Back in the day, there weren&#8217;t any (or none I found) plugins that would allow you to add meta tags to your site. This was somewhat a pain for me whenever I needed to add google or yahoo verification meta tags to connect to their webmaster tools. Sure, you can edit the theme header, but that presented problems when updating the theme and was also just less convenient overall.</p>
<p>Over the years, other plugins came out that served my purposes, and in other cases I just verified my sites over DNS. As other plugins took up more of my time, this one fell by the wayside, and it has been <strong>four years</strong> since my last update!<br />
<span id="more-3711"></span><br />
<img loading="lazy" class="alignright size-full wp-image-3713" src="http://msyk.es/wp-content/uploads/2016/05/icon-256x256.png" alt="icon-256x256" width="256" height="256" srcset="https://msyk.es/wp-content/uploads/2016/05/icon-256x256.png 256w, https://msyk.es/wp-content/uploads/2016/05/icon-256x256-150x150.png 150w, https://msyk.es/wp-content/uploads/2016/05/icon-256x256-240x240.png 240w, https://msyk.es/wp-content/uploads/2016/05/icon-256x256-96x96.png 96w, https://msyk.es/wp-content/uploads/2016/05/icon-256x256-121x121.png 121w, https://msyk.es/wp-content/uploads/2016/05/icon-256x256-60x60.png 60w, https://msyk.es/wp-content/uploads/2016/05/icon-256x256-184x184.png 184w" sizes="(max-width: 256px) 100vw, 256px" /></p>
<p>However, I still get people asking me every so often whether I can update it. There&#8217;s also a surprisingly large number of active installs, so I felt it only fitting for my first ever (publicly released) WordPress plugin to get a spruce up. Moreover, it&#8217;s a refreshing change of pace to work on a plugin that is less complex than some of my popular ones.</p>
<p>The main aim of this first rewrite was to:</p>
<ul>
<li>Get it up to latest coding standards of WordPress, which includes security best practices and getting rid of outdated PHP methods causing warnings.</li>
<li>Keep it lightweight</li>
<li>Improve the UI for creating meta tags, which restricted the creation of tags with only the name property.</li>
<li>Allow for limiting these tags to show on certain page types (CPTs, Taxonomies for now) along with the option to show on all pages or just the home page as before.</li>
<li>Allow for adding specific meta tags to Custom Post Types</li>
</ul>
<p>Additionally, I&#8217;ve integrated the <a href="http://freemius.com/">Freemius Insights</a> service to make use of their feedback data collection features and allow the users to optionally share some usage stats, which will hopefully make our plugin better.</p>
<p>I&#8217;m curious to see how useful people find the plugin, and certainly intend on at very least maintaining these features, ensuring they work with newer updates.</p>
<p>Other possible plans/ideas for this plugin are:</p>
<ul>
<li>Allow Taxonomy-specific meta tags.</li>
<li>Add placeholders for global meta tags, allowing insertion of dynamic data</li>
<li>Making it easier to set up Open Graph and Twitter meta data.</li>
<li>Multi-lingual support</li>
<li>Make it extendable through hooks/filters to allow other devs to add their own.</li>
</ul>
<p>There&#8217;s already plenty to go on for now, but I&#8217;m open to ideas and may well tackle other features if they&#8217;re in demand. Feel free to let me know!</p>
<p>The post <a rel="nofollow" href="https://msyk.es/blog/meta-tag-manager-2-0/">Meta Tag Manager 2.0</a> appeared first on <a rel="nofollow" href="https://msyk.es">Marcus etc.</a>.</p>
]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">3711</post-id>	</item>
		<item>
		<title>A Year of Revival</title>
		<link>https://msyk.es/blog/season-of-revival/</link>
		
		<dc:creator><![CDATA[marcus]]></dc:creator>
		<pubDate>Mon, 16 May 2016 17:03:13 +0000</pubDate>
				<category><![CDATA[Other]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Wordpress]]></category>
		<guid isPermaLink="false">http://msyk.es/?p=3706</guid>

					<description><![CDATA[<p>I love coding. Plain and simple. I love making things that people find useful and make an impact online, and I fulfill this passion by creating code and sharing it with others. Whilst I&#8217;ve been wearing many hats in my work/career environment over the recent years, my coder/developer hat is and has always been my [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://msyk.es/blog/season-of-revival/">A Year of Revival</a> appeared first on <a rel="nofollow" href="https://msyk.es">Marcus etc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>I love coding. Plain and simple. I love making things that people find useful and make an impact online, and I fulfill this passion by creating code and sharing it with others. Whilst I&#8217;ve been wearing many hats in my work/career environment over the recent years, my coder/developer hat is and has always been my favorite.</p>
<p>Over the past few years due to work, time constraints, life and other priorities, this blog along with various WordPress plugins I had written in the past have been neglected. <a href="http://msyk.es/blog/prevent-jquery-wordpress-theme/">My last post was in 2012</a>&#8230;. yikes! Yet funnily enough, I still refer people to that post as recently as this year, so the thought that I could be writing something that&#8217;s useful to someone is certainly an inspiration to get this going again.</p>
<p>I also have plugins that haven&#8217;t been updated in many years, and still seem to have a following. Therefore, I&#8217;m committing to reviving some of these plugins and showing this blog some love.</p>
<p><span id="more-3706"></span>First step, this site has had a much needed refresh, and I hope on improving my post frequency. In the spirit of not over-promising, we&#8217;ll keep it at that 🙂</p>
<p>More importantly (to me at least), I&#8217;d like to see <a href="http://msyk.es/wordpress-plugins/">some of my plugins</a> that fell by the wayside get updated and keep provide value again. Every so often someone tells me they&#8217;re using one of these older plugins because it solved a problem for them, and it always warms my heart to hear that, along with a surprise that they still work! Also, most of these plugins are minute in comparison to my more popular ones, and are a refreshing change of pace.</p>
<p>With the intent of hitting the ground running, I&#8217;ve done a full rewrite of my first ever plugin, <a href="https://wordpress.org/plugins/meta-tag-manager/">Meta Tag Manager,</a> which I originally wrote sometime in 2008 and committed to the repo in early 2009. That was fun and has given me food for thought on what features I could add to it. I&#8217;m just polishing that off for release and looking forward to the feedback!</p>
<p>I&#8217;ll then be contemplating which plugin to revive next, but meantime I&#8217;m open to suggestions!</p>
<p>The post <a rel="nofollow" href="https://msyk.es/blog/season-of-revival/">A Year of Revival</a> appeared first on <a rel="nofollow" href="https://msyk.es">Marcus etc.</a>.</p>
]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">3706</post-id>	</item>
		<item>
		<title>jQuery CDNs and WordPress theme conflicts</title>
		<link>https://msyk.es/blog/prevent-jquery-wordpress-theme/</link>
					<comments>https://msyk.es/blog/prevent-jquery-wordpress-theme/#comments</comments>
		
		<dc:creator><![CDATA[marcus]]></dc:creator>
		<pubDate>Mon, 06 Aug 2012 13:01:21 +0000</pubDate>
				<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[CDN]]></category>
		<category><![CDATA[conflicts]]></category>
		<category><![CDATA[Google]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[jquery]]></category>
		<guid isPermaLink="false">http://msyk.es/?p=436</guid>

					<description><![CDATA[<p>Since the recent update of version 3.4, many users have started to experience issues with their sites not working correctly, particularly due to JavaScript features such as datepickers, autocompleters, etc. failing to work as before. For plugin developers like myself, it&#8217;s a pain in the @!+ as I&#8217;m now seeing users run into this problem [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://msyk.es/blog/prevent-jquery-wordpress-theme/">jQuery CDNs and WordPress theme conflicts</a> appeared first on <a rel="nofollow" href="https://msyk.es">Marcus etc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>Since the recent update of version 3.4, many users have started to experience issues with their sites not working correctly, particularly due to JavaScript features such as datepickers, autocompleters, etc. failing to work as before.</p>
<p>For plugin developers like myself, it&#8217;s a pain in the @!+ as I&#8217;m now seeing users run into this problem on a daily basis for a few weeks now, and it has become obvious that the problem in every case is the forced loading of jQuery library files from CDNs, particularly Google.</p>
<p>The aim of loading jQuery libraries from external sources is to speed up page loading time, so no wonder why theme makers jump at this quick speed upgrade.</p>
<p>However, whilst there&#8217;s nothing wrong with doing this theoretically, they way they&#8217;re going about it <strong>couldn&#8217;t be more wrong</strong>! The <a href="https://www.google.com/?q=wordpress+jquery+google+cdn" target="_blank">various misleading posts circulating the web</a> are most likely the cause of such a widespread problem, and now we&#8217;re starting to see the consequences as time passes.<span id="more-436"></span></p>
<h2>Why is this wrong?</h2>
<p>As I mentioned above, there&#8217;s nothing wrong with loading files from a CDN, however, there&#8217;s two major things themes do wrong:</p>
<p>The first major issue is that I have yet to see a theme that does this load the latest jQuery version used by WordPress! This presents a load of problems because other plugins that rely on the jQuery library are forced to use outdated libraries which may conflict with some of the code written with later library versions in mind.</p>
<p>The second major mistake is that they&#8217;re taking it upon themselves to do this in the first place. My opinion is that themes have no place in messing with the jQuery libraries and WordPress dependencies. Themes should must take into account that plugins will be installed, and these plugins should have access to the standard libraries provided by WordPress.</p>
<h2>How can I check if I have this problem?</h2>
<p>The major browsers these days all have their own code viewers which makes it easy to check which scripts are loaded. The screenshots below show how this is done in Google Chrome, which is also similar to doing this with FireFox and the Firebug extension.</p>
<p>To bring up the developer window, right click anywhere on the webpage and the click on &#8216;Inspect Element&#8217;. You&#8217;ll see a window appear similar to the one below, click the <em>Sources </em>(in FireBug it&#8217;s <em>Scripts</em>) tab, and look at your scripts there:</p>
<p><a href="http://msyk.es/wp-content/uploads/2012/08/jquery-google-cdn-wrong.png"><img loading="lazy" class="alignnone size-full wp-image-453" title="Spot an outdated version of jQuery" src="http://msyk.es/wp-content/uploads/2012/08/jquery-google-cdn-wrong.png" alt="" width="610" height="297" srcset="https://msyk.es/wp-content/uploads/2012/08/jquery-google-cdn-wrong.png 610w, https://msyk.es/wp-content/uploads/2012/08/jquery-google-cdn-wrong-300x146.png 300w" sizes="(max-width: 610px) 100vw, 610px" /></a></p>
<p>As you can see, the location of the jquery.js file is on the Google server, and clicking on that file shows you the contents which includes the version number (it&#8217;s also usually in the URL). In this case, the theme is loading jQuery 1.4.4.</p>
<h2>Where does my theme do this, and how do I fix it?</h2>
<p>This is the most common question I get these days, which is what inspired this post. Thankfully, the approaches taken by most theme are the same, or similar therefore easy to identify. Unfortunately, not all will be so lucky.</p>
<p>In either case, when trying to find the location of where this is done, you&#8217;ll need to use search functions in your text editors.</p>
<h3>Typical &#8211; functions.php</h3>
<p>This is the usual situation.</p>
<pre class="brush: php; title: ; notranslate">
wp_deregister_script('jquery');
wp_register_script('jquery', 'http://ajax.googleapis.com/ajax/libs/jquery/1.4.4/jquery.min.js', false, '1.4.4');
wp_enqueue_script('jquery');
</pre>
<p>The solution is easy though, just delete it! WordPress will then start loading its own copy of the jQuery library.</p>
<h3>Worse &#8211; header.php</h3>
<p>Less often, but astoundingly too often, some themes go ahead and hard-code the jQuery file with pure html similar to:</p>
<pre class="brush: xml; title: ; notranslate">&lt;script type=&quot;text/javascript&quot; src=&quot;http://ajax.googleapis.com/ajax/libs/jquery/1.4.4/jquery.min.js&quot; /&gt;</pre>
<p>This is worse because it goes against the whole dependency system WordPress uses to load the right scripts during the wp_head() function executed usually within the header.php file.</p>
<p>The fix involves one to three steps (depending on how many mistakes your theme maker made):</p>
<p><strong>Step 1 &#8211;</strong> Remove the line above.</p>
<p><strong>Step 2 (if step 1 fails)</strong> &#8211; Your theme may be doing something even naughtier which is failing to include the wp_head() PHP function in your document head, meaning plugins like Events Manager can&#8217;t include its own javascript files. Try replacing the line you just deleted with this:</p>
<pre class="brush: php; title: ; notranslate">&lt;?php wp_head(); ?&gt;</pre>
<p><strong>Step 3 (if Step 2 fails) &#8211; </strong>If you had to add wp_head(), chances are you&#8217;ll need to add wp_footer() too, which is done within your footer.php file above the body closing HTML tag.</p>
<p><strong>The upside once you fix this </strong>is that your theme will now work with more plugins. However, if you had to do step 2 or 3, you may want to reconsider where you get your themes from (if you made it yourself, lesson learnt i hope!).</p>
<h3>Worst of all &#8211; unknown</h3>
<p>Your theme maker decided to get uber fancy and demonstrate their skills by making this modification somewhere in the myriad of custom included files. Your best bet is to use a search tool and look at all your theme files for words like jquery or google.com. Chances are if the mod isn&#8217;t done in your header.php file, they used the method for the function.php file.</p>
<p>If your theme has found another ingenious way of doing this&#8230; I&#8217;d say your theme is too smart to be used on WordPress, save yourself the headache and move on.</p>
<h2>The &#8216;Right Way&#8217; to host external libraries</h2>
<p>Whilst there&#8217;s more ways than one to do this, the two most sensible ways to do this are:</p>
<ul>
<li>Use a plugin that does this for you, such as <a href="http://wordpress.org/extend/plugins/use-google-libraries/" target="_blank">Use Google Libraries</a> and makes sure the right jQuery version is loaded according to your WP version.</li>
<li>Host all your javascript, css, image and other files on a CDN such as Amazon S3 or CloudFront. It&#8217;s cheap and effective. Caching plugins such as <a href="http://wordpress.org/extend/plugins/wp-super-cache/" target="_blank">Super Cache</a> or <a href="http://wordpress.org/extend/plugins/w3-total-cache/" target="_blank">W3 Total Cache</a> make this very easy to set up and are well documented.</li>
</ul>
<p>Between the two, if you can make use of minify functions (W3TC has this function) to merge all js files into one cached file, then the best choice is the second one if your end goal is increasing your page speeds and/or reducing your server load. However, if you&#8217;re on a budget, or you&#8217;re having issues minifying your scripts with caching plugins then <em>Use Google Libraries</em> will still help a lot and is highly recommended.</p>
<p>As you can see, these have nothing to do with your theme, as it should be!</p>
<p>The post <a rel="nofollow" href="https://msyk.es/blog/prevent-jquery-wordpress-theme/">jQuery CDNs and WordPress theme conflicts</a> appeared first on <a rel="nofollow" href="https://msyk.es">Marcus etc.</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://msyk.es/blog/prevent-jquery-wordpress-theme/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">436</post-id>	</item>
		<item>
		<title>My new home&#8230;..</title>
		<link>https://msyk.es/blog/my-new-home/</link>
		
		<dc:creator><![CDATA[marcus]]></dc:creator>
		<pubDate>Sun, 01 Jul 2012 22:00:28 +0000</pubDate>
				<category><![CDATA[Other]]></category>
		<category><![CDATA[news]]></category>
		<category><![CDATA[themes]]></category>
		<guid isPermaLink="false">http://msyk.es/?p=420</guid>

					<description><![CDATA[<p>Blogging is no easy task! It takes time, dedication and consistency. I started a blog on netweblogic.com, which started falling behind as other priorities took over. It&#8217;s been over a year, and an ageing blog theme did nothing to motivate me. It has gotten to the point that it made sense to split my posts [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://msyk.es/blog/my-new-home/">My new home&#8230;..</a> appeared first on <a rel="nofollow" href="https://msyk.es">Marcus etc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>Blogging is no easy task! It takes time, dedication and consistency. I started a blog on netweblogic.com, which started falling behind as other priorities took over. It&#8217;s been over a year, and an ageing blog theme did nothing to motivate me.<span id="more-420"></span></p>
<p>It has gotten to the point that it made sense to split my posts from any company blogs and move it over to a personal space. I hope to find the time to write more, particularly tidbits, tips and tricks on my day to day work with web technologies, along with the possibility of a rant or two about something or other.</p>
<p>So&#8230; I&#8217;m almost starting from scratch. All my posts on netweblogic.com have been moved over. I may have lost some comments in the process (which is why you shouldn&#8217;t go with plugins like Disqus), but if more content is produced as a result this move, then it will be worth it.</p>
<h2>Under the Hood</h2>
<p>I&#8217;m a fan of simplicity, as well as not re-inventing the wheel (especially when you can improve it!), so I&#8217;ve gone with the lovely Elegant Themes Modest theme with some minimal CSS changes, which does what it says in the box, and will allow more focus to be placed on the content. I may even take it a step further and simplify it even more by removing unnecessary scripts, fonts, etc.</p>
<p>Welcome to my new online home. Don&#8217;t expect regular posts anytime soon, but hey, that&#8217;s the goal and this is the first step 😉</p>
<p>The post <a rel="nofollow" href="https://msyk.es/blog/my-new-home/">My new home&#8230;..</a> appeared first on <a rel="nofollow" href="https://msyk.es">Marcus etc.</a>.</p>
]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">420</post-id>	</item>
		<item>
		<title>Redirect users from WordPress admin pages</title>
		<link>https://msyk.es/blog/redirect-users-wordpress-admin-pages/</link>
		
		<dc:creator><![CDATA[marcus]]></dc:creator>
		<pubDate>Wed, 20 Apr 2011 09:39:59 +0000</pubDate>
				<category><![CDATA[Wordpress]]></category>
		<guid isPermaLink="false">http://netweblogic.com/?p=351</guid>

					<description><![CDATA[<p>After some time looking at the various user-restriction/membership style plugins, I realized that there wasn&#8217;t a quick and easy way to ban normal users from all of the wp-admin pages. Fortunately, wordpress makes this sort of customization easy with its amazing API. These four lines of code are all that&#8217;s needed: You can get this [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://msyk.es/blog/redirect-users-wordpress-admin-pages/">Redirect users from WordPress admin pages</a> appeared first on <a rel="nofollow" href="https://msyk.es">Marcus etc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>After some time looking at the various user-restriction/membership style plugins, I realized that there wasn&#8217;t a quick and easy way to ban normal users from all of the wp-admin pages.</p>
<p>Fortunately, wordpress makes this sort of customization easy with its amazing API. These four lines of code are all that&#8217;s needed:<br />
<span id="more-351"></span></p>
<pre class="brush: php; title: ; notranslate">
function my_wp_admin_ban(){
	if( !current_user_can('activate_plugins') ){
		wp_redirect( get_bloginfo('wpurl') );
		exit;
	}
}
add_action('admin_init','my_wp_admin_ban');
</pre>
<p>You can get this working in two ways:</p>
<ol>
<li>Copy the contents above into a file named wp-admin-ban.php (put them between <?php these tags ?>) and move it to wp-contents/mu-plugins folder. If the <a href="http://wpmututorials.com/basics/what-is-the-mu-plugins-folder/" target="_blank">mu-plugins folder</a> doesn&#8217;t exist, create it. This will be available across any theme on your site.</li>
<li>Copy the code to your theme&#8217;s functions.php file, which restricts functionality to that theme.</li>
</ol>
<p>If you can think of a good membership plugin on the wordpress repo that does the trick, feel free to drop me a line!</p>
<p>On that note, here&#8217;s two plugins you might find useful:</p>
<ul>
<li>My own <a title="ajax login with wordpress" href="http://wordpress.org/extend/plugins/login-with-ajax/" target="_blank">ajax login</a> plugin so users can log in and register with smooth ajax effects from the front of your site!</li>
<li><a href="http://premium.wpmudev.org/project/membership" target="_blank">Membership Plugin</a> If you&#8217;re looking for a good premium membership plugin with great support (personally recommended, tried a few others before it). They also have a lite free version for you to try out.</li>
</ul>
<p>The post <a rel="nofollow" href="https://msyk.es/blog/redirect-users-wordpress-admin-pages/">Redirect users from WordPress admin pages</a> appeared first on <a rel="nofollow" href="https://msyk.es">Marcus etc.</a>.</p>
]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">351</post-id>	</item>
		<item>
		<title>New Plugin &#8211; Cursor Trail</title>
		<link>https://msyk.es/blog/cursor-trail/</link>
		
		<dc:creator><![CDATA[marcus]]></dc:creator>
		<pubDate>Mon, 14 Feb 2011 15:30:22 +0000</pubDate>
				<category><![CDATA[Plugins]]></category>
		<category><![CDATA[valentines]]></category>
		<category><![CDATA[Wordpress]]></category>
		<guid isPermaLink="false">http://netweblogic.com/?p=343</guid>

					<description><![CDATA[<p>This is a pretty simple plugin and probably as useless as they get! This was inspired by David Walsh&#8217;s MooTools implementation. Check out his demo to see functionality, it&#8217;s the same thing except you can control the fade speed and cursor image, as long with start/end dates for special occasions. Activate it for Valentines Day [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://msyk.es/blog/cursor-trail/">New Plugin &#8211; Cursor Trail</a> appeared first on <a rel="nofollow" href="https://msyk.es">Marcus etc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>This is a pretty simple plugin and probably as useless as they get!</p>
<p>This was inspired by David Walsh&#8217;s MooTools implementation. <a href="http://davidwalsh.name/dw-content/mouse-trailer.php" target="_blank">Check out his demo</a> to see functionality, it&#8217;s the same thing except you can control the fade speed and cursor image, as long with start/end dates for special occasions.</p>
<p>Activate it for Valentines Day for a special surprise, if that&#8217;s today you&#8217;ll know what I mean 🙂</p>
<p><a href="https://wordpress.org/plugins/cursor-trail/">Download it here!</a><span id="more-343"></span></p>
<h3>Installation</h3>
<p>Download the zip file, and either:</p>
<ul>
<li>Unzip and upload the cursor-trail folder to your plugins directory, then activate in your plugins page.</li>
<li>Upload via the add new plugin feature in your admin area.</li>
</ul>
<p>The post <a rel="nofollow" href="https://msyk.es/blog/cursor-trail/">New Plugin &#8211; Cursor Trail</a> appeared first on <a rel="nofollow" href="https://msyk.es">Marcus etc.</a>.</p>
]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">343</post-id>	</item>
		<item>
		<title>Single string with multiple translations</title>
		<link>https://msyk.es/blog/single-string-multiple-translations/</link>
					<comments>https://msyk.es/blog/single-string-multiple-translations/#comments</comments>
		
		<dc:creator><![CDATA[marcus]]></dc:creator>
		<pubDate>Wed, 11 Aug 2010 23:34:28 +0000</pubDate>
				<category><![CDATA[Wordpress]]></category>
		<guid isPermaLink="false">http://netweblogic.com/?p=321</guid>

					<description><![CDATA[<p>Multilingual wordpress sites are not as straight-foward to create as you may think (unless you&#8217;re using multi-site). There are various plugins that make this easier, although they all lack something or other (my favourite is qTranslate so far). It gets tricky when you add custom text to sidebars, other plugins, or your themes. It&#8217;s not [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://msyk.es/blog/single-string-multiple-translations/">Single string with multiple translations</a> appeared first on <a rel="nofollow" href="https://msyk.es">Marcus etc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>Multilingual wordpress sites are not as straight-foward to create as you may think (unless you&#8217;re using multi-site). There are various plugins that make this easier, although they all lack something or other (my favourite is <a href="http://wordpress.org/extend/plugins/qtranslate/">qTranslate</a> so far). It gets tricky when you add custom text to sidebars, other plugins, or your themes. It&#8217;s not really the fault of the translation plugins either, because it&#8217;s literally impossible to reliably force plugin outputs to be translated in a user-friendly manner.<span id="more-321"></span></p>
<p>I came across a problem like this where a custom theme I made needed to accommodate the multilingual capabilities of qTranslate for some small snippets of text here and there which could be added in the theme options page (e.g. address, slogans etc.). The amount of work that would be required to make a multilingual options page was not justifiable for the project. So&#8230;. I came up with a pretty simple solution which I&#8217;m sure others can easily use in their plugins and themes:</p>
<p>Basically, if used, you can pass along text wrapped in curly bracket tags, much like html except the tags use curly brackets and the tag names are the language code(e.g. en_US, de_DE, fr_FR). The result is that you could add this to a text box:</p>
<p><code>{en_US}english text{/en_US}{fr_FR}french text{/fr_FR}</code></p>
<p>With the above string the function will choose the correct language based on the current wordpress locale, and if that doesn&#8217;t exist, revert to the first language in the string. This is also compatible with non-translated strings. Whilst not ideal for a whole post, this would definitely come in handy for smaller snippets of text, such as widget titles, theme texts, etc. where fully fledged translation functionality is not needed.</p>
<p>Without further ado, here is the function:</p>
<pre class="brush: php; title: ; notranslate">
/**
 * Separates a string by {lang_code}{/lang_code} 
 * style wrappers and returns the desired locale. If the locale 
 * parameter is empty, function will use default locale (e.g. en_US).
 * If no local is matched, the first language is used. If no brackets 
 * are enclosed, the $string param is returned as is.
 * @param $string
 * @param $locale
 * @return string
 */
function ml_string($string, $locale = ''){
	$locale = ($locale == '') ? get_locale():$locale;
	//Do a regex and extract all text within braces
	$matches = array();
	preg_match_all('/{([a-zA-Z_]{5})}([^{]+){/[a-zA-Z_]{5}}/', $string, $matches);
	if( count($matches[0]) &amp;amp;amp;gt; 0 ){
		//Check if the language we want exists, if not we take the first language there
		foreach($matches[1] as $key =&amp;amp;amp;gt; $lang){
			if ($lang == $locale) {
				return $matches[2][$key];
			}
		}
		return $matches[2][0];
	}
	return $string;
}
</pre>
<p>The post <a rel="nofollow" href="https://msyk.es/blog/single-string-multiple-translations/">Single string with multiple translations</a> appeared first on <a rel="nofollow" href="https://msyk.es">Marcus etc.</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://msyk.es/blog/single-string-multiple-translations/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">321</post-id>	</item>
		<item>
		<title>Adding &#038; Removing Allowed FileTypes To WordPress Media Library</title>
		<link>https://msyk.es/blog/adding-removing-allowed-filetypes-wordpress-media-library/</link>
					<comments>https://msyk.es/blog/adding-removing-allowed-filetypes-wordpress-media-library/#comments</comments>
		
		<dc:creator><![CDATA[marcus]]></dc:creator>
		<pubDate>Fri, 02 Jul 2010 08:00:59 +0000</pubDate>
				<category><![CDATA[Other]]></category>
		<guid isPermaLink="false">http://netweblogic.com/?p=315</guid>

					<description><![CDATA[<p>WordPress has a set of restricted filetypes it will allow you to upload via the media library. Whilst this is a great security feature, there may be times where you&#8217;d like to add other files that are restricted by default, or maybe even the opposite where you&#8217;d only like to allow a few extensions to [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://msyk.es/blog/adding-removing-allowed-filetypes-wordpress-media-library/">Adding &#038; Removing Allowed FileTypes To WordPress Media Library</a> appeared first on <a rel="nofollow" href="https://msyk.es">Marcus etc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>WordPress has a set of restricted filetypes it will allow you to upload via the media library. Whilst this is a great security feature, there may be times where you&#8217;d like to add other files that are restricted by default, or maybe even the opposite where you&#8217;d only like to allow a few extensions to be uploaded. Fortunately, WordPress makes this dead easy with a small snippet of PHP code.<span id="more-315"></span></p>
<p>If you&#8217;d like to add or remove a specific filetype that can be uploaded to wordpress via the media library, you can insert this PHP code in your theme functions.php file:</p>
<pre class="brush: php; title: ; notranslate">
function my_myme_types($mime_types){
	//Adjust the $mime_types, which is an associative array where the key is extension and value is mime type.
	return $mime_types;
}
add_filter('upload_mimes', 'my_myme_types', 1, 1);
</pre>
<p>Here is an example of what you can do to add and remove a new filetype (in this example, I&#8217;m adding an extension that already exists, but the concept is the same):</p>
<pre class="brush: php; title: ; notranslate">
function my_myme_types($mime_types){
	$mime_types['avi'] = 'video/avi'; //Adding avi extension
	unset($mime_types['pdf']); //Removing the pdf extension
	return $mime_types;
}
add_filter('upload_mimes', 'my_myme_types', 1, 1);
</pre>
<p>You can also reset the allowed filetypes by creating a new array within the function and returning these values:</p>
<pre class="brush: php; title: ; notranslate">
function my_myme_types($mime_types){
	//Creating a new array will reset the allowed filetypes
	$mime_types = array(
		'jpg|jpeg|jpe' =&gt; 'image/jpeg',
		'gif' =&gt; 'image/gif',
		'png' =&gt; 'image/png',
		'bmp' =&gt; 'image/bmp',
		'tif|tiff' =&gt; 'image/tiff'
	);
	return $mime_types;
}
add_filter('upload_mimes', 'my_myme_types', 1, 1);
</pre>
<p>If you&#8217;d like to see what filetypes are currently supported by wordpress, check out the function <code>get_allowed_mime_types</code> located in the <code>wp-includes/functions.php</code> file.</p>
<p>The post <a rel="nofollow" href="https://msyk.es/blog/adding-removing-allowed-filetypes-wordpress-media-library/">Adding &#038; Removing Allowed FileTypes To WordPress Media Library</a> appeared first on <a rel="nofollow" href="https://msyk.es">Marcus etc.</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://msyk.es/blog/adding-removing-allowed-filetypes-wordpress-media-library/feed/</wfw:commentRss>
			<slash:comments>3</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">315</post-id>	</item>
	</channel>
</rss>

<!--
Performance optimized by W3 Total Cache. Learn more: https://www.boldgrid.com/w3-total-cache/


Served from: msyk.es @ 2024-02-15 06:03:00 by W3 Total Cache
-->