![]() |
a variable inHTML?
Can I have a variable in plain HTML?
pseudo such as: <variable color="White"> <form...> <input type=text value=color> </form> and have the word White as the value that appears in the textfield on the browser's page. If that can't be done purely in HTML, how best to work around? Thanks. My intended purpose is to declare variables at the top of the code, where easily visible and available to change, and have the effects work later on throughout the working code. |
Re: a variable inHTML?
Bob wrote:
> Can I have a variable in plain HTML? No. > If that can't be done purely in HTML, how best to work around? Server-side scripting. (e.g. PHP.) -- Toby A Inkster BSc (Hons) ARCS Contact Me ~ http://tobyinkster.co.uk/contact Geek of ~ HTML/SQL/Perl/PHP/Python*/Apache/Linux * = I'm getting there! |
Re: a variable inHTML?
On 14 Feb, 16:52, Bob <jhg...@albo.net> wrote:
> Can I have a variable in plain HTML? No. > pseudo Sort of (macro expansion through server-side scripting), but it's a rare occasion when that's of real practical use. > <variable color="White"> What's your _real_ purpose for doing this? If it's to have some sort of indirection between context and presentation, then CSS and the HTML class attribute already does pretty much all you could want. Otherwise tell us what you need to achieve (rather than how you've already decided it ought to be implemented) and maybe we can give a better idea. |
| All times are GMT. The time now is 04:16 AM. |
Powered by vBulletin®. Copyright ©2000 - 2013, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.