• Resolved tpenny3

    (@tpenny3)


    The linked page is an example of a bigger problem:

    I have a CPT ‘Elections’, with one template and one listing that applies to all elections posts. (I am using JetEngine and Elementor).

    Elections posts include Governments (e.g. United States), Offices (e.g. House of Representatives), Districts, Primaries, and General Elections. Some of these overlap (e.g. House of Representatives District 10 is a General Election page).

    As a newbie to web development, I’m struggling to figure out how to build this out logically so that I can easily improve the user experience.

    I have set up taxonomies to organize posts by: election type (primary, general election, NOT an election (e.g. a government or office with districts)), government level (governments, offices, districts), and years (2023, 2024, etc. (which affect if the post display results or upcoming election information).

    Unfortunately there is so much conditional logic combined with a so-so (yet improving) naming structure, that changing anything in the listings, is difficult to think through, implement, and test.

    I just set up a staging/dev environment. (Thank goodness). I plan to get a whiteboard to visualize the database and site structure. But I’m still in this strange place where I have little experience and limited resources to have an experienced dev manage the structure.

    I have tried building out separate post types (e.g. Governments) and I may return to that, however, the last time I did this I bit off more than I could chew and ultimately returned to the current structure.

    Any thoughts/suggestions for improving the site’s structure (or perhaps finding local development resources for a bit of ongoing advice) would be greatly appreciated.

    Thank you!

    The page I need help with: [log in to see the link]

Viewing 2 replies - 1 through 2 (of 2 total)
  • Moderator bcworkz

    (@bcworkz)

    While WP posts can be used to organize all sorts of data, when the data schema is very complex, WP posts can often fall short of ideal. This may be the case here.

    Where is all this data coming from? I’d think you’re better off utilizing it in its current form rather than trying to rearrange it to fit within the WP post schema. This does mean you’d need to compose your own SQL queries, but I think it’d be preferable over reorganizing all the data. It may be bad enough importing the data into a mySQL DB without also needing to organize into a WP schema.

    Getting the data into a well organized schema is the principal challenge, but the other big consideration is how should the data be presented to end users? The best data schema is not useful if it cannot be presented in a meaningful manner to end users.

    Thread Starter tpenny3

    (@tpenny3)

    Thank you. I will have to think about this.

    The data is coming from a variety of sources. Unfortunately I don’t think I have the bandwidth for the learning curve required to re-build the current system.

    Perhaps with more resources this is the way to go. For now I may try re-adding another CPT and improving the template/css management.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Simplifying cpt/taxonomy/database logic for easier management’ is closed to new replies.