mIRC Homepage
Posted By: New_One need help with this script dosn't - 08/01/21 07:16 PM
hello i need help with this script it dosn't work anymore , we use it in a little chanel with 20-30 users and we do not have some eggdrop bot , if someone could help us smile thnx
on *:text:!H*:#horo: {
if ( $istok(Dashi Demi Binjaket Gaforrja Luani Virgjeresha Peshorja Akrepi Shigjetari Bricjapi Ujori Peshqit,$2,32) ) {
set %shenja1 $2
unset %terminal
unset %mesazhihoroskopit*
set %periudha.horoskopi Lindur me:
set %kanalihoroskopit $chan
set %fillohoroskopin <p>
sockclose horoskopi
sockopen horoskopi www.horoskopishqip.com 80
}
}
on *:sockopen:horoskopi: {
sockwrite -n horoskopi GET https://www.horoskopishqip.com/horoskopi-ditor/shenja $+ %shenja1 $+ /
}
on *:sockread:horoskopi: {
sockread %horoskopi.temp
if (%periudha.horoskopi isin %horoskopi.temp) { set %periudha $remove($gettok(%horoskopi.temp,3,62),</span) }
if ((%fillohoroskopin isin %horoskopi.temp) && (!%terminal)) {
set %horoskopi.frase %horoskopi.temp
set %terminal !
/set %mesazhihoroskopit $remove(%horoskopi.temp,</p>,<p>)
if ( $len(%mesazhihoroskopit) > 417 ) {
set %mesazhihoroskopit2 0,2 ... $+ $right(%mesazhihoroskopit,$calc($len(%mesazhihoroskopit) - 410)) 
set %mesazhihoroskopit $remove(%mesazhihoroskopit,$right(%mesazhihoroskopit,$calc($len(%mesazhihoroskopit) - 410)))
set %mesazhihoroskopit %mesazhihoroskopit $+ ... 
}
/msg %kanalihoroskopit %mesazhihoroskopit
if ( %mesazhihoroskopit2 != $null ) { /msg %kanalihoroskopit %mesazhihoroskopit2 }
}
}
Posted By: Loki12583 Re: need help with this script dosn't - 09/01/21 01:11 AM
You have to use https:

Code
sockopen -e horoskopi www.horoskopishqip.com 443
Posted By: New_One Re: need help with this script dosn't - 09/01/21 09:51 AM
still doesn't work .....
Posted By: Loki12583 Re: need help with this script dosn't - 09/01/21 02:25 PM
Oh well looking again, your script is incomplete. You need to send more data for a valid HTTP request, so I don't see how this could have been working before.

Code
on *:sockopen:horoskopi: {
  sockwrite -n horoskopi GET /horoskopi-ditor/shenja $+ %shenja1 $+ / HTTP/1.1
  sockwrite -n horoskopi Host: $sock($sockname).addr
  sockwrite -n horoskopi Connection: close
  sockwrite -n horoskopi $crlf
}
Posted By: New_One Re: need help with this script dosn't - 09/01/21 02:43 PM
still doen't work or something im doing wrong , thank you for your help smile


on *:text:!H*:#horo: {
if ( $istok(Dashi Demi Binjaket Gaforrja Luani Virgjeresha Peshorja Akrepi Shigjetari Bricjapi Ujori Peshqit,$2,32) ) {
set %shenja1 $2
unset %terminal
unset %mesazhihoroskopit*
set %periudha.horoskopi Lindur me:
set %kanalihoroskopit $chan
set %fillohoroskopin <p>
sockclose horoskopi
sockopen -e horoskopi www.horoskopishqip.com 443
}
}
on *:sockopen:horoskopi: {
sockwrite -n horoskopi GET /horoskopi-ditor/shenja $+ %shenja1 $+ / HTTP/1.1
sockwrite -n horoskopi Host: $sock($sockname).addr
sockwrite -n horoskopi Connection: close
sockwrite -n horoskopi $crlf
}
on *:sockread:horoskopi: {
sockread %horoskopi.temp
if (%periudha.horoskopi isin %horoskopi.temp) { set %periudha $remove($gettok(%horoskopi.temp,3,62),</span) }
if ((%fillohoroskopin isin %horoskopi.temp) && (!%terminal)) {
set %horoskopi.frase %horoskopi.temp
set %terminal !
/set %mesazhihoroskopit $remove(%horoskopi.temp,</p>,<p>)
if ( $len(%mesazhihoroskopit) > 417 ) {
set %mesazhihoroskopit2 0,2 ... $+ $right(%mesazhihoroskopit,$calc($len(%mesazhihoroskopit) - 410)) 
set %mesazhihoroskopit $remove(%mesazhihoroskopit,$right(%mesazhihoroskopit,$calc($len(%mesazhihoroskopit) - 410)))
set %mesazhihoroskopit %mesazhihoroskopit $+ ... 
}
/msg %kanalihoroskopit %mesazhihoroskopit
if ( %mesazhihoroskopit2 != $null ) { /msg %kanalihoroskopit %mesazhihoroskopit2 }
}
}
Posted By: Loki12583 Re: need help with this script dosn't - 09/01/21 03:20 PM
Well you'll need to come up with more than "not working", it appears to work for me though I can't read it.

