Developer forum

Forum » CMS - Standard features » Item Field - default value - is it possible to set current AreaID or Area title as default value?

Item Field - default value - is it possible to set current AreaID or Area title as default value?

Hans Ravnsfjall
Reply

Hi

 

on a solution containing multiple websites, and where you use the same item type (in my case, an item based page) on  all websites - is it possible to set the title of the website you are working on as default valur, for an item field using something like  <!--@Global:AreaTitle--> (Not a real tag i know, but hopefully you get the idea)

 

The purpos of this is, that if you create an item instance on website a, the automatic value of the field is "website a" - and if you create a similar item instance on website b, the automatic value of this field is "website b"

 

is this possible, and if yes - how do I set it?


Replies

 
Nicolai Høeg Pedersen
Reply

Hm, maybe - try this:

@Code(Dynamicweb.Frontend.Pageview.Current().Area.Item["FieldName"])

 

You must be logged in to post in the forum