WordPress.org

Ready to get started?Download WordPress

Forums

Post with two titles (3 posts)

  1. Tombo
    Member
    Posted 7 years ago #

    I've been looking for a related post with no luck.

    I want to be able to enter a "title" and "sub title" when creating a new post. I imagine I would have to duplicate the title text box in the new-post.php page, as well as create a new entry in the back-end database to hold this new information. (I don't know very much about the database(s).)

    One of my options is to put both titles in the title box, separated by some charcter (?) and modify php get_title into get_title_1 and get_title_2.

    Long story short, here's what I'm looking to do. I want to use wordpress to organize a line of clothing. When I create a new post, I want to enter the article of clothing's name, price, avaliable sizes, colors, and brief description. Originally I planned to enter the majority of that as a string in the title field, and then modify get_title to parse the information (ie. create new functions get_price, get_sizes, etc.)

    Is there a "hack" already in existance which could do something like this for me?

    I've been using WordPress for years and have always simply modified the code into whatever I needed (I once made a photoalbum) -- however, I've never modified the database.

    Thanks for your comments!

    Tom

  2. alakhnor
    Member
    Posted 7 years ago #

    The way would be to parse the title as you like in a function and then add a filter to get_title.

  3. Tombo
    Member
    Posted 7 years ago #

    Waaaaaaaaaaaaait a minute... what's this "custom fields" thingy?

Topic Closed

This topic has been closed to new replies.

About this Topic