www.horoskopishqip.com/horoskopi-ditor/shenjaDemi/
Këtu mund të gjeni shenjën tuaj të horoskopit duke zgjedhur datëlindjën tuaj.

You can try to change HTTP/1.1 to HTTP/1.0 to avoid chunked transfer encoding:

Code
sockwrite -n horoskopi GET /horoskopi-ditor/shenja $+ %shenja1 $+ / HTTP/1.0
Posted By: Bes Re: need help with this script dosn't - 09/01/21 06:29 PM
Hello New_One,
Pershendetje.

i have tested and function perfect.

Code
[19:09:54] <AdmiraL> !h demi
[19:09:55] <Alb> Po përjetoni një fazë acarimi ndaj shumë njerëzve. Mundohuni të shtyni takimet për javën e ardhshme, projektet do të marrin hov. Së shpejti dashuria do ecë mirë. Nga 13 janari, Venusi i favorshëm do të sjellë lajme të këndshme.
[19:10:03] <AdmiraL> !h dashi
[19:10:04] <Alb> Nesër nuk do të jetë më e mira për ju, veçanërisht në lidhje me dashurinë, prandaj përpiquni të qëndroni larg polemikave. Mundohuni të bëni minimumin por mos u dekurajoni: lajmet e mira do të vijnë në punë nga 12 janari.
[19:10:45] <AdmiraL> !h gaforrja
[19:10:46] <Alb> Duhet të përpiqeni të kompensoni në dashuri kohën e humbur për të cilën po përpiqeni të organizoni një udhëtim ose një fundjavë romantike. Në punë, edhe nëse keni ide të mira, gjithmonë duhet të luftoni për t’u imponuar.


Here is Script :

Code
on *:text:!h *:#egitim: {
  if ( $istok(Dashi Demi Binjaket Gaforrja Luani Virgjeresha Peshorja Akrepi Shigjetari Bricjapi Ujori Peshqit,$2,32) ) {
    set %shenja1 $2
    unset %terminal
    unset %mesazhihoroskopit*
    set %periudha.horoskopi Lindur me:
    set %kanalihoroskopit $chan
    set %fillohoroskopin <p>
    sockclose horoskopi
    sockopen -e horoskopi www.horoskopishqip.com 443

  }
}
on *:sockopen:horoskopi: {
  sockwrite -n horoskopi GET /shenja/ $+ %shenja1 $+ / HTTP/1.0
  sockwrite -n horoskopi Host: $sock($sockname).addr
  sockwrite -n horoskopi Connection: close
  sockwrite -n horoskopi $crlf
}
on *:sockread:horoskopi: {
  sockread %horoskopi.temp
  if (%periudha.horoskopi isin %horoskopi.temp) { set %periudha $remove($gettok(%horoskopi.temp,3,62),</span) }
  if ((%fillohoroskopin isin %horoskopi.temp) && (!%terminal)) {
    set %horoskopi.frase %horoskopi.temp
    set %terminal !
    /set %mesazhihoroskopit $remove(%horoskopi.temp,</p>,<p>)
    if ( $len(%mesazhihoroskopit) > 0 ) {
      set %mesazhihoroskopit2 $+ $right(%mesazhihoroskopit,$calc($len(%mesazhihoroskopit) - 1800))
      set %mesazhihoroskopit $remove(%mesazhihoroskopit,$right(%mesazhihoroskopit,$calc($len(%mesazhihoroskopit) - 1800)))
      set %mesazhihoroskopit %mesazhihoroskopit $+
    }
    /msg #egitim 10 %mesazhihoroskopit
    if ( %mesazhihoroskopit2 != $null ) { /msg #egitim 10 %mesazhihoroskopit2 }
  }
}

on *:TEXT:!h:#egitim: {
  /msg #egitim 10 Perdorimi i Horoskopit: !h <shenja juaj> 
/msg #egitim 10 Opsionet: Dashi Demi Binjaket Gaforrja Luani Virgjeresha Peshorja Akrepi Shigjetari Bricjapi Ujori Peshqit $halt - }

on *:ACTION:!h:#egitim: {
  /msg #egitim 10 Perdorimi i Horoskopit: !h <shenja juaj> 
/msg #egitim 10 Opsionet: Dashi Demi Binjaket Gaforrja Luani Virgjeresha Peshorja Akrepi Shigjetari Bricjapi Ujori Peshqit $halt - }





When you have a question you can write to me smile or send me a PM
shkrujem prv..:)
© mIRC Discussion Forums