init III
This commit is contained in:
117
Webseiten/andrewisniewski.dev1/admin/admin.pl
Normal file
117
Webseiten/andrewisniewski.dev1/admin/admin.pl
Normal file
@@ -0,0 +1,117 @@
|
||||
#!/bin/perl
|
||||
|
||||
use CGI qw(:standard);
|
||||
|
||||
my $file=param('file');
|
||||
|
||||
print header();
|
||||
|
||||
print <<FIRST_HTML;
|
||||
<!DOCTYPE BHTML PUBLIC "-//BC//DTD BHTML 3.2 Final//EN">
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<title>Example of Xinha</title>
|
||||
<link rel="stylesheet" href="full_example.css" />
|
||||
|
||||
<script type="text/javascript">
|
||||
// You must set _editor_url to the URL (including trailing slash) where
|
||||
// where xinha is installed, it's highly recommended to use an absolute URL
|
||||
// eg: _editor_url = "/path/to/xinha/";
|
||||
// You may try a relative URL if you wish]
|
||||
// eg: _editor_url = "../";
|
||||
// in this example we do a little regular expression to find the absolute path.
|
||||
// _editor_url = document.location.href.replace(/examples\/full_example-body\.html.*/, '')
|
||||
_editor_url = "../xinha/";
|
||||
_editor_lang = "en"; // And the language we need to use in the editor.
|
||||
</script>
|
||||
|
||||
<!-- Load up the actual editor core -->
|
||||
<script type="text/javascript" src="../xinha/htmlarea.js"></script>
|
||||
|
||||
<script type="text/javascript">
|
||||
xinha_editors = null;
|
||||
xinha_init = null;
|
||||
xinha_config = null;
|
||||
xinha_plugins = null;
|
||||
|
||||
// This contains the names of textareas we will make into Xinha editors
|
||||
xinha_init = xinha_init ? xinha_init : function()
|
||||
{
|
||||
xinha_plugins = xinha_plugins ? xinha_plugins :
|
||||
[
|
||||
'CharacterMap',
|
||||
'ContextMenu',
|
||||
'FullScreen',
|
||||
'ListType',
|
||||
'SpellChecker',
|
||||
'Stylist',
|
||||
'SuperClean',
|
||||
'TableOperations',
|
||||
'ImageManager',
|
||||
'Forms',
|
||||
'FormOperations',
|
||||
'Linker',
|
||||
'InsertAnchor',
|
||||
'FindReplace',
|
||||
'InsertWords',
|
||||
'Equation',
|
||||
'InsertMarquee',
|
||||
'QuickTag',
|
||||
'Template',
|
||||
'DoubleClick'
|
||||
];
|
||||
|
||||
// THIS BIT OF JAVASCRIPT LOADS THE PLUGINS, NO TOUCHING :)
|
||||
if(!HTMLArea.loadPlugins(xinha_plugins, xinha_init)) return;
|
||||
xinha_editors = xinha_editors ? xinha_editors :
|
||||
[
|
||||
'ta'
|
||||
];
|
||||
|
||||
xinha_config = xinha_config ? xinha_config() : new HTMLArea.Config();
|
||||
|
||||
xinha_editors = HTMLArea.makeEditors(xinha_editors, xinha_config, xinha_plugins);
|
||||
|
||||
HTMLArea.startEditors(xinha_editors);
|
||||
}
|
||||
|
||||
window.onload = xinha_init;
|
||||
</script>
|
||||
<!--link type="text/css" rel="alternate stylesheet" title="blue-look" href="../xinha/skins/blue-look/skin.css" />
|
||||
<link type="text/css" rel="alternate stylesheet" title="green-look" href="../xinha/skins/green-look/skin.css" />
|
||||
<link type="text/css" rel="alternate stylesheet" title="xp-blue" href="../xinha/skins/xp-blue/skin.css" />
|
||||
<link type="text/css" rel="alternate stylesheet" title="xp-green" href="../xinha/skins/xp-green/skin.css" />
|
||||
<link type="text/css" rel="alternate stylesheet" title="inditreuse" href="../xinha/skins/inditreuse/skin.css" />
|
||||
<link type="text/css" rel="alternate stylesheet" title="blue-metallic" href="../xinha/skins/blue-metallic/skin.css" /-->
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<form action="save.pl" method="post" id="edit" name="edit">
|
||||
<textarea id="ta" name="ta" rows="30" cols="80" style="width:100%">
|
||||
|
||||
FIRST_HTML
|
||||
|
||||
|
||||
open FILE, "<$file";
|
||||
@file=<FILE>;
|
||||
close FILE;
|
||||
|
||||
print @file;
|
||||
|
||||
print " </textarea>\n";
|
||||
print " <input type='hidden' name='file' value='$file'>";
|
||||
|
||||
print <<THIRD_HTML;
|
||||
|
||||
<input type="submit" name="ok" value="Speichern">
|
||||
<input type="button" name="can" value="Abbruch" onclick="window.open('http://dev1.andrewisniewski.de/admin/','_top','')">
|
||||
|
||||
</form>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
||||
THIRD_HTML
|
||||
|
||||
Reference in New Issue
Block a user