• I have been researching how to incorporate a database into WordPress, through all my research I am unsure of the best way to go about this..

    Here is the situation: I am creating a WordPress site that will function much like the site ratemyprofessor.com functions. I need to have the ability to create pages based on a name and include a form that allows user input to be put into the database under that name and extracted to show statistics etc.

    I believe this is attainable adding tables to the WordPress database, but like I said, I have been unable to find any definitive guidance on achieving this.

Viewing 6 replies - 1 through 6 (of 6 total)
  • You don’t need to add tables to WordPress for this. Worst case is you might need to create a Custom Post Type but I doubt that even that would be necessary. Instead, there are likely to be plugins that will help you get what you need.

    For example, you can use a forms plugin like Gravity Forms or Formidable to design the forms you need and output the data. Automattic’s PollDaddy might also get you a lot of this. There may also be a plugin that has the functionality you’re looking for already built. Here’s one that may or may not do what you need: http://wordpress.org/plugins/gd-star-rating/

    Thread Starter christhomas32

    (@christhomas32)

    If possible, I would like to know the development route, avoiding plugins. Just not sure exactly what the most “WordPress friendly” way of structuring something like that would be.

    I’m not sure why you need to avoid plugins (plugins are definitely “WordPress friendly”), but in any case, you can create your own Custom Post Types as I already mentioned.

    http://codex.wordpress.org/Post_Types#Custom_Post_Types

    Thread Starter christhomas32

    (@christhomas32)

    I am taking a minute to grasp this.. I have hundreds of entries, it would appear that I would have to manually create a post for each of these entries than?

    No. You would define the Custom Post Type once, then you’d load your content into WordPress using that CPT. Defining a CPT is sort of like a creating a template for how you want your specific content to appear – but it’s specifically not a “WordPress template” which is a different thing entirely (just to be clear on terminology). CPTs use the existing WordPress DB structure.

    Thread Starter christhomas32

    (@christhomas32)

    Almost there, how do you “load your content” into the CPT? I have a large excel file, would I just have to import rows one at a time?

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Adding Tables to the WordPress Database’ is closed to new replies.