I'm wondering if there's a technical writing term for when an author uses purposefully misspelled words to mimic the sound of the speaker? This has the effect of "forcing" the reader to hear the dialogue as it may sound to the writer.
An example would be a character who has, say, a cold or sinus infection whose dialogue might be written this way: "By doze has bid ruddeg all day log!" (Translation: "My nose has been running all day long!")
I've seen (generally fiction) writers employ this technique in dialogue. Is there a name for it?