Spec-Zone.ru › ColdFusion

setVariable

Sets a variable in the name parameter to the value of the value parameter.

setVariable(name, value) → returns void

Discouraged: This function is no longer required in well-formed CFML pages

  • CF
  • Lucee
  • BL 1.0.0+
  • See Also: getVariable

    Argument Reference

    name string
    Required

    Variable name

    value string
    Required

    A string, the name of a string, or a number

    Examples
    Sample code invoking the setVariable function

    Set the value of a from 1 to 2

    a=1;
    setVariable('a',2);
    writeOutput(a);

    Expected Result: 2

    © 2012–present Foundeo, Inc. and the CFDocs contributors.
    Licensed under the MIT License.
    ColdFusion is a trademark of Adobe Systems Incorporated.
    https://cfdocs.org/setvariable

    Spec-Zone.ru

    Настройки Оффлайн Что нового Помощь О нас
    Spec-Zone .ru
    спецификации, руководства, описания, API