I think I&#39;m following you, but maybe I&#39;ve missed your point.<div><br></div><div>Couldn&#39;t you just setup a View to display one node of type class, filtered by your CCK field, sorted by random?  Use &quot;node view&quot; of that one node in the View, and you&#39;ll get one URL that shows whatever random featured node shows up using the node-class.tpl.php template.</div>
<div><br></div><div>Brian</div><div><br></div><div><br></div><div><br></div><div><br><div><br><div class="gmail_quote">On Wed, Jan 27, 2010 at 6:06 AM, Fred Jones <span dir="ltr">&lt;<a href="mailto:fredthejonester@gmail.com">fredthejonester@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">I have a site with a custom content type called Class. We have a file<br>
in the theme called node-class.tpl.php.<br>
<br>
Now the challenge is that we have need a URL like /featured_class<br>
which will search based on a boolean CCK and randomly select any class<br>
node which is marked as &quot;Featured&quot; and then display that.<br>
<br>
I can do this with SQL and then redirect to the class node, but then<br>
the URL changes to that of the node. They want the URL to stay the<br>
same, ie. featured_class.<br>
<br>
I can&#39;t wrap my head around this. I somehow need to get the<br>
node-class.tpl.php in there b/c there&#39;s a lot of code in there for<br>
displaying classes. The only solution I have thus far (that someone<br>
else gave me) is to use template_preprocess_page() to select that node<br>
template, based on the URL, and then use a custom function to find and<br>
load the node in question. I&#39;m not sure it will work, but before I<br>
try, is there any other (better) way to do this?<br>
<br>
Thanks!<br>
<font color="#888888">--<br>
[ Drupal support list | <a href="http://lists.drupal.org/" target="_blank">http://lists.drupal.org/</a> ]<br>
</font></blockquote></div><br><br clear="all"><br>-- <br>Brian Choc<br>Technology Director<br><br>Teaming for Technology Colorado<br>2505 18th St. Denver, CO 80211<br>P: 303.561.2377, F: 303.455.6462<br><a href="http://www.t4tcolorado.org">http://www.t4tcolorado.org</a><br>

</div></div>