Unfortunately it doesn’t work if you have 2 categories having the same name (for example: two subcategories named “Best of” in two diffrent categories, “Article” and “Essay”)
In such a case, get_cat_id would send you a wrong id for one of the two categories …
If you have any other idea, I’d be glad to read it ??