-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathschmidtinatorfunktioniertregex4.php
211 lines (193 loc) · 8.33 KB
/
schmidtinatorfunktioniertregex4.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
<html><head> <link rel='stylesheet' href='style.css' > <link rel='stylesheet' href='../style.php' >
<meta charset="UTF-8">
<meta name="description" content="Arno Schmidt Etym Generator">
<meta name="keywords" content="HTML, CSS,PHP,Arno Schmidt Etym Generator, schmidtisator, arnoschmidtisator, arnoschmidtinator,arnoschmidtator, verlispeln, verlispelung, etym, etyms, zettels traum, erotik">
<meta name="author" content="Klaus Vulvv">
<meta name="title" content="Arschmidtisator">
<title>Arschmidtisator</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<!--style>/* class frac wichtig fuer Schmidtinator oder Brueche */
/*span.frac {
display: inline-block;
text-align: center;
}
span.frac > sup {
display: block;
border-bottom: 1px solid;
font: inherit;
}
span.frac > span {
display: none;
}
span.frac > sub {
display: block;
font: inherit;
}
/* Class uml fuer uebereinandergestellte Umlaute oe etc. Bruch ohne Bruchstrich.*/
span.uml {
display: inline-block;
text-align: center;
vertical-align:-5px;
}
span.uml > sup {
display: block;
font: inherit;
position: relative; top: 10px;
}
span.uml > span {
display: none;
}
span.uml > sub {
display: block;
font: inherit;
vertical-align:5px;
}
/* Zettels Traum css style, unwichtig.*/
#box {
width:65%;
line-height: 1.5;
outline: #fff5ee solid 10px;
border: #000 solid 2px;
margin: 0px auto;
//margin-top: 10em; auto;
padding: 15px;
text-align: center;
background-color: #fff5ee;
float: left;
// border: 1px solid blue;
// border-width:5px;
// border-spacing: -15px;
// border-margin:15px;
}
#box.right {
position:static;
width:25%;
line-height: 1.5;
margin: 0px auto;
//margin-top: 10em; auto;
padding: 15px;
float: right;
overflow: true;
background-color: #fff5ee;
border:none;
outline: none;
line-height: 0.7;
text-align: justify;
}
#box.footer{
}
body {
margin: 20px;
text-align: center; /* nur fuer alte Browser */
background-color: #29220a;//#e6e6fa;
font-family: monospaced;
}
hr.new1 {
border-top: 3px solid darkgrey;
width:20%;
}
.brl
{
padding: 8px;
border-right: 5px solid #f00;
border-left: 5px solid #f00;
}
*/</style -->
</head>
<body>
<!-- Link your php/css file -->
<!--link rel="stylesheet" href="style.php" media="screen"-->
<!--span class="frac"-->
<div id="box">
<hr class="new1">
<h4> <span style='vertical-align:-15px;'><span class='frac'><sup>Ar</sup><span> / </span><sub>№</sub></span></span> Schmid <span style='vertical-align:-15px;'><span class='frac'><sup>ator</sup><span> / </span><sub> Tina</sub></span></span> <span style='vertical-align:-15px;'><span class='frac'><sup>00</sup><span> / </span><sub>2.</sub></span></span></h4>
<hr class="new1">
<form method="get" action="<?php echo htmlspecialchars($_SERVER["PHP_SELF"]);?>">
<!-- onclick="this.value=''" // ggf einfuegen unten -->
<Textarea onfocus="this.value=null;" type="text" name="str" rows="6" cols="35" style="background-color:#29220a; color:#fff5ee;"
placeholder="Ich fl / l ausche P ul / ol lis / ice
The T w / o ilit of the G od / ut s.!!!!!!
A / B
aaa / bbb
ccc / ddd">Ich fl / l ausche P ul / ol lis / ice.
The T w / o ilit of the G od / ut s !!! / ???
A / B
aaa / bbb
ccc / ddd</textarea><br>
<label>Ausrichten !!! </label><input type ="number" step="1" name ="ausr" value="-14" style="background-color:#fff5ee;" widht="4">
<br>
<input type="radio" name="brch" value="frac" checked="true"><label> Stahlberg</label>
<input type="radio" name="brch" value="uml"><label> Haffmans</label>
<!--input type="radio" name="gender" value="other">Other-->
<br>
<input type="submit" src="button.png" value="Sp ü / ie len ! -- > -.- ),">
</form>
<script>
function myFunction() {
console.log("hello");
}
</script>
<?php
# require_once("./style.php");
global $str, $pattern, $sing;
$str = "Ich fl / l ausche P ul / ol lis / ice <br>
The T wi / oi lit of the G od / ut s !!! / ???<br>
A / B <br>
aaa / bbb <br>
ccc / ddd";
$pattern = "#([a-zA-ZüöäÜÖÄß]{1,3}) / ([a-zA-ZüöäÜÖÄß]{1,3})#i";
$str = $_GET["str"];
$brch=$_GET["brch"];
$ausr=$_GET["ausr"];
# $ausr = $ausr;
if ($brch == "frac"){
$sing ="<span style='vertical-align:$ausr\px'><span class='frac'><sup>$1</sup><span> / </span><sub>$2</sub></span></span>";
Echo "<br>";}
if ($brch == "uml") {
$ausr = $ausr +10;
$sing ="<span style='vertical-align: $ausr\px;'><span class='$brch'><sup>$1</sup><span> / </span><sub>$2</sub></span></span>";
Echo "<br>";}
echo nl2br(preg_replace($pattern, $sing, $str));
Echo "<br>";
Echo "<hr class='new1'>";
Echo "Ihre Eingabe zum Korrigieren und Kopieren: <br><br>".nl2br($str);
echo "<br>";
/*echo $pattern;
echo "<div class='frac'>".$sing."</div>";*/
htmlspecialchars($_SERVER["PHP_SELF"]);
?><hr class='new1'><!--/span-->
</div>
<div id='box' style="margin-top:40px;border:none;outline:none;"">
<?php echo "In html für Sie: <textarea style='background-color:#fff5ee;'>".nl2br(preg_replace($pattern, $sing, $str))."</textarea> mit <a href='style.css'>style.css</a>";
Echo "<br>";?>
<?php
$filepath ="ator.txt";
$myfile = fopen($filepath, "a+") or die("Unable to open file!");
$ator = nl2br(preg_replace($pattern, $sing, $str));
/*fwrite($myfile, substr("Name: ".$_GET["name"]." "."<br>",0,36));*/
if ($ator ==NULL OR $str=="Ich fl / l ausche P ul / ol lis / ice.
The T w / o ilit of the G od / ut s !!! / ???
A / B
aaa / bbb
ccc / ddd"){echo "piep";}
else {
fwrite($myfile, $ator."<br>");
/*
* fwrite($myfile, substr("b,<br> ".$_GET["md2"]."<br>",0,105));*/
fwrite($myfile,date('y/m/d, H')." Uhr<br>");}
fclose($myfile);
unset($str);
?>
</div>
<div id='box' class='right' style="overflow:true;"><p><u><b>An­lei­tung :</b></u> Ge­ben Sie Ihr­en Schmidt­etym­bruch zu ein­em bis drei Zei­chen, mit Leer­zei­chen ab­ge­setzt, ge­tren­nt mit ei­nem Schräg­strich<pre><code>"	 / 	"
" aa / bbb "</code></pre>, die­sen mit Leer­zei­chen ( Pau­sen ) { Spa­ce , gro­ße läng­ste Tast­e } um­schlos­sen, ein. O­hne füh­ren­de Leer­zei­chen geht es auch, mit ggf. un­ge­wol­ltem Er­geb­nis. Kon­trol­lieren Sie das Er­geb­nis! Sie kön­nen den html out­put e­di­tie­ren und noch mal ein­fü­gen, dann kom­men Sie zu höh­er­en Le­vels. Z.B. aus ei­nem <pre><code><sub>v</sub></code></pre> mach­en Sie <pre><code><sub> v / f </sub></code></pre>. Um­lau­te und sz wer­den of­fen­sicht­lich als zwei Zei­chen in­ter­pre­tiert. Län­ge­re Aus­drük­ke in ( Drei­er- ) grup­pen um­wan­deln: <pre>Z.B. 3 + 3 + 2.</pre> Sonst­ige Zahl­en oder Zeich­en sind nicht zu­ge­las­sen. Das Pro­gramm be­nutzt Reg­ex und css. Der Re­gex­aus­druck kön­nte um wei­te­re Zeich­en er­gänzt wer­den. Wir schrei­ben die Ein­ga­be mit ( <a href="./ator.txt">hier</a> oder <a href="./deepspace.htm.php">mit Stil</a>).
Vorsicht: Suchtgefahr.</p></div>
<div style="clear:both;"></div>
<div style="align:left;text-align:center;position:static;">
<p style="color:#fff5ee;">The t<span style='vertical-align:-10px;'><span class='frac'><sup>wi</sup><span> / </span><sub>oi</sub></span></span>lit of the G<span style='vertical-align:-10px;'><span class='frac'><sup>od</sup><span> / </span><sub>ut</sub></span></span>s.</p>
<p style="color:#fff5ee;align:center;">© <span style='vertical-align:-10px;'><span class='frac'><sup>Kl</sup><span> / </span><sub>L</sub></span></span>aus <span style='vertical-align:-10px;'><span class='frac'><sup>Wul</sup><span> / </span><sub>Vul</sub></span><span class='frac'><sup>ff</sup><span> / </span><sub>v</sub></span></span>	2009—<?php
echo date("Y");
?>.</p>
<p style="color:#fff5ee;align:center;">© <a href="https://www.matheretter.de/wiki/bruch-schreiben">matheretter.de</a></p></div>
</body>
</html>