SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Guru
    Join Date
    Oct 2004
    Location
    uk
    Posts
    853
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    help needed with wordpress

    Hi guys

    This is what I need to do in wordpress

    I have a mysql table of discount codes (each one has a unique id)

    When a users makes a post I want there to be a custom field where they enter this number.

    Then if the custom field matches a unique id in the database then it will display the discount code. I know how to do this in PHP but when it comes to WP its a completely different story.

    How can I do this in wordpress so that it shows the discount in the post itself?

  2. #2
    SitePoint Addict
    Join Date
    Feb 2009
    Location
    Austin Texas
    Posts
    289
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I'm in 2.7. There's a bit near the bottom of the New Post/Edit Post page in the backend that says Add New Custom Field. Once you add it in that area, you can select the field from a dropdown box and assign a value on a per post basis.

    More info on retrieving said values here: http://codex.wordpress.org/Using_Cus..._Custom_Fields


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •