I'd like to know how can I create a menu like so:   Menu X which appears when a Member X performs a login, for example when a simple user login, a Menu with 4 sections appears but when a Member Y (for example a user as manager) performs a login, instead of Menu X (= simple user menu), this time a Menu Y (menu manager with 7 sections) appears.   any suggestions?
How can I add a Login link to the "Main navigation" menu?  When a user clicks on the link, it should take them to the /user/login page. Once they login, the link should change to say "Logout" instead of "Login".  Is there any way to add such a link?
Given $m$ rows with $n$ variables where $m &lt; n$, and given that there exists a combination of some of the rows that gives a zero vector. Is it promised when computing the reduced-row echelon form, with Gaussian elimination to find a zero vector?  Update: I clearly don't know, how to pick up the right words to ask my question. So let me give you the full context and please help me say it right, so the question will make sense. I am solving step 3 in the quadratic sieve algorithm, here is a  description of it.  Suppose the composite number N is being factored. Bound $B$ is chosen, and the factor base is identified (which is called $P$), the set of all primes less than or equal to $B$. Next, positive integers $z$ are sought such that $z_2$ mod $N$ is B-smooth. Therefore it can be written, for suitable exponents $a_i$, $${\displaystyle z^{2}{\text{ mod }}N=\prod _{p_{i}\in &gt; P}p_{i}^{a_{i}}}$$ When enough of these relations have been generated (it is generally sufficient that the number of relations be a few more than the size of P), the methods of linear algebra can be used (for example, Gaussian elimination) to multiply together these various relations in such a way that the exponents of the primes on the right-hand side are all even: $${\displaystyle {z_{1}^{2}z_{2}^{2}\cdots z_{k}^{2}\equiv \prod &gt; _{p_{i}\in P}p_{i}^{a_{i,1}+a_{i,2}+\cdots +a_{i,k}}\ {\pmod {N}}\quad ({\text{where }}a_{i,1}+a_{i,2}+\cdots +a_{i,k}\equiv 0{\pmod &gt; {2}})}}$$  Now, let's say I found $m$ relations and the number of primes in $P$ is $n$, such that $m&lt;n$. It is given that there exists a combination of some of the $m$ relations that their product is a square number. My question is: When I perform the Gaussian elimination over F2 to find a null space combination, is it promised that I will find one? I successfully implemented the algorithm and the matrix part of my implementation works. But what I see is that if I found a null space(a combination of making a null space) and latter I add more relations(still $m &lt; n$), I lose the null space solution and not able to solve the matrix again. Each time I add a new relation I start solving it from the beginning, I don't remember any previous state. So what I want to know, could it be that there is a limitation with the Gaussian elimination algorithm, that it does not promise to find the null space if $m &lt; n$? Regular expression: match start or whitespace Can a regular expression match whitespace or the start of a string?  I'm trying to replace currency the abbreviation GBP with a £ symbol. I could just match anything starting GBP, but I'd like to be a bit more conservative, and look for certain delimiters around it.  &gt;&gt;&gt; import re &gt;&gt;&gt; text = u'GBP 5 Off when you spend GBP75.00'  &gt;&gt;&gt; re.sub(ur'GBP([\W\d])', ur'£\g&lt;1&gt;', text) # matches GBP with any prefix u'\xa3 5 Off when you spend \xa375.00'  &gt;&gt;&gt; re.sub(ur'^GBP([\W\d])', ur'£\g&lt;1&gt;', text) # matches at start only u'\xa3 5 Off when you spend GBP75.00'  &gt;&gt;&gt; re.sub(ur'(\W)GBP([\W\d])', ur'\g&lt;1&gt;£\g&lt;2&gt;', text) # matches whitespace prefix only u'GBP 5 Off when you spend \xa375.00'   Can I do both of the latter examples at the same time? How to terminate a script? I am aware of the die() command in PHP which exits a script early.  How can I do this in Python? A place where you could sit and see something like this (with a fall if you step further):    (Not looking for a technical term, just a common one). How do I root my Android device? Installing QGIS Statist plugin in Mac OS X? Why is super.super.method(); not allowed in Java? I read  and thought that would easily be solved (not that it isn't solvable without) if one could write:   @Override public String toString() {     return super.super.toString(); }   I'm not sure if it is useful in many cases, but I wonder why it isn't and if something like this exists in other languages.  What do you guys think?  EDIT: To clarify: yes I know, that's impossible in Java and I don't really miss it. This is nothing I expected to work and was surprised getting a compiler error. I just had the idea and like to discuss it. Is there a free site to play Yu-Gi-Oh? Fraleigh(7ed) Theorem33.12. Let $p$ be a prime and let $n\in\mathbb{Z}^+$. If $E$ and $E&#39;$ are fields of order $p^n$, then $E \simeq E&#39;$.   Proof in the text: Both $E$ and $E&#39;$ have $\mathbb{Z}_p$ as prime field, up to isomorphism. By Corollary 33.6(A finite extension $E$ of a finite field $F$ is a simple extension of $F$), $E$ is a simple extension of $\mathbb{Z}_p$ of degree $n$, so there exists an irreducible polynomial $f(x)$ of degree $n$ in $\mathbb{Z}_p[x]$ such that $E\simeq \mathbb{Z}_p[x]/ \langle f(x) \rangle$. Because the elements of $E$ are zeros of $x^{p^n}-x$, *we see that $f(x)$ is a factor of $x^{p^n}-x$ in $\mathbb{Z}_p[x]$*. Because $E&#39;$ also consists of zeros of  $x^{p^n}-x$, we see that $E&#39;$ also contains zeros of irreducible $f(x)$ in $\mathbb{Z}_p[x]$. Thus, because $E&#39;$ also contains exactly $p^n$ elements, $E&#39;$ is also isomorphic to $E\simeq \mathbb{Z}_p[x]/\langle f(x) \rangle$.  I don't know why $f(x)$ divides $x^{p^n}-x$. $E$ has a zero $\alpha$ of $f(x)$, but it doesn't need to have all the zeros of $f(x)$. So $f(x)=(x-\alpha)g(x)$ in $E[x]$ and $g(x)$ need not be splitted into linear factors. How can $f(x)$ divide $x^{p^n}-x$? Are there surface-mount pin header footprints for KiCAD? I'm designing a small module that breaks out a DIP SPI EEPROM to a 2x5 pin header socket(more info here: ). I want to mount the socket on the end of the board, with the pins lying parallel to the board.  I think two 5x1 surface-mount header footprints, on both sides of the board right near the end would do the job. Trouble is, KiCAD doesn't come with such a footprint(if it does, I haven't found it yet). Where might I find one? If one doesn't exist, that's OK; I'll have a shot at making my own. $\limsup$ and cluster points Let $(x_n)$ be a sequence in $\mathbb R$. We call $y$ a cluster point of $(x_n)$ iff for every neighborhood $N$ of $y$ there are infinitely many $n$ such that $x_n \in N$. Let $C$ denote the set of cluster points of $(x_n)$.   By definition, $\limsup_{n \to \infty} x_n = \inf_n \sup_{k \geq n} x_k$.  Can you show me how to prove $\limsup_n x_n = \sup C$? Thanks. (p → q) ∧ ¬p ⇒ ¬q  I have tried to use the rules of inference in many ways to prove this argument to be valid. However, I cannot seem to find a way to validate the argument, but I am afraid I have missed something.  Using a truth table I find that when p and q is 0, then p → q is 1, ¬p is 1 and ¬q is 1. Would that not make the argument valid?  I apologize in advance if I have misunderstood the whole concept. Any answer would be much appreciated. Thank you Moving from SQL 2005 [SQL_Latin1_General_CP1_CI_AS] to 2008 - will I lose any features by using 'backwards compatibility' We're moving from SQL 2005 [Instance and DB have collation of SQL_Latin1_General_CP1_CI_AS]  to SQL 2008 [which defaults to Latin1_General_CI_AS].  I completed a SQL 2008 R2 installation, and used default Latin1_General_CI_AS collation, with the restoration of the database still on SQL_Latin1_General_CP1_CI_AS. The excepted problems occurred - the #temp tables where in  Latin1_General_CI_AS whilst the db was in  SQL_Latin1_General_CP1_CI_AS and this is where I am now - I need advice on the pitfalls now please.  On installation of SQL 2008 R2, I have the option on installation to use 'SQL Collation, used for backwards compatibility' where I have the option to select the same collation as the 2005 database : SQL_Latin1_General_CP1_CI_AS.   This will allow me to not have problems with #temp tables, but are there pitfalls? Would I lose any functionality or features of any kind by not using a "current" collation of SQL 2008? What about when we move (e.g. in 2 years ) from 2008 to SQL 2012? Will I have problems then? Would I at some point be forced to go to Latin1_General_CI_AS? I read that some DBA's script complete the rows of complete databases, and then run the insert script into the database with the new collation - I'm very scared and wary of this - would you recommend doing this? Inversion in "only [adverb] have they" I'm having serious problems installing the Broadcom drivers for Ubuntu. It worked perfectly on my previous version, but now, it is impossible.   What are the steps to install Broadcom wireless drivers for a BCM43xx card?  I'm a user with no advance knowledge in Linux, so I would need clear explanations on how to make, compile, etc.    lspci -vnn | grep Network showed:   Broadcom Corporation BCM4322 802.11a/b/g/n Wireless LAN Controller [14e4:432b]      iwconfig showed:  lo        no wireless extensions. eth0      no wireless extensions.   NOTE: Answer below is updated every time new information is added and confirmed working. mysql_fetch_array, mysql_fetch_assoc, mysql_fetch_object In the radio series, how did Zaphod get into the artificial universe? In the book The Restaurant at the End of the Universe, it's very clearly explained how Zaphod gets into the simulated universe; he's in it from the moment he enters Zarniwop's office, and a big deal is made of him leaving via the window rather than the door so that he stays in it.  In the radio series, however, this doesn't happen. At the end of Fit the Seventh, Zaphod asks "How do we get to this universe, then?" and Roosta replies "I'm afraid it looks like we don't...", pointing out that the building is splitting down the middle, preventing them reaching the office.  Later, in Fit the Twelfth, Zaphod finally meets Zarniwoop in the lounge of the slightly-delayed spaceliner and reacts with astonishment at learning he's been in the artificial universe all this time. "How did we get into it? I mean like where, when?"  Zarniwoop only replies enigmatically: "You didn't notice? Well, I'll let you work it out for yourself."  So, how did he get in? As noted, he never actually entered Zarniwoop's office. My only thought is that it happened during the "body debit" incident with the disco, but there's no particular indication that that should be the case. Is there any other possibility? How do you force Chrome pages/tabs to crash using JavaScript? Trouble With Persistence After Making a USB Live Thumb Drive Using Pendrivelinux I created a bootable Ubuntu on my 32GB thumb drive (on a NTFS partition) and I selected a persistence of 4GB.  I've noticed that when I reboot from the initial booting off of the USB thumb drive, nothing is preserved.  No apps that were installed nor saved bookmarks.  Is there a way for me to manually force persistence? Below you find the design for our business cards. The triangles are yellow, as you can see outside of the canvas. However, inside the canvas, only when I set the Color Mode to CMYK, they appear pink. When I switch the Color Mode back to RGB, they appear yellow as expected. However, when I print them, in both cases they turn out pink...   I would just like to know what is going on here and how I can change them back to the right colors?  CMYK Colors: