Sponsored Content
Top Forums Shell Programming and Scripting Finding a string inside A Tag Post 302443541 by dahlia84 on Monday 9th of August 2010 07:33:12 AM
Old 08-09-2010
Finding a string inside A Tag

I have umpteen number of files containing HTML A tags in the below format

Quote:
<a href="someurl.jsp?someparam&Login=$(someloginvalue)">
or

Quote:
<a href="someurl.jsp?Login=$(someloginvalue)">
I want to find all the lines that contain the word Login=

I used this command

Code:
grep "Login=" *

This gave me normal lines as well which contain the word Login= for example, it returned lines which have

Quote:
Login=AssignSomeValue;
this.Login=someValue;
How can I extract only those files which contain Login= in a A tag? Is it possible if yes, how can I do it?
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

finding text inside file

Hi everyone I have a small problem i cant find a soloution to... I'm using digital unix and have to find out all the files which have a certain string inside them and i dont know how to do it. *This search is done as root. *All files from '/' to the last directory should be searched for... (3 Replies)
Discussion started by: dindan100
3 Replies

2. Shell Programming and Scripting

Capturing string between a xml tag

Hi All, I have an XML-: <ProcId>CES_P5010_AddVLan</ProcId> <DataVersion>yxcxycyxcycyxc</DataVersion> <JobId>OR3000055-002-1</JobId> </CesHeader> <VLanServiceList> <NopId>blu</NopId> </VLanServiceList> <StatusNPA>2</StatusNPA> ... (5 Replies)
Discussion started by: amit_iti
5 Replies

3. Shell Programming and Scripting

Extract value inside <text> tag for a particular condition.

Hi All! I have obtained following output from a tool "pdftohtml" :: So, my input is as under: <text top="246" left="160" width="84" height="16" font="3">Business purpose</text> <text top="260" left="506" width="220" height="16" font="3">giving the right information and new insights... (3 Replies)
Discussion started by: parshant_bvcoe
3 Replies

4. UNIX for Dummies Questions & Answers

Finding files with a certain name string inside of another file.

Hi, I have a very large file that contains a listing of all files on the system. I need to create a listing from that file of all files that start with the following format: s???_*, whereas the '?' represents characters, so the file name begins with an 's' followed by three other characters and... (4 Replies)
Discussion started by: tes218
4 Replies

5. Shell Programming and Scripting

How to remove string inside html tag <a>

Does anybody know how i can remove string from <a> tag? There are several hundred posts in a few forums that need to be cleaned up. The precise situation is ---------- <a href="http://mydomain.com/cgi-bin/anyboard.cgi?fvp=/family/sexuality_and_spirituality/&cmd=rA&cG=43"> ------------- my... (6 Replies)
Discussion started by: georgi58
6 Replies

6. Programming

Deciphering a tag character string

I have a string, eg 7f30.3 and I want to store things in the following way npos = 7 decform = true width = 30 ndp = 3 I need to read each character one by one. I am coding in fortran but I can try to code it should answer be given in C in the above way. (2 Replies)
Discussion started by: kristinu
2 Replies

7. Shell Programming and Scripting

Extracting a string from html tag

Hi I am new to string extractions in shell script... I am trying to extract a string such as #1753 from html tag looks like below. <a class="model-link tl-tr" href="lastSuccessfulBuild/">Last successful build (#1753), 40 min ago</a> and want the value as 1753 Could someone help me to... (3 Replies)
Discussion started by: hicharbo
3 Replies

8. Shell Programming and Scripting

How can i find texts inside a html tag using sed?

How can i find texts inside a html tag using sed? Html texts: What i tried: cat infile | sed -e 's/\(<kbd*\)\(.*\)\(kbd>\)/\2/ Expected result like this: sed -i -e 's/@colophon/@@colophon/' \ -e 's/doc@cygnus.com/doc@@cygnus.com/' bfd/doc/bfd.texinfo (5 Replies)
Discussion started by: cola
5 Replies

9. Shell Programming and Scripting

How to check empty string in an XML tag?

I have an XML tag <abc> which is empty as <abc></abc>.If the the tag is empty I want to flag the file as bad. Please help. Thanks (3 Replies)
Discussion started by: aneeta13
3 Replies

10. Shell Programming and Scripting

awk to print string if tag is specific value

In the below awk I am trying to print expName only if another tag planExecuted is true. In addition to the expName I am also printing planShortID. For some reason the word experiment gets printed so I remove it with sed. I have attached the complete index.html as well as included a sample of it... (1 Reply)
Discussion started by: cmccabe
1 Replies
REPORTER-RHTSUPPORT(1)						 LIBREPORT MANUAL					    REPORTER-RHTSUPPORT(1)

NAME
reporter-rhtsupport - Reports problem to RHTSupport. SYNOPSIS
reporter-rhtsupport [-v] [-c CONFFILE] -d DIR Or: reporter-rhtsupport [-v] [-c CONFFILE] [-d DIR] -t[ID] FILE... DESCRIPTION
The tool reads problem directory DIR. Then it logs in to RHTSupport and creates a new case. The URL to new case is printed to stdout and recorded in reported_to element in DIR. If not specified, CONFFILE defaults to /etc/libreport/plugins/rhtsupport.conf. Option -t uploads FILEs to the already created case on RHTSupport site. The case ID is retrieved from directory specified by -d DIR. If problem data in DIR was never reported to RHTSupport, upload will fail. Option -tCASE uploads FILEs to the case CASE on RHTSupport site. -d DIR is ignored. Configuration file Configuration file lines should have PARAM = VALUE format. The parameters are: Login Login to RHTSupport account. Password Password to RHTSupport account. URL HTTP(S) address. (default: https://api.access.redhat.com/rs) SSLVerify Use yes/true/on/1 to verify server's SSL certificate. (default: yes) Parameters can be overridden via $RHTSupport_PARAM environment variables. Integration with ABRT events reporter-rhtsupport can be used as an ABRT reporter. Example fragment for /etc/libreport/report_event.conf: # Report Python crashes EVENT=report_RHTSupport analyzer=Python reporter-rhtsupport -d . -c /etc/libreport/plugins/rhtsupport.conf OPTIONS
-d DIR Path to problem directory. -c CONFFILE Path to configuration file. -t[ID] Upload FILEs to the already created case on RHTSupport site. SEE ALSO
abrt_event.conf LIBREPORT 2.1.11 06/18/2014 REPORTER-RHTSUPPORT(1)
All times are GMT -4. The time now is 02:05 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy