BYU-ODH / wp-humanities-byu

Humanities theme following BYU Official style
2 stars 0 forks source link

Make a function that does post_id -> project_status #504

Closed WorldsEndless closed 2 years ago

WorldsEndless commented 2 years ago

It will check for status given a postid and return "active", "archived", or "intake"

WorldsEndless commented 2 years ago

The contract on this function should be like, function get-project-status ($post_id){} returns a string that can be used for the classname "live" on one of the others

WorldsEndless commented 2 years ago

Example of a function with a similar contract that can simulate the loop to allow you to access the project data to determine the status https://github.com/BYU-ODH/wp-humanities-byu/blob/c8c3b9e17c3e409cfb29478082eb365db550334e/functions.php#L354