I can not find where to change path for wp_get_archives()
…Now i have path http://example.com/2015
but i want to add history before 2015 so that i have url:
http//example.com/history/2015
. Any suggestion?
<?php wp_get_archives('type=yearly'); ?>
add_filter( 'get_archives_link', function( $html )
{
if( is_admin() ) // Just in case, don't run on admin side
return $html;
// $html is '<li><a href='http://example.com/hello-world'>Hello world!</a></li>'
$html = str_replace( 'href="http://example.com', 'href="http://example.org', $html );
return $html;
});
I found this but when nothing happend when i added