[wp-hackers] Internal links

Patrik Bóna patrik.bona at mrhead.sk
Thu Dec 3 14:36:11 UTC 2009


I think, that you have probably missed the point :)

I think that Vlad wants links in form:
/2009/10/10/article instead of http://example.com/2009/10/10/article

Vlad i don't know if it is possible to set it somewhere, but this simple 
code should works:

function change_permalinks($link) {
        return str_replace(get_bloginfo('url'), '', $link);
}
add_filter('post_link','change_permalinks');
add_filter('page_link','change_permalinks');

Best regards

Patrik

Anthony Cole wrote:
> Enable Permalinks in Settings -> Permalinks :)
>
> -ac
>
> On 4/12/2009, at 2:49 AM, Vlad GURDIGA wrote:
>
>   
>> Hello,
>>
>> Is there any reason why one cannot create an internal link? Like:
>> ./2009/12/03/article-title.
>> _______________________________________________
>> wp-hackers mailing list
>> wp-hackers at lists.automattic.com
>> http://lists.automattic.com/mailman/listinfo/wp-hackers
>>     
>
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
>
>   



More information about the wp-hackers mailing list