In an oriented tree, the parent is the previous node before the node of interest. The word parent can then be used in countless abstractions of computer science. The container of contained graphic or logic items can be called a parent. The inherited class in OOP can be called the parent.
Questions tagged [parent]
2914 questions
382
votes
14 answers
How may I reference the script tag that loaded the currently-executing script?
How can I reference the script element that loaded the javascript that is currently running?
Here's the situation. I have a "master" script being loaded high in the page, first thing under the HEAD tag.
geuis
337
votes
6 answers
How to find a parent with a known class in jQuery?
I have a
that has many other
s within it, each at a different nesting level. Rather than give every child
an identifier, I rather just give the root
the identifier. Here’s an example:
…

John Smith
- 8,567
- 13
- 51
- 74
246
votes
9 answers
How to call a parent method from child class in javascript?
I've spent the last couple of hours trying to find a solution to my problem but it seems to be hopeless.
Basically I need to know how to call a parent method from a child class.
All the stuff that I've tried so far ends up in either not working or…

YemSalat
- 19,986
- 13
- 44
- 51
234
votes
4 answers
super() fails with error: TypeError "argument 1 must be type, not classobj" when parent does not inherit from object
I get some error that I can't figure out. Any clue what is wrong with my sample code?
class B:
def meth(self, arg):
print arg
class C(B):
def meth(self, arg):
super(C, self).meth(arg)
print C().meth(1)
I got the sample…

Ehsan Foroughi
- 3,010
- 2
- 18
- 20
214
votes
11 answers
Changing the child element's CSS when the parent is hovered
First of all, I'm assuming this is too complex for CSS3, but if there's a solution in there somewhere, I'd love to go with that instead.
The HTML is pretty straightforward.
Text Block 1
…

Hartley Brody
- 8,669
- 14
- 37
- 48
189
votes
16 answers
How can I return to a parent activity correctly?
I have 2 activities (A and B) in my android application and I use an intent to get from activity A to activity B. The use of parent_activity is enabled:

ashiaka
- 3,994
- 8
- 32
- 45
159
votes
13 answers
How do I get the n-th level parent of an element in jQuery?
When I want to get, for example, the 3rd level parent of the element I must write $('#element').parent().parent().parent() Is there a more optimal method for this?

Artur Keyan
- 7,643
- 12
- 52
- 65
158
votes
9 answers
Make div (height) occupy parent remaining height
Consider the following HTML/css code sample:
#container { width: 300px; height: 300px; border:1px solid…
Text
Text
Text
Text
Text
Text
Text
Text
Text
Text

Alvaro
- 9,247
- 8
- 49
- 76
152
votes
8 answers
Select parent element of known element in Selenium
I have a certain element that I can select with Selenium 1.
Unfortunately I need to click the parent element to get the desired behaviour. The element I can easily locate has attribute unselectable, making it dead for clicking. How do I navigate…

f l
- 1,684
- 2
- 10
- 11
109
votes
5 answers
100
votes
7 answers
How to get parent process in .NET in managed way
I was looking a lot for method to get parent process in .NET, but found only P/Invoke way.

abatishchev
- 98,240
- 88
- 296
- 433
83
votes
2 answers
jQuery: get parent tr for selected radio button
I have the following HTML:
....
… |