It is enough to store just user login (or user id) in the session.
To prevent session fixation/hijacking everything you need is just to implement simple algorythm (pseudocode):
if (!isset($_SESSION['hash']) {
$_SESSION['hash'] = md5(!empty($_SERVER['HTTP_USER_AGENT']) ? $_SERVER['HTTP_USER_...
i was crying because I could not explain why the article is dummy
"@z - Stop ordering me to look at the code you provided. Of course I am looking at it, which is why we are having this conversation. But, you have finally provided a straight answer to my question, so you win. "
omg
"Stop ordering me to look at the code you provided" - is not it a little rude?
i've given him a great sample. the only thing he need to do - is to be polite and say thanks
That's ok, I gave a link to the exact resources an author needed yesterday and I had someone with 11k rep argue me that I didn't give code, that I gave the downloads to the microsoft samples which covered how to do what the author wanted and many more examples
so after 18 hours of arguing with mr 11k, I deleted my answer and went on with my life. I learned because I downloaded the samples and played with the code to learn, so I think others would learn well the same way, no?
I also love that on this question the guy is arguing that I am encouraging him to use a bad tool, when it's already built in and works well with little for him to consider stackoverflow.com/questions/4175266/… :\
"oh, they store way more information than I need!! boohoo for me"
I know that Microsoft spent time and effort to make it an easily extensible (by fields, not function, see the Profile) and fairly dynamic and easily adaptable membership system. I'm not sure why people feel the need to reinvent the wheel. Unless they're in the business of selling User Membership controls
My vote goes for most people optimize what they think is the weak point, but they don't profile.
So regardless of how well you know algorithms and regardless of how well you've written your code, you don't know what else is happening outside your module. What do the APIs you've called do behind ...
Yeah I'm really really curious about that language
I think it's a TSQL variant for sure, but I couldn't dig up any answers from google last night, nor wikipedia, and as we all know, no syntax on searches
Malbolge is a public domain esoteric programming language invented by Ben Olmstead in 1998, named after the eighth circle of hell in Dante's Inferno, the Malebolge.
The peculiarity of Malbolge is that it was designed to be the most difficult and esoteric programming language. However, several of the tricks used to make understanding it difficult can be simplified away.
Programming in Malbolge
Malbolge was so difficult to understand when it arrived that it took two years for the first Malbolge program to appear. The program was not even written by a human being: it was generated by a be...
Yeah, I've noticed if I answer a question someone with more rep than me asked, and someone with more rep comes in after me and gives the same answer they often get the check.
The ability to put a bounty on someone else's question, spending only a fraction of the reputation it would normally take.
For example, when you saw a question that you really wanted to help, you could spend 50 of your own reputation to give that question a +250 point bounty.
This would allow 2...
@mootinator see my concerns on inflation ;)
@mootinator DO SHARE!!! I wanna know
for anyone who thinks they can help @tina with her UML modeling on her three packages, you should also be encouraged to visit her other questions (found on her profile page).
True, but given this: INSERT INTO emp(empno, ename, deptno) VALUES(:x, :y, :z); it could be some library based on it. It would make sense for someone to extend it with precompiler looking # aliases
I'm making an application that is similar to stackoverflow in that it has ratings for questions and answers and i also have tabs that show comments by oldest,newest and votes. Im having trouble sorting by votes.
Here is my function:
/**
*
* @param int $threadid
* @param string $...
Risotto is a class of Italian dishes of rice cooked in broth to a creamy consistency. The broth may be meat-based, fish-based, or vegetable-based; many kinds include parmesan cheese, butter, and onion. It is one of the most common ways of cooking rice in Italy.
Its origins are in northern Italy, specifically Eastern Piedmont, Western Lombardy, and the Veneto, where rice paddies are abundant. Risottos are made using short-grain rice (italian cultivars of Oryza sativa japonica), with the stock being added gradually while the rice is stirred constantly. The cooking technique leads the ri...
If God didn't want us to masturbate he would have made our arms shorter. Maybe that's why the T- Rex was always so angry. http://cl.ly/3FSe
but what's up with the multiple variations on each line? It's like it allows multiple variations on each parameter to be passed. I think each line is:
:#(declare parameter) [name of passed parameter] { // [name of passed parameter] }* { = [default value] } { in [parenthesis surrounded comma delimited list of valid values] } where {optional} and [plain English term] and (comment)
that seems rather tricky
it needs a frigging grammar just to explain what I think each part means, and I'm not in the mood to correctly define a grammar
the multiple optionals makes me say a grammar would be appropriate :p
@tina I don't know that will help ... I'm not sure I'm going to be able to help you that much. Do you know any professors of Computer Science you could talk to?
I'm binary uuids for keys. Is there any way to edit table data with Mysql Workbench for this kind of schema? I end up with:
UPDATE `db`.`table` SET `foo`='bar' WHERE `uuid`=?;
Which obviously returns an error:
ERROR 0: Value not set for all parameters
I have no other way to reference the ro...
@zerkms There are no U.S. federal alcohol laws, each of the 50 states has their own, some more modern than others...
"In 2010, a trial was initiated to test selling wine in grocery stores using vending machines. The buyer must present identification, look into a camera to allow an offsite PLCB employee to verify the identification, and blow into a breathalyzer to authorize the sale."
The pointy-haired boss (often abbreviated to just PHB) is Dilbert's boss in the Dilbert comic strip. He is notable for his micromanagement, gross incompetence and unawareness of his surroundings, yet somehow retains power in the workplace. In the Dilbert TV series, in which he is voiced by comedian Larry Miller, the character is notably smarter (although still quite stupid) and more actively evil.
The phrase "pointy-haired boss" has acquired a generic usage to refer to incompetent managers. It is also possible to speak of someone being pointy-haired or having pointy hair metaphorically,...