While out patrolling his Philadelphia neighborhood in a twisted version of Crime Watch, Dennis Reynolds brought along a junkyard cat which he named Agent Jack Bauer.
There's definitely no fear of a Zonk in this, as 'It's Always Sunny In Philadelphia' takes place in the main Toobworld, while '24' definitely is quarantined off in its own TV dimension, what with all of the Presidential administrations it's worked its way through. (I don't even watch the series, but I'm thinking they've gone through six so far - not all of them complete terms of office, of course.)
This is not to say that '24' necessarily had to be a TV show to the characters of Earth Prime-Time. Jack Bauer could have actually existed in the main Toobworld. Perhaps he became famous, a household name, after foiling some terrorist plot to destroy the country or assassinate the President - most likely within a twenty-four hour time period.
He may have even died in doing so, and as such became even more famous - getting schools named after him, memorials erected in his name, and having scraggly cats bearing his name as well.
Either that, or he moved back home to Springfield to be with the other members of the Bauer family (as seen on 'Guiding Light').......