Here is a string in my code that works when I put in the actual ID # but not when I attempt to use the $categoryID variable. (this works in other places I use it, just not in this string).
echo '<script type="text/javascript">document.location.href = "'.category_url($categoryID).'"</script>'."\n";
Is there something in the syntax that needs to change for me to get that $categoryID working?