Thanks for all the information. I&#39;ll include the proper usage in my theme notes.<br clear="all"><br>Curtis McHale<br>PH: 604.751.3482<br><a href="http://www.curtismchale.ca">http://www.curtismchale.ca</a><br>Linkedin: <a href="http://www.linkedin.com/in/curtismchale">http://www.linkedin.com/in/curtismchale</a><br>

Twitter: <a href="http://twitter.com/curtismchale">twitter.com/curtismchale</a><br><br>
<br><br><div class="gmail_quote">On Fri, Apr 22, 2011 at 10:15 AM, Chip Bennett <span dir="ltr">&lt;<a href="mailto:chip@chipbennett.net">chip@chipbennett.net</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

So, I found <a href="http://themes.svn.wordpress.org/wiredrive-classic/1.0.1/css/custom-css.php" target="_blank">the code you&#39;re talking about</a>.<div><br></div><div>The correct way to do this:</div><div><br></div><div>

1) Wrap that output in a function, e.g.:</div>
<div><br></div><blockquote style="margin:0 0 0 40px;border:none;padding:0px"><div>function wiredrive-classic_custom_css() {</div><div>     include( get_template_directory() . &#39;/css/custom-css.php&#39; );</div>
<div>}</div></blockquote><div><br></div><div>2) Enqueue the function (increase priority as needed):</div><div><br></div><blockquote style="margin:0 0 0 40px;border:none;padding:0px">
<div>add_action( &#39;wp_print_styles&#39;, &#39;wiredrive-classic_custom_css&#39;, 11 );</div></blockquote><div><br></div><div>And that&#39;s it.</div><div><br></div><div>Chip</div><div><br><div class="gmail_quote"><div class="im">

On Fri, Apr 22, 2011 at 11:34 AM, Curtis McHale <span dir="ltr">&lt;<a href="mailto:curtis@curtismchale.ca" target="_blank">curtis@curtismchale.ca</a>&gt;</span> wrote:<br>
</div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div></div><div class="h5">I&#39;m reviewing a theme and I&#39;ve found uses of get_template_part where I believe that locate_template is the proper item. Specifically the code below loads the custom stylesheet.<div>


<br></div><div><div>&lt;?php get_template_part(&#39;css/custom-css&#39;)?&gt;</div>

<div><br></div><div>It was my understanding that in this case we should use:</div><div><br></div><div>&lt;?php locate_template( array( &#39;/css/custom-css.css&#39; ), 1); ?&gt;</div><div><br></div><div>and that get_template part was to call a file in the same directory like loop-main.php. Is there established best practice and if so what is it? Is the use above an okay way to call a custom stylesheet in to the theme? If not what way is currently advised?</div>




<br>Curtis McHale<br>PH: 604.751.3482<br><a href="http://www.curtismchale.ca" target="_blank">http://www.curtismchale.ca</a><br>Linkedin: <a href="http://www.linkedin.com/in/curtismchale" target="_blank">http://www.linkedin.com/in/curtismchale</a><br>


Twitter: <a href="http://twitter.com/curtismchale" target="_blank">twitter.com/curtismchale</a><br>

<br>
</div>
<br></div></div><div class="im">_______________________________________________<br>
theme-reviewers mailing list<br>
<a href="mailto:theme-reviewers@lists.wordpress.org" target="_blank">theme-reviewers@lists.wordpress.org</a><br>
<a href="http://lists.wordpress.org/mailman/listinfo/theme-reviewers" target="_blank">http://lists.wordpress.org/mailman/listinfo/theme-reviewers</a><br>
<br></div></blockquote></div><br></div>
<br>_______________________________________________<br>
theme-reviewers mailing list<br>
<a href="mailto:theme-reviewers@lists.wordpress.org">theme-reviewers@lists.wordpress.org</a><br>
<a href="http://lists.wordpress.org/mailman/listinfo/theme-reviewers" target="_blank">http://lists.wordpress.org/mailman/listinfo/theme-reviewers</a><br>
<br></blockquote></div><br>