summaryrefslogtreecommitdiff
path: root/swat/esptest
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2005-07-20 07:20:03 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:29:48 -0500
commit86d628a292a22973597e0c06d4a36e20c58ae31c (patch)
tree502f4f8f915be7c4f7104cf6ad38d2239e6dff2d /swat/esptest
parent620301858a5b747002eebe2b9fcef10712ee8249 (diff)
downloadsamba-86d628a292a22973597e0c06d4a36e20c58ae31c.tar.gz
samba-86d628a292a22973597e0c06d4a36e20c58ae31c.tar.bz2
samba-86d628a292a22973597e0c06d4a36e20c58ae31c.zip
r8639: moved loadparm calls into an ejs object
(This used to be commit 2dc493eea6f9d87c40ad0dc755f528ce0b33ca47)
Diffstat (limited to 'swat/esptest')
-rw-r--r--swat/esptest/ldb.esp3
-rw-r--r--swat/esptest/loadparm.esp11
2 files changed, 8 insertions, 6 deletions
diff --git a/swat/esptest/ldb.esp b/swat/esptest/ldb.esp
index b0a2db8dad..20b95b1590 100644
--- a/swat/esptest/ldb.esp
+++ b/swat/esptest/ldb.esp
@@ -5,7 +5,8 @@
<h3>An attribute constrained search</h3>
<%
-var dbfile = lpGet("sam database");
+var lp = loadparm_init();
+var dbfile = lp.get("sam database");
var attrs = new Array("name", "dnsDomain", "objectSid", "dn");
var ldb = ldb_init();
var ok = ldb.connect(dbfile);
diff --git a/swat/esptest/loadparm.esp b/swat/esptest/loadparm.esp
index 9e6de480e2..9ea83b77bc 100644
--- a/swat/esptest/loadparm.esp
+++ b/swat/esptest/loadparm.esp
@@ -3,6 +3,8 @@
<h1>Samba4 loadparm test</h1>
<%
+lp = loadparm_init();
+
var f = FormObj("LoadparmTest", 2, 1);
f.element[0].label = "Share";
f.element[1].label = "Parameter";
@@ -41,9 +43,9 @@ if (request['REQUEST_METHOD'] == "POST") {
share = form['Share'];
name = form['Parameter'];
if (share && name) {
- v = lpGet(share, name);
+ v = lp.get(share, name);
} else if (name) {
- v = lpGet(name);
+ v = lp.get(name);
}
showValue(name, v);
@@ -53,11 +55,10 @@ if (request['REQUEST_METHOD'] == "POST") {
Here are some commonly used parameters:<p>
<%
-
-showValue("defined services", lpServices());
+showValue("defined services", lp.services());
function showParameter(name) {
- showValue(name, lpGet(name));
+ showValue(name, lp.get(name));
}
showParameter("server services");