Old Clock

Migration of the old posts

When making this website I intentionally did not migrate any of the old posts. The reasons are many, including the lack of knowledge in some areas. For example, I did have a CCNA certification and was working on obtaining a CCNP, but life happened and I simply devoted much more of my time toward Web Development and various other personal projects and simply abandoned my CCNA/CCNP ambitions. Currently, it does not seem I will ever return to it, except as a hobby maybe. But even this is doubtful. As a result of these developments, I would not be able to answer the questions about it, so I did not see any point in keeping these posts alive.

Read More
No worries - just copy and paste

Three Web.config tricks - force HTTPS, force yes/no www subdomain

No worries series is designed to do just that - enable you to say "no worries", just copy the code and fire it up. For the first post in the series, we'll do two simple, but very common requirements using some web.config tricks. So, let's get into it.

Force HTTPS


<system.webServer>
<rewrite>
	<rules>
		<clear />
		<rule name="Redirect to https" stopProcessing="true">
			<match url=".*" />
			<conditions>
				<add input="{HTTPS}" pattern="off" ignoreCase="true" />
			</conditions>
			<action type="Redirect" url="https://{HTTP_HOST}{REQUEST_URI}" redirectType="Permanent" appendQueryString="false" />
		</rule>
	</rules>
</rewrite>
</system.webServer>

Sometimes you'll get a requirement to have content available only through www subdomain or without it.

Remove www subdomain


<system.webServer>
<rewrite>
	<rules>
		<clear />
		<rule name="Remove www" stopProcessing="true">
		  <match url="(.*)" ignoreCase="true" />
		  <conditions logicalGrouping="MatchAll">
			<add input="{HTTP_HOST}" pattern="^www\.(.+)$" />
		  </conditions>
		  <action type="Redirect" url="http://{C:1}/{R:0}" appendQueryString="true" redirectType="Permanent" />
		</rule>
	</rules>
</rewrite>
</system.webServer>

Read More
Php FastCGI

Handler PHP_via_FastCGI has a bad module FastCgiModule in its module list

I have seen that a lot of people visit this site when searching for:

Handler "PHP_via_FastCGI1" has a bad module "FastCgiModule" in its module list.

So, here's how to fix it.

Read More
Code with DomagojSalopek.com logo

I am back

That's right. After two and a half years of being inactive, this website will be alive once again. Sorry that old content was not preserved, but these days it belongs only in the archive anyway - it would not be of use to anyone.

The most useful things would be the networking posts, because AFAIK - and that's a big AFAIK because my CCNA has expired and I didn't refresh it - not much has changed in the world of getting certifications, so networking might be useful to some, but at this point I am not willing to invest time to migrate it. The previous version of the site used BlogEngine .NET and this one is using a beta version of own CMS, so there's no possibility to migrate it automatically without some development, which means - either development or I do it manually.

That is not to say that I won't transfer anything ever, but for now, it seems like it's gonna be a brand new start.

For those who are new - and let's face it, after 2.5 years of inactivity everybody's new - my name is Domagoj Salopek and I am a Web Developer. I have been in the Web area professionally for about give or take 10 years, started with Perl, then PHP and these days I'm all about Microsoft..

Read More
Speed is what we need - girl superhero speed

A few quick tips on how to improve site speed

Search engines care about page speed. Users care about page speed. It only makes sense that you try to make your pages load as quickly as possible, without losing anything important.

So, here's a few quick tips on how to do that. Let's get into it:

1. Reduce number of HTTP requests

Browsers have limitations how many parallel requests per server/proxy they do.

Firefox 2:  2
Firefox 3+: 6
Opera 9.26: 4
Opera 12:   6
Safari 3:   4
Safari 5:   6
IE 7:       2
IE 8:       6
IE 10:      8
Chrome:     6

Source: stackoverflow, you can also take a look at Browserscope.

So, what can we do about this? First thing that comes to mind is bundling. Bundling basically means that you combine all the different CSS or JS files into a single file which then browser downloads using only one HTTP request.

Read More

Getting started with Virtualization - Create a Ubuntu Virtual Machine

This will be brief but (excuse me for saying so myself) a cool little blog post about getting started with virtualization. We'll get into an example right away and some minutes from now you'll be testing your website in real IE6 on a virtual machine. Don't care about IE6? Fine, later in the article we'll quickly create our own little machine where you can install any software you might find useful.

We'll install Ubuntu. Why? Because it's free and cool.

Read More
SEO

SEO for Developers

Hey, you! Thanks for visiting. I don't know if you found this website via a search engine or by social media link or whatever, but thank you for stopping by. As a matter of fact, this will be the topic of our little post: how to improve your SEO, from the technical side of things.

This will be the post about what you as developers can do about SEO. We'll stay on the technical side of the equation, and leave the "snake oil salesmanship" to so-called "SEO experts, gurus and rockstars". Therefore we'll only mention the things that are proven to be SEO-friendly, and much more important than that, we'll see how you can implement those things using some popular Web Development technologies.

Read More
Server Room

Setup your own small dedicated server

In this blog post we'll do something different. We'll use an old computer to setup a dedicated web server using Ubuntu Server edition, Apache and MySQL server.

What you'll need

  • A blank CD
  • An old computer with CD drive
  • Some free time (3 hours approximately)
Read More

Create a simple Responsive Design for a blog site using CSS media queries

Responsive Web Design is basically a design done with CSS3 Media Queries that changes according to the environment a visitor uses. In other words, the design "responds" to changes.

It may sound science-fictiony, but that's what happens. And it's not complicated like it sounds. It's actually easy to create a basic Responsive design. All you need to do is play a little with CSS3 Media Queries and setting different widths for container elements.

Read More

NAT Introduction and basic configuration on a Cisco Router

What is NAT?

NAT is short for "Network Address Translation". The basic purpose of NAT is to translate private IP addresses which are used inside the company into public (global) IP addresses.

NAT is primarily used to conserve global IP addresses because it allows that many IP-enabled devices use a few public IP addresses. It's really easy to see NAT at work. For instance, at your work place you and your colleagues are probably represented by a single IP address and NAT allows you all to access the Internet at the same time.

Read More