The link you followed has expired – Error-message

A fix for problem installing new theme or plugin

published: 10.06.2018 / comments 6

I recently got an error message saying that “The link you followed has expired”. This happened as I was installing a new theme on my local development environment. While googling the problem I found out that many others had the same problem.

In this article, I explain what causes the problem and how to fix it.

The case of expired link error

I first noticed this error in my local development environment (I’m using MAMP). Never seen it before and it appeared after I installed a new version of MAMP. Everything worked well in environment till I tried to install a theme I bought from Themeforest. The theme installation file is 17MB of size and I have never had problems installing this theme in any other environment. So I had no idea why this was happening.

The error appeared when I tried to upload a theme file to my WordPress site. Going to Appearance – Themes – Add new and then select the theme file for upload always ended with the error. And it happened very fast, like immediately after starting the upload.

Solution to the problem of “the link you followed has expired”

It appeared that the reason for all this was MAMP settings. The new MAMP installation with default settings had too small values for file upload size. Also, the max execution time was quite low as well as post maximum size. I’m not sure if the maximum post size has anything to do with this but I changed it anyway to a bigger value. So – the reason for this error is too small values for certain values. Change them to

  • upload_max_filesize = 64M
  • post_max_size = 64M
  • max_execution_time = 300

These values are set in php.ini configuration file. In this case, MAMP, it is the file located in MAMP/bin/php/<your php version>/conf/php.ini -file.

How do you know which configuration file to edit?

The easiest method is to check your phpinfo. Go to your MAMP and select “Open WebStart page”. At the top of the page, there is a heading PHP and underneath of that is a link to phpinfo. Click the link and you’ll get a page full of information about your PHP environment. Quite high at the top is info about the loaded configuration file. To edit the values, open the file and change the above-mentioned values.

PHP info and the location of active php.ini file

Start the servers again and you’ll be good.

 

Author of this site: Kari Selovuo

I'm a web developer/designer, instructor, and writer who has a mind of a developer and a heart of a designer. I like to share my knowledge and help others learn web development.

Twitter: @KariSelovuo

Leave a Reply

Your email address will not be published. Required fields are marked *

2 comments on “The link you followed has expired – Error-message

  1. Jo says:

    Thank you so much! I’ve spent the last hour wading through spurious advice and this is perfect – worked brilliantly.

  2. Hanieh says:

    Thanks for your help! It was so useful.

0 Shares
Tweet
Share
Share