S
sfxpete
Hi!
Heres something thats been bugging me but I don't seem to be able to
find an elegant way of solving the problem....
I'd like to have a small amount of dynamic text (its actually a string
sucked in from the appsettings section in the web.config) appear in
various locations on a webpage (NOT part of a recordset etc). In this
case its a brandname for the site.
So, I want to just intermingle the brand name in the pages text where
it suits. If I changed brand no probs I just change my config and the
whole site adjusts to suit.
I know of two ways to do it...
A. Use a lot of asp.net label or literal controls and then set each
one individually in the code behind. This just looks ugly and isn;t
the best to maintain.
B. Use an inline expression and call a function that returns the
brandname. A better solution but from what I know (it isn;t much!)
that starts to go back to old classic ASP although by just calling the
function the code is still isolated to the code behind...
I was thinking of a control collection or something that I can iterate
through. I guess my base question is whats the best way to perform
the task at hand!
Sorry about the waffling..... I love waffles....
Cheers
Heres something thats been bugging me but I don't seem to be able to
find an elegant way of solving the problem....
I'd like to have a small amount of dynamic text (its actually a string
sucked in from the appsettings section in the web.config) appear in
various locations on a webpage (NOT part of a recordset etc). In this
case its a brandname for the site.
So, I want to just intermingle the brand name in the pages text where
it suits. If I changed brand no probs I just change my config and the
whole site adjusts to suit.
I know of two ways to do it...
A. Use a lot of asp.net label or literal controls and then set each
one individually in the code behind. This just looks ugly and isn;t
the best to maintain.
B. Use an inline expression and call a function that returns the
brandname. A better solution but from what I know (it isn;t much!)
that starts to go back to old classic ASP although by just calling the
function the code is still isolated to the code behind...
I was thinking of a control collection or something that I can iterate
through. I guess my base question is whats the best way to perform
the task at hand!
Sorry about the waffling..... I love waffles....
Cheers