Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migration of unmigrated content due to installation of a new plugin
{div:class=} h1.
Wiki Markup
Div
classapi-page

fluid.allocateSimpleId(element)

{section} {column:width=70%} Allocate an id to the supplied element if it has none already, by a simple scheme resulting in ids

Section
Column
width70%

Allocate an id to the supplied element if it has none already, by a simple scheme resulting in ids "fluid-id-nnnn"

where

nnnn

is

an

increasing

integer.

{

Code Block
:javascript|borderStyle=none|bgColor=white}
javascript
bgColorwhite
borderStylenone
javascript

fluid.allocateSimpleId(element);
{code} *

File

name:

* {{

Fluid.js

}} h2. Parameters {span:class=

Parameters

Span
classborderless-table

} |*{{element}}*|

element

(Element)

The

element

to

place

the

id

on.

| {span} h2. Return Value {span:class=borderless-table} |*String*| representing the id | {span} {column} {column:width=5%} {column} {column} h3. See Also * [fluid.allocateGuid] {column} {section} ---- h3. Example {code:javascript}

Return Value

Span
classborderless-table

String

representing the id

Column
width5%

Column

See Also


Example

Code Block
javascript
javascript

var titleId = fluid.allocateSimpleId(title);
{code}

In

this

example,

the

string

returned,

{{

titleId

}}

will

be

added

as

the

{{

id

}}

attribute

to

the

{{

title

}}

node.

{div}