<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-gb">
	<link rel="self" type="application/atom+xml" href="https://forum.eggheads.org/app.php/feed/topic/6497" />

	<title>egghelp/eggheads community</title>
	<subtitle>Discussion of eggdrop bots, shell accounts and tcl scripts.</subtitle>
	<link href="https://forum.eggheads.org/index.php" />
	<updated>2003-12-30T17:23:57-04:00</updated>

	<author><name><![CDATA[egghelp/eggheads community]]></name></author>
	<id>https://forum.eggheads.org/app.php/feed/topic/6497</id>

		<entry>
		<author><name><![CDATA[Sir_Fz]]></name></author>
		<updated>2003-12-30T17:23:57-04:00</updated>

		<published>2003-12-30T17:23:57-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=31996#p31996</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=31996#p31996"/>
		<title type="html"><![CDATA[regsub]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=31996#p31996"><![CDATA[
Hope you're enjoying your vacation <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><br><br>Merry Christmas and happy New Year.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3085">Sir_Fz</a> — Tue Dec 30, 2003 5:23 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Papillon]]></name></author>
		<updated>2003-12-30T15:44:13-04:00</updated>

		<published>2003-12-30T15:44:13-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=31992#p31992</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=31992#p31992"/>
		<title type="html"><![CDATA[regsub]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=31992#p31992"><![CDATA[
/me feels loved  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_mrgreen.gif" width="15" height="15" alt=":mrgreen:" title="Mr. Green"> <br>Merry Xmas and Happy New Year!  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_cool.gif" width="15" height="15" alt="8)" title="Cool"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=852">Papillon</a> — Tue Dec 30, 2003 3:44 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2003-12-30T15:30:01-04:00</updated>

		<published>2003-12-30T15:30:01-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=31991#p31991</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=31991#p31991"/>
		<title type="html"><![CDATA[regsub]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=31991#p31991"><![CDATA[
As usualy, I love you man! <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_mrgreen.gif" width="15" height="15" alt=":mrgreen:" title="Mr. Green"> Merry Xmas and Happy New Year! <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_razz.gif" width="15" height="15" alt=":P" title="Razz"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Tue Dec 30, 2003 3:30 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Papillon]]></name></author>
		<updated>2003-12-30T11:57:06-04:00</updated>

		<published>2003-12-30T11:57:06-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=31983#p31983</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=31983#p31983"/>
		<title type="html"><![CDATA[regsub]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=31983#p31983"><![CDATA[
something like this?<div class="codebox"><p>Code: </p><pre><code>foreach line [split $tosave \n] {     if {[llength $line] == 0 || [lindex $line 0] == {-}} {       continue     }     regsub {(\d){2,}[']} [string trim $line] {} line     if {[regexp {^(\d){2}:(\d){2}$} $line]} {       set nline $line       continue    } else {      append nline " $line"      putlog $nline       unset nline    }    incr i   }</code></pre></div>hehe, thx but I'm just home for xmas Sir_Fz  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_mrgreen.gif" width="15" height="15" alt=":mrgreen:" title="Mr. Green"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=852">Papillon</a> — Tue Dec 30, 2003 11:57 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2003-12-30T10:39:27-04:00</updated>

		<published>2003-12-30T10:39:27-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=31978#p31978</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=31978#p31978"/>
		<title type="html"><![CDATA[regsub]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=31978#p31978"><![CDATA[
Adding "|[&lt;*&gt;]" to the regsub like regsub -all -- { |[&lt;*&gt;]} $tosave { }  tosave and all seem to be working smoothly. Thank you <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_mrgreen.gif" width="15" height="15" alt=":mrgreen:" title="Mr. Green"><br><br>Btw, how should I make it arrange them like:<blockquote class="uncited"><div>Date: Marti, 30-12-2003<br>07:00 Dennis, pericol public (SUA desene animate, rel.)<br>08:00 Minute de milioane<br>etc.</div></blockquote><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Tue Dec 30, 2003 10:39 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Sir_Fz]]></name></author>
		<updated>2003-12-30T10:18:33-04:00</updated>

		<published>2003-12-30T10:18:33-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=31977#p31977</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=31977#p31977"/>
		<title type="html"><![CDATA[regsub]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=31977#p31977"><![CDATA[
Alright! welcome back Papillon <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_razz.gif" width="15" height="15" alt=":P" title="Razz"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3085">Sir_Fz</a> — Tue Dec 30, 2003 10:18 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Papillon]]></name></author>
		<updated>2003-12-30T08:40:25-04:00</updated>

		<published>2003-12-30T08:40:25-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=31973#p31973</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=31973#p31973"/>
		<title type="html"><![CDATA[regsub]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=31973#p31973"><![CDATA[
hehe... I'm bored, so I modified your script abit... I think it's faster now <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_wink.gif" width="15" height="15" alt=";)" title="Wink"><div class="codebox"><p>Code: </p><pre><code>bind dcc * bla my:bla proc my:bla {idx hand arg} {   set content [read [set f [open "tv.txt" r]]][close $f]  putlog "searching..."   set tosave [string range $content [set f [string first "&lt;!-- programul canalului ales --&gt;" $content]] [string first "&lt;!-- template 2000 jos--&gt;" $content $f]]  regsub -all -- {&lt;/b&gt;|&lt;br&gt;|&lt;/font&gt;} $tosave {  }  tosave  regsub -all -- {&lt;[^&gt;]*&gt;} $tosave {}  tosave  regsub -all -- { } $tosave { }  tosave  set i 0 ;set o {}  foreach line [split $tosave \n] {     if {[llength $line] == 0 || [lindex $line 0] == {-}} {       continue     }     regsub {(\d){2,}[']} [string trim $line] {} line    putlog $line    incr i   }   putlog "finished... $i line[expr {$i==1?"":"s"}].." } </code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=852">Papillon</a> — Tue Dec 30, 2003 8:40 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2003-12-30T07:54:39-04:00</updated>

		<published>2003-12-30T07:54:39-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=31972#p31972</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=31972#p31972"/>
		<title type="html"><![CDATA[regsub]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=31972#p31972"><![CDATA[
I did now <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_razz.gif" width="15" height="15" alt=":P" title="Razz">  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_mrgreen.gif" width="15" height="15" alt=":mrgreen:" title="Mr. Green"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Tue Dec 30, 2003 7:54 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Papillon]]></name></author>
		<updated>2003-12-30T07:43:48-04:00</updated>

		<published>2003-12-30T07:43:48-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=31971#p31971</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=31971#p31971"/>
		<title type="html"><![CDATA[regsub]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=31971#p31971"><![CDATA[
<blockquote class="uncited"><div>And from an line like "href=<a href="http://tv.kappa.ro/loc__detalii/id__469556" class="postlink">http://tv.kappa.ro/loc__detalii/id__469556</a> Roseanne (SUA serial de comedie, 1988) 30" I want to remove the url and it's random number and the last number of the line..</div></blockquote>you didn't say anything about the <em class="text-italics">[01:23]</em> <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=852">Papillon</a> — Tue Dec 30, 2003 7:43 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2003-12-29T19:22:37-04:00</updated>

		<published>2003-12-29T19:22:37-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=31955#p31955</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=31955#p31955"/>
		<title type="html"><![CDATA[regsub]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=31955#p31955"><![CDATA[
The first regsub seems to be working fine but the second is not removing corectly, it removes the minutes also.. (bot): [01:23] 01: &lt;~ there should be some minutes and the year like (bot): [01:27] Luni, 29-12- <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Mon Dec 29, 2003 7:22 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Papillon]]></name></author>
		<updated>2003-12-29T18:01:59-04:00</updated>

		<published>2003-12-29T18:01:59-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=31951#p31951</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=31951#p31951"/>
		<title type="html"><![CDATA[regsub]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=31951#p31951"><![CDATA[
try it like this<div class="codebox"><p>Code: </p><pre><code>foreach line $tosave {     if {[llength $line] == 0} {       continue     }     regsub {(href=http:).*(id__)(\d){6}} $line {} line     regsub {(\d){2,}$} $line {} line    putlog $line     incr i   }   putlog "finished... $i line[expr {$i==1?"":"s"}].." </code></pre></div>this is from my tclsh:<blockquote class="uncited"><div>% set line "href=<a href="http://tv.kappa.ro/loc__detalii/id__469556Roseanne" class="postlink">http://tv.kappa.ro/loc__detalii/id__469556Roseanne</a> (SUA serial de comedie, 1988) 30"<br>href=<a href="http://tv.kappa.ro/loc__detalii/id__469556" class="postlink">http://tv.kappa.ro/loc__detalii/id__469556</a> Roseanne (SUA serial de comedie, 1988) 30<br>% regsub {(href=http:).*(id__)(\d){6}} $line {} line ;puts $line<br> Roseanne (SUA serial de comedie, 1988) 30<br>% regsub {(\d){2,}$} $line {} line ;puts $line<br> Roseanne (SUA serial de comedie, 1988)<br>%</div></blockquote><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=852">Papillon</a> — Mon Dec 29, 2003 6:01 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2003-12-29T09:13:11-04:00</updated>

		<published>2003-12-29T09:13:11-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=31921#p31921</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=31921#p31921"/>
		<title type="html"><![CDATA[regsub]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=31921#p31921"><![CDATA[
Well.. it dosen't seem to be working.. Here is the code I have done till now:<div class="codebox"><p>Code: </p><pre><code>bind dcc * bla my:blaproc my:bla {idx hand arg} {  set content [split [read [set f [open "tv.txt" r]]][close $f] \n]   putlog "searching..."  regsub -all -- {&lt;td|colspan="3"|bgcolor="#EFEFEF"&gt;&lt;div align="center"&gt;&lt;strong&gt;|&lt;/strong&gt;&lt;/div&gt;&lt;/td&gt;} $content "" content  regsub -all -- {&lt;table width="440"|cellpadding="0"|cellspacing="0"|align="center"|border=0&gt;|&lt;tr&gt;|&lt;/tr&gt;} $content "" content  regsub -all -- {valign="top"|width="40"|&gt;&lt;font size=1&gt;|&lt;/font&gt;&lt;/td&gt;|width="20"|&gt;-&lt;/td&gt;|&lt;B&gt;|&lt;/B&gt;} $content "" content  regsub -all -- {&lt;a||bgColor='#fafafa'|bgColor='#A6A6FF'|style='text-decoration:none} $content "" content  regsub -all -- {'&lt;/font&gt; &lt;img|src='http://tv.kappa.ro/images/detalii.gif'|border=0 alt='detalii'&gt;&lt;/a&gt;|&lt;/font&gt; &lt;img|'} $content "" content  set up [expr [lsearch $content "&lt;!-- programul canalului ales --&gt;"] + 2]  set down [expr [lsearch $content "*&lt;!-- template 2000 jos--&gt;*"] - 2]  set tosave [lrange $content $up $down]  set i 0  foreach line $tosave {    if {[llength $line] == 0} {      continue    }    putlog $line    incr i  }  putlog "finished... $i line[expr {$i==1?"":"s"}].."}</code></pre></div>and <a href="http://www.geocities.com/cezarica01/tv.txt" class="postlink">here</a> is the tv.txt file..<br><br>And from an line like "href=<a href="http://tv.kappa.ro/loc__detalii/id__469556" class="postlink">http://tv.kappa.ro/loc__detalii/id__469556</a> Roseanne (SUA serial de comedie, 1988) 30" I want to remove the url and it's random number and the last number of the line..<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Mon Dec 29, 2003 9:13 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Papillon]]></name></author>
		<updated>2003-12-29T08:17:13-04:00</updated>

		<published>2003-12-29T08:17:13-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=31917#p31917</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=31917#p31917"/>
		<title type="html"><![CDATA[regsub]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=31917#p31917"><![CDATA[
<div class="codebox"><p>Code: </p><pre><code>#to remove the http-part (as long as the number is always 6 digits long)regsub { (href=http:).*(id__)(\d){6}} $line {} newline#to remove the numbers and the 'regsub { (\d){3}\'} $line {} newline</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=852">Papillon</a> — Mon Dec 29, 2003 8:17 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2003-12-29T07:03:47-04:00</updated>

		<published>2003-12-29T07:03:47-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=31914#p31914</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=31914#p31914"/>
		<title type="html"><![CDATA[regsub]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=31914#p31914"><![CDATA[
How to regsub something like "href=<a href="http://some.page.here/page__id/id__123456" class="postlink">http://some.page.here/page__id/id__123456</a>" where the 123456 are some random numbers from an line like "bla bla bla href=<a href="http://some.page.here/page__id/id__123456" class="postlink">http://some.page.here/page__id/id__123456</a> bla bla bla" .. and to regsub something like "bla bla bla 123' bla bla" and remove the 123 random numbers and the '<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Mon Dec 29, 2003 7:03 am</p><hr />
]]></content>
	</entry>
	</feed>
