1. Halo Guest, pastikan Anda selalu menaati peraturan forum sebelum mengirimkan post atau thread baru.

[ASK] iMacros Javascript Check if Text Appears on Web Page

Discussion in 'Pemrograman Web' started by iTunes.Jr, May 19, 2019.

  1. iTunes.Jr

    iTunes.Jr AdSense Fan

    Joined:
    Aug 28, 2013
    Messages:
    144
    Likes Received:
    4
    Location:
    www.saelendra.com
    Halo master2 ads.id :)
    Setelah sekian lama tdk pernah posting, akhirnya posting juga malam ini :)
    Lagi mumet nih, mentok script imacros saya :( mau minta bantuan suhu2 disini :)

    Jadi begini, saya ada satu buah kata yang ingin dicek disebuah halaman website, jika HANYA SATU KATA tsb ada di halaman website tsb maka proses "imacros A" akan berjalan. Namun apabila kalimat (keyword) tsb tidak ditemukan di halaman website tsb maka proses "imacros B" yg akan berjalan.

    Begini kondisi script yg sedang sy kerjakan saat ini :

    for (var i=1;i<50;i++){
    var ret = iimPlayCode("SEARCH SOURCE=TXT:\"Follow\"")
    if(ret==1){ //ada text Follow di halaman
    iimPlay("iMacrosA.iim")
    }
    else
    {
    iimPlay("iMacrosB.iim")
    }
    }
    Seharusnya jika kata Follow tidak ada di halaman website tsb, imacros B akan berjalan bukan?
    Akan tetapi tidak demikian hasilnya :(
    Di halaman web ada beberapa kata following, followed, followers, tetapi TIDAK ADA kata FOLLOW saja. Saya rasa script ini menangkap kata2 yang mengandung kata Follow, bukan HANYA kata Follow saja. Pertanyaan sy, apa benar demikian? Jika iya mohon bantuan suhu2 n master2 disini :D

    Sebelumnya saya ucapkan banyak terima kasih :)
     
    Last edited: May 19, 2019
  2. iTunes.Jr

    iTunes.Jr AdSense Fan

    Joined:
    Aug 28, 2013
    Messages:
    144
    Likes Received:
    4
    Location:
    www.saelendra.com
    helppp meee pleaseeee... :(
     
  3. linkcluster

    linkcluster AdSense Pro

    Joined:
    Jan 6, 2011
    Messages:
    490
    Likes Received:
    33
    Location:
    under contruction
    udh 10thn lalu terakhir pake imcros,
    apa masih bntk yg pake teknologin jadul ini,..
    stlah bnyknya bermunculan teknologi2 scraper modern
     
  4. iTunes.Jr

    iTunes.Jr AdSense Fan

    Joined:
    Aug 28, 2013
    Messages:
    144
    Likes Received:
    4
    Location:
    www.saelendra.com
    walaupun jadul tp fungsinya om, ehehe...
    ayooo om bantuin dunkkk.. :D
    thank you
     
  5. oprekbot

    oprekbot AdSense Starter

    Joined:
    Dec 9, 2016
    Messages:
    87
    Likes Received:
    45
    Coba aja pake SOURCE=REGEXP
     
  6. iTunes.Jr

    iTunes.Jr AdSense Fan

    Joined:
    Aug 28, 2013
    Messages:
    144
    Likes Received:
    4
    Location:
    www.saelendra.com
    Halo masbro, sblmnya thanks ud mau bantu reply ya...
    Saya coba sprt ini tp kok masih blm bs ya? Ada ide lain? :)

    var ret = iimPlayCode("SEARCH SOURCE=REGEXP:\"Follow\"")
     
  7. oprekbot

    oprekbot AdSense Starter

    Joined:
    Dec 9, 2016
    Messages:
    87
    Likes Received:
    45
    Coba kasi boundary, seperti ini
    Code:
    \bFollow\b
    :
     
  8. iTunes.Jr

    iTunes.Jr AdSense Fan

    Joined:
    Aug 28, 2013
    Messages:
    144
    Likes Received:
    4
    Location:
    www.saelendra.com
    Seperti ini ya masbro ??

    var ret = iimPlayCode("SEARCH SOURCE=REGEXP:\bFollow\b")

    kalau benar sprt itu, gagal juga, nggak bisa :(
     
  9. hacktube

    hacktube AdSense Fan

    Joined:
    Jun 3, 2013
    Messages:
    192
    Likes Received:
    11
    lebih baik pakai puppeteer saja gan. kalau butuh jasa scraper bisa hubungi saya. :D
     
  10. iTunes.Jr

    iTunes.Jr AdSense Fan

    Joined:
    Aug 28, 2013
    Messages:
    144
    Likes Received:
    4
    Location:
    www.saelendra.com
    cek PM om....
     
  11. iTunes.Jr

    iTunes.Jr AdSense Fan

    Joined:
    Aug 28, 2013
    Messages:
    144
    Likes Received:
    4
    Location:
    www.saelendra.com
    uppp, sambil menunggu jawaban...
     
  12. oprekbot

    oprekbot AdSense Starter

    Joined:
    Dec 9, 2016
    Messages:
    87
    Likes Received:
    45
    Coba pakai double blackslash seperti ini :
    Code:
    REGEXP:\\bFollow\\b
     
  13. iTunes.Jr

    iTunes.Jr AdSense Fan

    Joined:
    Aug 28, 2013
    Messages:
    144
    Likes Received:
    4
    Location:
    www.saelendra.com
    gagal maning omm :(
     
  14. oprekbot

    oprekbot AdSense Starter

    Joined:
    Dec 9, 2016
    Messages:
    87
    Likes Received:
    45
    Gagalnya gimana gan?
    Kemarin iseng saya coba, jalan tuh.

    Btw, nih mo bikin bot buat ig ya?
     
  15. imel404

    imel404 AdSense Starter

    Joined:
    Oct 17, 2017
    Messages:
    87
    Likes Received:
    572

Share This Page