assuming "cat" is the pattern, string (regardless length)
asdadfcat4
I need to get 4
for eirtrjkkkcat678- I'd get 678
(in b-shell)
Thanks in advance!!! (4 Replies)
This is my first post, please be nice. I have tried to google and read different tutorials.
The task at hand is:
Input file input.txt (example)
abc123defhij-E-1234jslo
456ujs-W-abXjklp
From this file the task is to grep the -E- and -W- strings that are unique and write a new file... (5 Replies)
Hello,
let's start by giving you guys a few examples of the text:
"READ /TEXT123/ABC123"
"READ /TEXT123/ABC123/"
"READ TEXT123/ABC123"
"READ TEXT123/ABC123/"
"READ TEXT123/TEXT456/ABC123"
"READ /TEXT123/TEXT456/ABC123"
"READ /TEXT123/TEXT456/ABC123/"
TEXT and ABC can be and I... (5 Replies)
Hi
I have a piece of xml that has a pattern like this
<int>159</int><int>30</int>
I want to find this pattern but only substitute the second part of the pattern to {rid1}.
Is that possible in sed ?
Thanks.
---------- Post updated at 12:10 PM ---------- Previous update was at 12:01 PM... (11 Replies)
nautilus is not remembering my settings. I have done everything I can think of to get this to work. I have deleted .gconf, .gconfd, and .gnome2. I tried to start over fresh and that did not work either. What else can I do? (4 Replies)
Hi,
I have two files file1.txt and file2.txt. Please see the attachments.
In file2.txt (which actually is a diff output between two versions of file1.txt.), I extract the pattern corresponding to 1172c1172. Now ,In file1.txt I have to search for this pattern 1172c1172 and if found, I have to... (9 Replies)
I read about this guy who always had difficulty remembering his password so he changed his password to "incorrect".
Now when he tries to log in and it fails the system tells him "your password is incorrect". (2 Replies)
'Hi
I'm using the following code to extract the lines(and redirect them to a txt file) after the pattern match. But the output is inclusive of the line with pattern match.
Which option is to be used to exclude the line containing the pattern?
sed -n '/Conn.*User/,$p' > consumers.txt (11 Replies)
The intended result should be :
PDF converters
'empty line'
gpdftext and pdftotext?xml version="1.0"?>
xml:space="preserve"><note-content version="0.1" xmlns:/tomboy/link" xmlns:size="http://beatniksoftware.com/tomboy/size">PDF converters
gpdftext and pdftotext</note-content>... (9 Replies)
I have a file like below.
2018.07.01, Sunday
09:27 some text 123456789 0 21 0.06 0.07 0.00
2018.07.02, Monday
09:31 some text 123456789 1 41 0.26 0.32 0.00
09:39 some text 456789012 1 0.07 0.09 0.09
09:45 some text 932469494 1 55 0.29 0.36 0.00
16:49 some text 123456789 0 48 0.12 0.15 0.00... (9 Replies)
Discussion started by: father_7
9 Replies
LEARN ABOUT PHP
domnode
DOMNODE(3) 1 DOMNODE(3)The DOMNode classCLASS SYNOPSIS
DOMNode
DOMNode
Properties
o publicreadonly string$nodeName
o public string$nodeValue
o publicreadonly int$nodeType
o publicreadonly DOMNode$parentNode
o publicreadonly DOMNodeList$childNodes
o publicreadonly DOMNode$firstChild
o publicreadonly DOMNode$lastChild
o publicreadonly DOMNode$previousSibling
o publicreadonly DOMNode$nextSibling
o publicreadonly DOMNamedNodeMap$attributes
o publicreadonly DOMDocument$ownerDocument
o publicreadonly string$namespaceURI
o public string$prefix
o publicreadonly string$localName
o publicreadonly string$baseURI
o publicreadonly string$textContent
Methods
o public DOMNode DOMNode::appendChild (DOMNode $newnode)
o public string DOMNode::C14N ([bool $exclusive], [bool $with_comments], [array $xpath], [array $ns_prefixes])
o public int DOMNode::C14NFile (string $uri, [bool $exclusive], [bool $with_comments], [array $xpath], [array $ns_prefixes])
o public DOMNode DOMNode::cloneNode ([bool $deep])
o public int DOMNode::getLineNo (void )
o public string DOMNode::getNodePath (void )
o public bool DOMNode::hasAttributes (void )
o public bool DOMNode::hasChildNodes (void )
o public DOMNode DOMNode::insertBefore (DOMNode $newnode, [DOMNode $refnode])
o public bool DOMNode::isDefaultNamespace (string $namespaceURI)
o public bool DOMNode::isSameNode (DOMNode $node)
o public bool DOMNode::isSupported (string $feature, string $version)
o public string DOMNode::lookupNamespaceURI (string $prefix)
o public string DOMNode::lookupPrefix (string $namespaceURI)
o public void DOMNode::normalize (void )
o public DOMNode DOMNode::removeChild (DOMNode $oldnode)
o public DOMNode DOMNode::replaceChild (DOMNode $newnode, DOMNode $oldnode)
PROPERTIES
o $nodeName
-Returns the most accurate name for the current node type
o $nodeValue
-The value of this node, depending on its type
o $nodeType
-Gets the type of the node. One of the predefined XML_xxx_NODE constants
o $parentNode
-The parent of this node. If there is no such node, this returns NULL.
o $childNodes
- A DOMNodeList that contains all children of this node. If there are no children, this is an empty DOMNodeList.
o $firstChild
- The first child of this node. If there is no such node, this returns NULL.
o $lastChild
-The last child of this node. If there is no such node, this returns NULL.
o $previousSibling
- The node immediately preceding this node. If there is no such node, this returns NULL.
o $nextSibling
- The node immediately following this node. If there is no such node, this returns NULL.
o $attributes
- A DOMNamedNodeMap containing the attributes of this node (if it is a DOMElement) or NULL otherwise.
o $ownerDocument
-The DOMDocument object associated with this node.
o $namespaceURI
-The namespace URI of this node, or NULL if it is unspecified.
o $prefix
-The namespace prefix of this node, or NULL if it is unspecified.
o $localName
-Returns the local part of the qualified name of this node.
o $baseURI
- The absolute base URI of this node or NULL if the implementation wasn't able to obtain an absolute URI.
o $textContent
-This attribute returns the text content of this node and its descendants.
NOTES
Note
The DOM extension uses UTF-8 encoding. Use utf8_encode(3) and utf8_decode(3) to work with texts in ISO-8859-1 encoding or Iconv for
other encodings.
SEE ALSO
oW3C specification of Node
PHP Documentation Group DOMNODE(3)