The issue I’m coming up against is that a client’s site has a series of nested units, tasks and segments, and they want different conditionals run depending on the various segments. Now, I could use the url_title to find each url segment’s channel, but that seems like I’d potentially have too much overhead. What I’d really like to do is use the channel preferences to prefix each url_title with the channel name, and then in my conditional, query the segment in order to run various templates/changes/etc. Is there any decent way to accomplish this, or is this adding too much overhead, still?
You may also consider using Switchee
If you search for SurgerEE on devotee - you'll be able to use that to query based on regular expression.
https://github.com/dsurgeons/SurgerEE/wiki/String is the function. I've used it lots of times and to really useful.
Sorry for the brevity - on the iPad and mobile at the mo.