how come when i have like a video file, and i just add the extension at the end of the file, .divx, the file format turns to divx video. and when i put .avi at the end of the name, it turns the video file to avi? im getting a converter that turns things like avi to mp4 and such, but how come avi and divx switch like that?
Most programs don't care what the extension is named - it's the actual file that is checked. AVI is a 'container', as is OGG or VOB and it may contain video created by different codecs - the codec being a program that compresses the video in a particular fashion. The AVI container may consist of video compressed by DivX or XviD and changing the extension doesn't affect the content. Different containers offer different features - some support subtitles , etc.
...Changing a file extension doesn't essentially modify the document type. To reiterate attar's words, .divx is indeed one of the codecs used by .avi files. That explains why the data file isn't garbled despite the change in extension. Of course this isn't true for every file.