Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

General Questions /

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

Strange Question about $variable

Go to End

4 Posts   971 Views


Community Member, 108 Posts

30 March 2009 at 12:56pm

I'm new and I'm just trying to better understand everything so I apologize for the simple question.

When I use a variable in a page such as: $Breadcrumbs

Is the $Breadcrumbs actually referencing the class that has been built?

I'm trying to put a login at the top of the page and I'm working through understanding who to best accomplish this.

I've attached a pic of what it will look like.

Thanks for your thoughts,


Attached Files
Carbon Crayon

Community Member, 598 Posts

30 March 2009 at 1:03pm

Hi Terry

$Breadcrumbs is a function in sapphire/core/model/SiteTree.php which returns the breadcrumbs trail. $Variable is either a function in the model/controller or a field attached to the current page or one of its decendents.

To use the login form simply add $LoginForm to your template. To style it you might want to wrap it in a div with a unique ID so that you can easily target the elements in that specifig login form.


Community Member, 108 Posts

30 March 2009 at 3:15pm

Is there somewhere that reveals all the functions? I saw some documentation early that looked like it might what I'm looking for.

Again, this is very helpful. I'm really enjoying working with SilverStripe.



Community Member, 904 Posts

30 March 2009 at 7:41pm

Hi Terry

Here's a list of the built in controls:

A lot of them aren't explained, but at least they're listed on the bottom of the page.