Thread:Project:Support desk/How to render TOC at a custom place in PHP

I'm editing my skin file to display TOC in the right sidebar rather than on the top of the article. I've tried next code:

mForceTocPosition = true; $text = ''; return $text; ?>

expecting my includes/parser/Parser.php would complete the positionning.

function formatHeadings( $text, $origText, $isMain = true ) { ...

if ( $this->mForceTocPosition ) { return str_replace( '', $toc, $full ); } else { return $full; }

Yet it didn't change anything. Could someone please tell me how I was supposed to do? I'am pretty much a noob at PHP editing and it's quite hard to figure it out on my own. Thank you.