Oct
23
2008
eingabe: <ASD asd=SDf SDA=F sad=F dsaf =SDAf =s daf=SDA f=SA Df=><P style=”border:2px solid lightblue;padding:10;text-align:center;color:royalblue;background:aliceblue width = = 123″><B>Welco
ausgabe: <ASD asd=”SDf” SDA=”F” sad=”F” dsaf=SDAf=”s” daf=”SDA” f=”SA” Df=><P style=”border:2px solid lightblue;padding:10;text-align:center;color:royalblue;background:aliceblue” width==”123″><B>Welco
<TEXTAREA id=n rows=10 cols=100></TEXTAREA>
<SCRIPT>
//a='<A href= asdsad name1 = aus1 name2 = \’aus2\’ asdsad = “32wq”>lkh</A>\n<asd=wqer<>><ASD asd=SDf SDA=F sad=F dsaf =SDAf =s daf=SDA f=SA Df=><P style=”border:2px solid lightblue;padding:10;text-align:center;color:royalblue;background:aliceblue”><B>Welco’
a='<ASD asd=SDf SDA=F sad=F dsaf =SDAf =s daf=SDA f=SA Df=><P style=”border:2px solid lightblue;padding:10;text-align:center;color:royalblue;background:aliceblue width = = 123″><B>Welco’
document.getElementById(‘n’).value=a+”\n\n”
document.getElementById(‘n’).value+=a.replace(/ ?= */g, “=”).replace(/[“‘]/g,””).replace(/(=)([^=><]+)([> ])/gi, “$1\”$2\”$3”)
</SCRIPT>
Comments Off on [javascript regex] nach = wort in ” ” wenn in <* > uiuiuiu | posted in bash
Oct
21
2008
a='<p align=center><i>text</i></p><b>bold</b><img src=><a href=sdasdadasdasda</a></img>’
a.replace(/<([/]?)([a-zA-Z]{1,8})(\ ?)/gi, function(m){return m.toUpperCase()} )
//b=a.replace(/<([/]?)([a-zA-Z]{1,8})(\ ?)/gi, ‘<$1($2)$3’)
ausgabe:
<P align=center><I>text</I></P><B>bold</B><IMG src=><A href=sdasdadasdasda</A></IMG>
Comments Off on [javascript] search replace | posted in bash
Oct
13
2008
cat lo | sed -e “s/\(.\{70\}\)/\1\n/g”
Comments Off on [bash – sed] after 70 chars one enter | posted in bash
Oct
12
2008
cat as|sed -e ‘s/^.*\ \(.*\)$/\1/1’
to search for last space, and swap it to begining
cat usercase_workingfile| grep “View top”|sed -e “s/^.*- \(.*\)<.*$/\1/”| sed -e ‘s/^\(.\{,25\}\).*$/\1/g’|sed -e ‘s/^\(.*\)\ \(.*\)$/\2 – \1/’
Comments Off on [bash – sed] del begin to last space, show rest of space | posted in bash
Oct
12
2008
sed -e ‘s/^\(.\{,5\}\).*$/\1/g’
Comments Off on [bash – sed] show 1st 5 chars, del rest | posted in bash
Oct
9
2008
./configure –enable-libmp3lame –enable-static –libdir=/{MEIN-HOME}/lib –incdir=/{MEIN-HOME}/include –shlibdir=/{MEIN-HOME}/lib –extra-ldflags=-L/{MEIN-HOME}/lib –extra-cflags=-I/{MEIN-HOME}/include
vorher lame installieren:
./configure –prefix={home}/arbeitsverzeichnis/
und nciht vergessen, bei ffmpeg ist noch ne .sh datei, die auf +x gesetzt werden muss
dann mit
../bin/bin/ffmpeg -i denim.wmv -ar 44100 -s cif -b 500kbit/s denim.flv
konvertieren
Comments Off on ffmpeg auf webserver installieren mit lame | posted in bash
Oct
6
2008
find ./ -depth -type d -empty -exec mv “{}” ./empty/ \;
test:
find ./ -depth -type d -empty -exec echo “{}” ./empty/ \;
Comments Off on [bash] search empty folder and mv to ./empty | posted in bash