Well, you already have the two particular category IDs, so list the sub-categories. Like so:
$cat_list_1 = wp_list_categories(array(
'echo' => 1,
'child_of' => FIRST_CAT_ID_HERE,
'title_li' => 'A Name for This',
'depth' => 2, // or whatever you like
));
$cat_list_2 = wp_list_categories(array(
'echo' => 1,
'child_of' => SECOND_CAT_ID_HERE,
'title_li' => 'Another Name for This',
'depth' => 2, // or whatever you like
));
This generates two lists containing links to the categories (which you first have to define in your WP admin, of course).
Then it’s just a matter of CSS/jQuery to style and tweak the lists as you see fit.
If you want/have to work with the HTML of the lists before printing it, use 'echo' => 0
. Then you’re able to do preg_replace
or whatever, and finally echo
the variables.
See wp_list_categories
for full listing of the parameters.