Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things

Re^3: Opening URL in instrumented browser

by Arunbear (Parson)
on Sep 18, 2013 at 10:18 UTC ( #1054631=note: print w/ replies, xml ) Need Help??

in reply to Re^2: Opening URL in instrumented browser
in thread Opening URL in instrumented browser

Yes, it is a blocking call:

% perl -E 'system(q[opera]); say "hello!" ' + hello!
That only prints "hello!" once Opera exists. Non-blocking alternatives are:
% perl -E 'system(q[opera &]); say "hello!" +' hello!
i.e. launching in the background, or
% perl -E '$r = fork; if($r == 0) { exec(q[opera http://www.perlmonks. +org/]) } elsif(defined $r) { say "hello!" }' hello!
which forks off a child process, and uses exec (so the child process doesn't hang around waiting for the browser process to end).

Comment on Re^3: Opening URL in instrumented browser
Select or Download Code

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1054631]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (6)
As of 2015-11-29 04:51 GMT
Find Nodes?
    Voting Booth?

    What would be the most significant thing to happen if a rope (or wire) tied the Earth and the Moon together?

    Results (746 votes), past polls