Uncategorized

[WordPress] Front page link to second page shows “index.phpIndex.php” when hosting on IIS

Been having a rather curious bug on WordPress installations on IIS such that for the front page, the previous post link to the second page keeps showing “index.phpIndex.php” instead of forming the correct url path.

Finally fixed this by modifying the code at “/wp-includes/link-template.php”

function get_pagenum_link($pagenum = 1) {
...
// insert before return $qstr
$qstr = str_replace("index.phpIndex.php","index.php",$qstr);
return $qstr;
}

Standard

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s