Quantcast
Channel: General developer forum
Viewing all articles
Browse latest Browse all 37883

Creating breadcrumbs in course format

$
0
0
by Lea Cohen.  

I'm using a course format (menutopic) that prints a top navigation bar above the content. The breadcrumbs appear above this bar, as they are created by the theme.

 

However, usability-wise, it makes more sense the the breadcrumbs should appear below the top navbar, and in order to do that, I would have to make the course format create the breadcrumbs.

 

However, when I tried copying the breadcrumbs code from the theme to  the format, I couldn't create the breadcrumbs becuase the $OUTPUT variable doesn't exist in the course format.

                <?php if ($hasnavbar) { ?>
                    <div class="navbar">
                        <div class="wrapper clearfix">
                            <div class="breadcrumb"><?php echo $OUTPUT->navbar(); ?></div>
                            <div class="navbutton"> <?php echo $PAGE->button; ?></div>
                        </div>
                    </div>
                <?php } ?>

 

So how should I go about getting the navbar breadcrumb info in the course format?

I'm using moodle 2.4.


Viewing all articles
Browse latest Browse all 37883

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>