11-20-2007
[Perl] Silent Input
I would like to use the WWW::Mechanize module to access a webpage that is password-protected. I was wondering if there was a way to make the input silent when asked from the script. For example:
What is your password: <password>
Where <password> is where you put your password, but is silent and cannot be seen.
Thanks.
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
I have been using the following code for sending out an email from a AIX UNIX platform.
cat filename | telnet mailhost 25 >/dev/null
Time to time I get a message
loopback: A specified file does not support the ioctl system call.
Can anyone tell me what this means? I need this function... (1 Reply)
Discussion started by: cgardiner
1 Replies
2. Shell Programming and Scripting
Hi,
i have just tried something in perl
#!/path/to/perl
print "login: ";
$login = <STDIN>;
print "\npassword: ";
$password = <STDIN>;
print "Username=$login\n";
print "Password=$password\n";
And it doesnt work, anyone know how i can get more than one line?
Cheers,
Elfyn (2 Replies)
Discussion started by: emcb
2 Replies
3. HP-UX
Hi,
I am connecting via SFTP to a remote Server. My problem is on trying to LOGin, I am asked for a password. I need to make this process automatic such that I can login without being prompted for a password.
I can achieve this if the remote server has a simple FTP server and not SFTP. How... (6 Replies)
Discussion started by: sgaucho
6 Replies
4. Linux
I want to run through wine the utorrent and I don't want the messages that are usually displayed in the console,
so I use the following command
wine utorrent.exe > /dev/null &
but it doesn't seem to work. Especially the redirection of the messages to the /dev/null doesn't work at all.
Do... (1 Reply)
Discussion started by: myle
1 Replies
5. Linux
Hi,
I am trying to do a silent installation of a JDk on a linux machine. Can anyone give me a command that would do it for me.
Thanx
Sundeep (2 Replies)
Discussion started by: eamani_sun
2 Replies
6. Shell Programming and Scripting
I run a background process using '&'. (see example below)
How can I suppress the '&' messages that are written to my console?? (lines 2 and 5)
Current Output...
1 > ak@LATU ~> ls &
2 > 4000
3 > ak@LATU ~>
4 > apps/ dl/ gems/ todo/ tst/ util/
5 > + Done ... (1 Reply)
Discussion started by: andy210
1 Replies
7. Shell Programming and Scripting
I need to process a file line-by-line using some value from a shell variable
Something like:perl -p -e 's/$shell_srch/$shell_replace/g' input.txt
I can't make the '-s' work in the '-p' or '-n' input loop (or couldn't find a syntaxis.)
I have searched and found... (4 Replies)
Discussion started by: alex_5161
4 Replies
8. Shell Programming and Scripting
Hi Experts,
I use perl telnet and ssh for normal tasks and health checks.
everything works fine but i would like to run scripts silently and print only data as i wish to.
by silent i mean.no banners /no prompts/ nothing.
I will format data before i print it on screen.
just formatted... (3 Replies)
Discussion started by: mtomar
3 Replies
9. Shell Programming and Scripting
Hello Experts,
I am learning perl. I know ksh/bash/csh...
In ksh I use to do this way... to read user input in silent mode so that nothing returns on the screen.
stty -echo
read -r pswd
stty echo
Please let me know the way in perl how to do it.
Here are my OS and Perl Details...
... (3 Replies)
Discussion started by: explorer007
3 Replies
10. Shell Programming and Scripting
ls | grep -E '^+$' | xargs --verbose -I{} rm -vfr "{}";
When i execute the command it works fine by removing the directories and its writing the output as below about which files are deleting.What i want know is,is there any XARGS command option that it should done silently in background with... (2 Replies)
Discussion started by: nareshreddy443
2 Replies
LEARN ABOUT DEBIAN
www::mechanize::image
WWW::Mechanize::Image(3pm) User Contributed Perl Documentation WWW::Mechanize::Image(3pm)
NAME
WWW::Mechanize::Image - Image object for WWW::Mechanize
SYNOPSIS
Image object to encapsulate all the stuff that Mech needs
Constructor
new()
Creates and returns a new "WWW::Mechanize::Image" object.
my $image = WWW::Mechanize::Image->new( {
url => $url,
base => $base,
tag => $tag,
name => $name, # From the INPUT tag
height => $height, # optional
width => $width, # optional
alt => $alt, # optional
} );
Accessors
$link->url()
URL from the link
$link->base()
Base URL to which the links are relative.
$link->name()
Name for the field from the NAME attribute, if any.
$link->tag()
Tag name (either "image" or "input")
$link->height()
Image height
$link->width()
Image width
$link->alt()
ALT attribute from the source tag, if any.
$link->URI()
Returns the URL as a URI::URL object.
$link->url_abs()
Returns the URL as an absolute URL string.
SEE ALSO
WWW::Mechanize and WWW::Mechanize::Link
COPYRIGHT & LICENSE
Copyright 2004-2010 Andy Lester.
This program is free software; you can redistribute it and/or modify it under the terms of either:
o the GNU General Public License as published by the Free Software Foundation; either version 1, or (at your option) any later version,
or
o the Artistic License version 2.0.
perl v5.14.2 2011-08-05 WWW::Mechanize::Image(3pm)