If your computer has a "sound card", more properly called an A/D converter; and if that converter has a preamp built in; and if you have recording software on your computer; then yes.
I plugged in my bass to my computer via my amplifier's headphone port to the line in port and now my computer will not detect anything from those ports such as my speakers or my bass.
Everything worked fine when I just did my bass directly to my line in port. Did I overload my computer?