skye_Blue Posted January 13, 2014 Share Posted January 13, 2014 In module.tpl I'd like to be able to change the css for a div, based on the its hook position. e.g. if the module is hooked at the top then a list is to be displayed horizontally, if it's hooked to the left column then it is displayed vertically. Please can anyone tell me how to find the calling hook's name or id so that I can replace HOOK in the module.tpl code below <div {if HOOK=="Top"} class="moduletop" {else} class="moduleleft" {/if}> Thanks Link to comment Share on other sites More sharing options...
vekia Posted January 13, 2014 Share Posted January 13, 2014 you can achieve this with css styles only, without modification of the .tpl files. if your module is attached to left column you can use #left_column .module {background:red;} #right_column .module {background:red;} etc. just use one class ="module" or any other name you want. then you will be able to stylize it depending on parent id. Link to comment Share on other sites More sharing options...
skye_Blue Posted January 13, 2014 Author Share Posted January 13, 2014 Thanks, Vekia. Issue now solved. Link to comment Share on other sites More sharing options...
vekia Posted January 14, 2014 Share Posted January 14, 2014 thank you for confirmation i marked this topic as [solved] too with regards, Milos Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now