phpBB2Refugees.com Logo
Not affiliated with or endorsed by the phpBB Group

Register •  Login 

Continue the legacy...

Welcome to all phpBB2 Refugees!Wave Smilie

This site is intended to continue support for the legacy 2.x line of the phpBB2 bulletin board package. If you are a fan of phpBB2, please, by all means register, post, and help us out by offering your suggestions. We are primarily a community and support network. Our secondary goal is to provide a phpBB2 MOD Author and Styles area.

(solved) template based path in php


 
Search this topic... | Search Styles Development & Discussion... | Search Box
Register or Login to Post    Index » Styles Development & Discussion  Previous TopicPrint TopicNext Topic
Author Message
hoimyr
Board Member



Joined: 16 Apr 2009

Posts: 115
Location: Oslo


flag
PostPosted: Mon Jun 22, 2009 8:39 pm 
Post subject: (solved) template based path in php

I have 2 templates installed. My challenge is that one image is linked in viewforum.php and not in the tpl. I want the image to change when the template changes.

now the code looks like this:
$image = '<IMG SRC="subsilver/images/mypic.jpg">';

is it possible to do something like this?
$image = '<IMG SRC="%template%/images/mypic.jpg">';



icon_question.gif


solution:
added
$images['myimage'] = "$current_template_images/myimage.gif"; in the templates cfg file.
Then i linked the pictures this way: IMG SRC="' . $images['myimage'] . '"

icon_smile.gif
Back to top
Display posts from previous:   
Register or Login to Post    Index » Styles Development & Discussion  Previous TopicPrint TopicNext Topic
Page 1 of 1 All times are GMT
 
Jump to:  

Index • About • FAQ • Rules • Privacy • Search •  Register •  Login 
Not affiliated with or endorsed by the phpBB Group
Powered by phpBB2 © phpBB Group
Generated in 0.0120 seconds using 15 queries. (SQL 0.0017 Parse 0.0005 Other 0.0099)
phpBB Customizations by the phpBBDoctor.com
Template Design by DeLFlo and MomentsOfLight.com Moments of Light Logo