JQuery: selecting element with specific data-attribute's value?
jQuery attribute selector variable
Motivation: I once had one surplus card on my hand, and knew the robbers would come soon. So I gave it to someone for free, to avoid losing more cards when they hit. I was surprised by how badly this was received. Two of the three other players (the hosts of the game) acted upset, like I had tried to cheat. I had to take the card back, get robbed the next turn and 'giving cards away for free' was banned immediately. (Oh, how I hate mid-game additions to the rules. But that's beside the point.)  So now the question: Is this really illegal in Settlers of Catan? Is it generally considered underhanded in any way? If so, why?   My reasoning was like this:        Consider players A and B.   A wants to give B a sheep.   A trades a sheep and one rock to B, in exchange for wheat.   A trades the received wheat for the (formerly his) rock.   A and B now both have the same resources they had in the beginning, only the sheep has moved from A to B. This question is essentially the same as one of my , except the only difference is that I am using "only" to change the text at the same location (i.e., ). In other words, I am destroying my earlier text as I go, and not adding new ones underneath the previous ones.   Since the text for the first "only" is shorter than the second "only", therefore the image will shift location. I would like for the image to remain at its location.   Here is an example     it may not be obvious but the second image is higher up than the first.  The code is here, can someone find a solution?  \documentclass{beamer}  \usepackage{graphicx}  \title[Title]{Presentation} \author{Sandro Botticelli} \institute{Italy} \date{1484}  \begin{document}   \begin{frame} \begin{figure} \includegraphics[scale = 0.8]{Venus}     \caption{Nascita di Venere} \end{figure}  \only&lt;1&gt;{In the centre the newly-born goddess Venus stands nude in a giant scallop shell. Its size is purely imaginary, and is also found in classical depictions of the subject. }    \only&lt;2&gt;{Alternative identifications for the two secondary female figures involve those also found in the Primavera; the nymph held by Zephyr may be Chloris, a flower nymph he married in some versions of her story, and the figure on land may be Flora. Flora is generally the Roman equivalent of the Greek Chloris; in the Primavera Chloris is transformed into the figure of Flora next to her, following Ovid's Fasti, but it is hard to see that such a transformation is envisaged here.} \end{frame}   \end{document} After a very long time will we see more stars (due to the fact that more light is get to us) or less stars (as the universe expends and light have to pass larger distance)? In general, can stellar objects go outside of the scope of the observable universe or is it only growing with time? Calculations are always better than just discussion. Does it have any connection to dark matter? I'm given a inequality as such: $n! &gt; n^3$ Where n > 5,   I've done this so far:  BC: n = 6, 6! > 720 (Works)  IH: let n = k, we have that: $k! &gt; k^3$  IS: try n = k+1, (I'm told to only work from one side)  So I have (k+1)!, but I'm not sure where to go from here.  I've been told that writing out: $(k+1)! &gt; (k+1)^3$ is a fallacy, because I can't sub in k+1 into both sides, but rather prove from one side only.    Any Help on how to continue from here, would be much appreciated. Why Wi-Fi is getting turned-on automatically in iOS 11 A. These kinds of problem are to be avoided. B. These kind of problems are to be avoided.  Are both A and B grammatical? If not, why not? If so, after having noticed the parallelism between A and C, and between B and D, could we say that C and D are &quot;standard&quot; English, too?  C. These kinds of problem are ones to avoid. D. These kind of problems are ones to avoid. How to make X.org listen to remote connections on port 6000? This is on Ubuntu 10.10 (Maverick Meerkat) 64-bit desktop.  I want to make my X server listen to remote connections from clients in other machines on the local network. I know about ssh -X and that is not what I want. I vaguely remember changing something like TCPListen from no to yes, but I don't remember where this change should be applied.  I'm interested in either a GUI method or a CLI one.  PS editing /etc/X11/xinit/xserverrc to remove the -nolisten tcp option and rebooting does not work. I am planning to visit the UK on a USA travel document but there’s nowhere I am able to find information about visas: I’m a Zimbabwean but using a USA refugee travel document do I need to apply for a UK visa before I travel or I can they just give them on arrival. Facebook OAuth Data Capturing I'm reading the Algebra book by Knapp and he mentions in passing that an orthonormal set in an infinite dimension vector space is "never large enough" to be a vector-space basis (i.e. that every vector can be written as a finite sum of vectors from the basis; such bases do exist for infinite dimension vector spaces by virtue of the axiom of choice, but usually one works with orthonormal sets for which infinite sums yield all the elements of the vector space).  So my question is - how can we prove this claim? (That an orthonormal set in an infinite dimension vector space is not a vector space basis).    Edit (by Jonas Meyer): Knapp says in a footnote on  of Basic algebra:     In the infinite-dimensional theory the term "orthonormal basis" is used for an orthonormal set that spans $V$ when limits of finite sums are allowed, in addition to finite sums themselves; when $V$ is infinite-dimensional, an orthonormal basis is never large enough to be a vector-space basis.   Thus, without explicitly using the word, Knapp is referring only to complete infinite-dimensional inner product spaces. Detect init system using the shell how to create facebook event in an android app? Evaluating the integral $\int \frac{x^2+x}{(e^x+x+1)^2}dx$ tcolorbox manual tip box, how to clone? I would like to clone this box used on the tcolorbox manual, but I couldn't find the configuration in the manual.    Can you help me? I have been assigned this problem for homework:     Show that, if $a &lt; b + \epsilon$ for every  $\epsilon \gt 0$, then $a\le b$.   I have tried to go about this using Induction, but I don't know what the base case would be. It is obvious to me in my mind, but I don't know how to put it into mathematical terms on paper. any hints? What is the difference between linear regression on y with x and x with y? The Pearson correlation coefficient of x and y is the same, whether you compute pearson(x, y) or pearson(y, x). This suggests that doing a linear regression of y given x or x given y should be the same, but I don't think that's the case.   Can someone shed light on when the relationship is not symmetric, and how that relates to the Pearson correlation coefficient (which I always think of as summarizing the best fit line)? I am relatively new to Java, and often find that I need to sort a Map&lt;Key, Value&gt; on the values.  Since the values are not unique, I find myself converting the keySet into an array, and sorting that array through array sort with a custom comparator that sorts on the value associated with the key.  Is there an easier way? With Ubuntu One shut down, is there a way to sync applications between computers? Since Ubuntu one is no longer it appears that Sync between computers no longer works.  Is there a new method to do this?  I'd like to sync the apps from one machine to another. My friend installed Windows 7 on his computer (upgrading from XP).  He wasn't sure if his processor supported x64 or not, so he installed the x86 version, just to be on the safe side.  After I looked it up, it turns out his processor does support x64, and now we want to upgrade.  The question is: is it possible to upgrade without completely re-installing the OS?  Can I? Or do I have to format the C: partition again? As the title says. I use, among other things, the following in my lstset:  framerule=1pt, frame=tblr   Some places a page break happens in the middle of my \lstlisting. Fine. But sometimes the whole code of the listing appears on one page, but the bottom frame appears on the top of the next page!    I know that I can float a particular listing, but I have a long document with many listings, and I don't want to float all of them; Most of them also need to be exactly where they are declared. That they are broken over a page doesn't bother me that much.  Is there something that can stop this from happening, without me needing to adjust each individual listing?   had the same problem, but fixed it by removing spaces in front of keywords in a custom language definition. I too have a custom language definition, but his solution doesn't help me. I managed to recreate the situation without a custom language.  Edit and MWE  I managed to reproduce it in a minimal working example. 's a pastebin, if that's helpfull.  \documentclass[UKenglish,a4paper,11pt]{report} \usepackage{babel}  %% Adjustments \addtolength{\topmargin}{-1\baselineskip} \addtolength{\textheight}{4\baselineskip} \pretolerance = 2000 \tolerance = 5000   \hbadness = \tolerance  %% Smaller font \usepackage{mathptmx}  %% LISTINGS \usepackage[final]{listings} \lstset{     xleftmargin=1.5em,     framexleftmargin=1em,     framextopmargin=0.5ex, %%  THE FRAME:     framerule=1pt,     frame=tblr }  %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%  \usepackage{lipsum}     % for demo \begin{document} \subsubsection{Lorem}   % some fiddling to get the "wrong spacing just right": \lipsum[1-3] \subsubsection{Ipsum}  \lipsum[1] and then some text  \begin{lstlisting} Here is a listing with three lines of code; The bottom border is placed on the next page! \end{lstlisting}  Can you believe it..?! \end{document}   This MWE is rather long. My document inputs most of the listings stuff from files written by others, so I'm not sure what all of it does. If anyone sees some lines that they are sure is irrelevant, feel free to take it out of the MWE.  "Fun fact"  An equally silly situation occurs if you remove \usepackage{mathptmx}: The whole code listing will then appear on the new page, except for the top frame which is left on the bottom of the first page!