WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] slug function (eregi/preg_replace/something )? (3 posts)

  1. sourlime
    Member
    Posted 8 years ago #

    I've been using feedwordpress to make a page of aggregated posts, but I've been thinking of moving to reblog, because I'd be better able to combine my own feeds with the ones I want to aggregate for the public.

    However, the reblog plugin leaves a fair bit to be desired. One of my biggest problems is that it doesn't do the slug at all, it just uses the title, which leaves broken links. I've already set it up so that it does certain replacements (space, comma, colon) and makes it all to lowercase, but I know it doesn't cover all the cases that the wordpress code does. Except... I can't figure out where this function is, for me to either copy it or just reference it instead.

    I'd appreciate any help, thank you.

  2. Kafkaesqui

    Posted 8 years ago #

    What you're looking for is sanitize_title(). It's the WP function that turns titles into 'slugs.'

  3. sourlime
    Member
    Posted 8 years ago #

    Fantastic, thank you! I knew there had to be an easier way, but I had could not figure out where to find it.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags