Hi, thanks a lot for your offer Shaun. <div><br></div><div>That was actually what I thought the solution to be. Now let's forget what I said and focus on what I need to accomplish. </div><div><br></div><div>Yes, I totally control the page content. The situation is, </div>
<div><br></div><div>I am designing a web portal that can launch back-end server side processes. The problem is that the process can finish in seconds, or it might need hours to finish, depending how much work the process has. So my design is to spawn a sub process, and capture all its outputs to a log text file, then return immediately to the user, in a web notice page saying, your job is queued; here is the log url; please check manually if is finished or not. </div>
<div><br></div><div>But my all my fellow coworkers said they don't want to check themselves. Instead, they want my web portal to check for them. I couldn't think of any solution from the server side to capture the end of the sub process, then informed the already submitted web notice page. Hence, I'm turning to the javascript front-end for solutions. Because I have zero knowledge of Javascript, it might not be feasible at all. But I know the best solution is that if I can have a desktop notification mechanism just like gmail does, that should solve the problem, because my sub process control task does know when the sub process ends, and write a specific ending tag to the end of the log file, which is what I was planning to watch/search for. Every page of my portal does include a standard master template (except the log text file), so if I can send a signal at the end of my sub process and capture that by the master template, then pop up a javascript window, that will do as well. </div>
<div><br></div><div>Sorry for the lengthy gibberish, hope that you can figure something out from it. </div><div><br></div><div>Thanks</div><div><br><div class="gmail_quote">On Wed, Oct 10, 2012 at 3:01 AM, Shaun Fryer <span dir="ltr"><<a href="mailto:sfryer@sourcery.ca" target="_blank">sfryer@sourcery.ca</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Antonio,<br>
<br>
I might be able to help you, but first I need to know a bit more<br>
detail about what you're trying to do. When you say watch for certain<br>
keywords from a webpage, what do you mean exactly? If you mean<br>
searching through a static html document looking for a give word or<br>
words, that's fairly trivial. However, if you can add javascript to<br>
the page in question, then you probably control the page, and<br>
therefore should already know it's content. So question is, why would<br>
you need front-end code in JavaScript to do it? If you mean doing an<br>
HTTP request from within a web-page, or even a Cross Origin request,<br>
in order to receive info from a 3rd-party website, then things could<br>
become considerably more complicated.<br>
<br>
Cheers,<br>
--<br>
Shaun Fryer<br>
----------------------------------------------------------<br>
perl -e 'print chr for map{$_+=22}($ARGV[0])=~/(\d\d)/g' \<br>
52959394107588899482799210587992861082757785799222<br>
----------------------------------------------------------<br>
<div class="im HOEnZb"><br>
<br>
On Tue, Oct 9, 2012 at 5:48 PM, Antonio Sun <<a href="mailto:antoniosun@lavabit.com">antoniosun@lavabit.com</a>> wrote:<br>
</div><div class="HOEnZb"><div class="h5">> Hi,<br>
><br>
> I know it's kind of OT, but since we have a lot of web experts here, let me<br>
> try my luck here first.<br>
><br>
> I have zero knowledge of Javascript, I'm wondering if you could give me a<br>
> big favor to show me how to watch for certain keyword from a web page using<br>
> Javascript.<br>
><br>
> Basically, I have a slow updating web page, and I need a client side<br>
> Javascript to watch for a specific keyword in that page and pop up an window<br>
> if the keyword is found.<br>
><br>
> As I have zero knowledge of Javascript, I hope that your answer is as<br>
> complete as possible.<br>
><br>
> Thanks a lot in advance<br>
><br>
> Antonio<br>
><br>
><br>
</div></div><div class="HOEnZb"><div class="h5">> _______________________________________________<br>
> toronto-pm mailing list<br>
> <a href="mailto:toronto-pm@pm.org">toronto-pm@pm.org</a><br>
> <a href="http://mail.pm.org/mailman/listinfo/toronto-pm" target="_blank">http://mail.pm.org/mailman/listinfo/toronto-pm</a><br>
><br>
</div></div></blockquote></div><br></div>