Keltex
Keltex

Reputation: 26426

How do I reference the theme folder in blogengine.net?

I have a theme in blog engine.net I want to reference a .aspx file in an IFRAME in my theme master page (inside site.master). Something like this:

<iframe src='/blog/themes/MCO/ContactForm.aspx' frameborder='0' width='250' height='75'></iframe>

Unfortunately this absolute path doesn't work. Is there some sort of helper function to get this reference? Like:

src='<%=BlogSettings.Instance.ThemeFolder+"ContactForm.aspx" %>'

Upvotes: 2

Views: 486

Answers (3)

Gabriele Pala
Gabriele Pala

Reputation: 94

The above marked good answer actually works only on the blog home page. This one should improve:

<img src="<%=Utils.ApplicationRelativeWebRoot %>themes/<%=BlogSettings.Instance.Theme%>/images/logo.png" />

Upvotes: 1

Chris
Chris

Reputation: 1731

Try this one:

<img src="themes/<%=BlogSettings.Instance.Theme%>/images/logo.png" />

Upvotes: 4

Kbdavis07
Kbdavis07

Reputation: 1090

*iframe src='/blog/themes/MCO/ContactForm.aspx'*

Why not try the full path url?

Upvotes: 1

Related Questions