bem, o seguinte parece funcionar. Graças a @tso
#!/bin/bash
var1=$1
url="http://www.google.com/"
# maybe use a for loop here??
# Okay now if I use getopts - @Hannu
while getopts ":p:e:" o; do
case "${o}" in
p)
page+=("$OPTARG")
;;
e)
extension+=("$OPTARG")
;;
esac
done
shift $((OPTIND -1))
for ((i=0;i<${#extension[@]};++i));
do
echo "URL is www.google.com/${page[i]}.${extension[i]}"
done