Warning |
---|
title | Engine Compatibility |
---|
|
replace_html is not supported by the Node engine. |
replace_html(<sel>, <html>)
Replace the page element (usually a <div>) with the id given by <html> with content given by the result of evaluating the expression.
Code Block |
---|
language | javascript |
---|
theme | Confluence |
---|
language | javascript |
---|
|
replace_html("#foo", "<p>This is the text</p>") |
The following ruleset shows replace_html() being used
Code Block |
---|
language | javascript |
---|
theme | Confluence | language | javascript |
---|
|
ruleset a1299x182 {
meta {
name "Replace Html Example"
author "nathan cerny"
logging off
}
dispatch {
// domain "exampley.com"
}
rule first_rule {
select when pageview ".*" setting ()
replace_html('#replace', '<h1>Replacement Text</h1>');
}
} |
...