@darkwolf687 I just wanna let you know the Dutch country,
my country, held a referendum on the association treaty with that beautiful country called Ukraine.
You know,
these guys, and
these people.
Same referendum set up, where it was only an advisory referendum. We 'won' aka my side that was against the treaty won with 60% to 30% or so.
However the legally binding aspect came from the fact that leading parties said they'd use the referendum and 'consider it binding' despite being against referendums in general. (They said that, yes, indeed, they are against democratic referendums) Naturally they hoped people would vote FOR the treaty. They didn't, and now they're backtracking and trying to find a way to pull the treaty through without seeming corrupt (and they're failing hard at that.)
Despite the advisory role of referendums, they are sort of legally binding unless you want to lose all political support you have.
David Cameron resigned because he doesn't want to be associated with this referendum, mostly cause his side lost, otherwise because if the results of the referendum turn out to be a bad move, he has a good shot at being chosen again. In the end though the referendum won't matter, because this is who leads the EU:
Europa über Alles, nicht?