commit
353d9c523f
@ -1,73 +0,0 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<title>YaCy '#[clientname]#': Augmented Browsing - Filters and Modules</title>
|
||||
#%env/templates/metas.template%#
|
||||
</head>
|
||||
<body id="Settings">
|
||||
#%env/templates/header.template%#
|
||||
#%env/templates/submenuSemantic.template%#
|
||||
<h2>Augmented Browsing - Filters and Modules</h2>
|
||||
|
||||
<form id="augmentationFilters" action="AugmentedBrowsingFilters_p.html" method="post" enctype="multipart/form-data">
|
||||
<fieldset><legend id="urlproxy">Augmented Browsing Filters</legend>
|
||||
<p>
|
||||
Select the desired functionality.
|
||||
</p>
|
||||
|
||||
<dl>
|
||||
|
||||
<dt><label for="content">External REFLECT:</label></dt>
|
||||
<dd>
|
||||
<input type="checkbox" name="augmentedReflect" id="augmentedReflect" #(augmentedReflect_checked)#:: checked="checked"#(/augmentedReflect_checked)# />Enabled<br/>
|
||||
<p class="help">
|
||||
Send webpages to REFLECT (<a href="http://reflect.ws/" target="_blank">http://reflect.ws/</a>)
|
||||
</p>
|
||||
</dd>
|
||||
|
||||
|
||||
|
||||
</dl>
|
||||
|
||||
<p>
|
||||
Select the desired inbuilt functionality
|
||||
</p>
|
||||
|
||||
<dl>
|
||||
|
||||
<dt><label for="content">Add DOCTYPE:</label></dt>
|
||||
<dd>
|
||||
<input type="checkbox" name="augmentedAddDoctype" id="augmentedAddDoctype" #(augmentedAddDoctype_checked)#:: checked="checked"#(/augmentedAddDoctype_checked)# />Enabled<br/>
|
||||
<p class="help">
|
||||
Add DOCTYPE information if not given. This is required for IE to render position:absolute correctly.
|
||||
</p>
|
||||
</dd>
|
||||
|
||||
<dt><label for="content">Reparse webpage:</label></dt>
|
||||
<dd>
|
||||
<input type="checkbox" name="augmentedReparse" id="augmentedReparse" #(augmentedReparse_checked)#:: checked="checked"#(/augmentedReparse_checked)# />Enabled<br/>
|
||||
<p class="help">
|
||||
Put webpage back into schema (htmlparser document) to allow node by node manipulation.
|
||||
</p>
|
||||
</dd>
|
||||
|
||||
<dt><label for="content">Show overlay interaction buttons:</label></dt>
|
||||
<dd>
|
||||
<input type="checkbox" name="overlayInteraction" id="overlayInteraction" #(overlayInteraction_checked)#:: checked="checked"#(/overlayInteraction_checked)# />Enabled<br/>
|
||||
<p class="help">
|
||||
Show overlay interaction buttons.
|
||||
</p>
|
||||
</dd>
|
||||
|
||||
</dl>
|
||||
|
||||
|
||||
<input type="submit" name="augmentationFiltersSettings" value="Submit"/>
|
||||
</fieldset>
|
||||
</form>
|
||||
|
||||
|
||||
|
||||
#%env/templates/footer.template%#
|
||||
</body>
|
||||
</html>
|
@ -1,50 +0,0 @@
|
||||
import net.yacy.cora.protocol.RequestHeader;
|
||||
import net.yacy.server.serverObjects;
|
||||
import net.yacy.server.serverSwitch;
|
||||
|
||||
public final class AugmentedBrowsingFilters_p {
|
||||
|
||||
public static serverObjects respond(@SuppressWarnings("unused") final RequestHeader header,
|
||||
final serverObjects post, final serverSwitch env) {
|
||||
// return variable that accumulates replacements
|
||||
final serverObjects prop = new serverObjects();
|
||||
|
||||
if (post != null) {
|
||||
|
||||
|
||||
if (post.containsKey("augmentationFiltersSettings")) {
|
||||
|
||||
env.setConfig("augmentation.reflect", "on".equals(post
|
||||
.get("augmentedReflect")) ? true : false);
|
||||
|
||||
env.setConfig("augmentation.addDoctype", "on".equals(post
|
||||
.get("augmentedAddDoctype")) ? true : false);
|
||||
|
||||
env.setConfig("augmentation.reparse", "on".equals(post
|
||||
.get("augmentedReparse")) ? true : false);
|
||||
|
||||
env.setConfig("interaction.overlayinteraction.enabled", "on".equals(post
|
||||
.get("overlayInteraction")) ? true : false);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
prop.put("augmentedReflect_checked",
|
||||
env.getConfigBool("augmentation.reflect", false) ? "1" : "0");
|
||||
|
||||
prop.put("augmentedAddDoctype_checked",
|
||||
env.getConfigBool("augmentation.addDoctype", true) ? "1" : "0");
|
||||
|
||||
prop.put("augmentedReparse_checked",
|
||||
env.getConfigBool("augmentation.reparse", true) ? "1" : "0");
|
||||
|
||||
prop.put("overlayInteraction_checked",
|
||||
env.getConfigBool("interaction.overlayinteraction.enabled", true) ? "1" : "0");
|
||||
|
||||
|
||||
// return rewrite properties
|
||||
return prop;
|
||||
}
|
||||
|
||||
}
|
Loading…
Reference in new issue