Syllables (which are a unit of spoken language and nothing per se to do with punctuation or hyphenation) are generally considered to be governed by something called the Maximum Onset Principle, meaning that a syllable consists of a vowel at its centre or nucleus and at its two edges (the onset and coda) zero or more consonants, with the coda first filled with as many consonants as the language in question allows.
These are the principles of syllabification and you'll find a few corner cases. In English, for example, in a word such as "strengths", it might be argued that the final -s actually functions as a though it were a vowel, forming the nucleus of a syllable. In a word such as "university", which intuitively appears to have five syllables, in actual pronunciation it's not clear that the "i" really heads a syllable but might in fact get "merged" into the coda of the previous syllable. Within a language, different speakers can syllabify some sound combinations differently. For example, to most speakers from England, "film" consists of one syllable; to most speakers from Wales, it consists of two syllables. In Spanish, the word "atlas" is probably syllabified "at-las" by a speaker from Spain and "a-tlas" by a speaker from Mexico. But, barring these occasional corner cases, the principle I've just mentioned holds pretty much across languages and there's reasonable consistency and predictability in how speakers of a given language syllabify.
Then, loosely based on syllabification, are rules of hyphenation. Taking something close to "real" syllable divisions as a starting point, in various languages these are then are modified so as not to split up parts of a word that go together as a "unit", or to avoid "odd-looking" hyphenations. So in "university", one might avoid hyphenating as "u-niversity" as it looks a bit odd leaving one letter on its own and also splits up the unit "uni-". The rules might also take account of spelling phenomena which don't reflect pronunciation. So for example in English, there might be a rule to always place a hyphen between consecutive letters representing consonants even where phonologically there is no corresponding syllable break, e.g. im-mune (only one [m] is actually pronounced).
There's no God-given, universally agreed upon "rules" for hyphenation, but there are preferences of individual editors and style guide writers. And as I say, syllabification is more or less consistent, but not 100% so. So dictionary "syllabifications" will differ because (a) what they are giving may or may not be syllabification in the true sense; and (b) there's not necessarily a consensually agreed syllabification or hyphenation.
My recommended rules of hyphenation in English:
- Never hyphenate words. In 2011, what is the real need to hyphenate words?[*]
- If you absolutely absolutely must hyphenate: just leave the hyphen wherever your word processor puts it. There are more important things in life for you to worry about. (Of course, if you are writing the hyphenation algorithm of a word processor, then you need to care a little more, but that's about the only occasion I can think of.)
[*] If you're writing in a more agglutinative language like German or worse Finnish, where you get an average of about 2 words per line of A4, then I would posit that there is more of a case for hyphenation.