grep substring between quotes
With GNU grep
, you can do:
$ echo 'title="2010-09-11 11:22:45Z"' | grep -oP 'title="\K[^"]+'
2010-09-11 11:22:45Z
grep -oP '[0-9-]{10} [0-9:]{8}' filename
If input would be in this format only then below command will easily solve your problem
echo "title=\"2010-09-11 11:22:45Z\"| cut -d '"' -f2