Chuck,
No they are not the same, although the plug is common which you probably already know. Looking at the back of the bulb, a 9007 should be Low, Ground, High from left to right. I don't remember the 9004 right now and I'm not at home, but you can check with a voltmeter/test light. You must have done some filing to fit the bulb? I thought they had small locating pins to prevent interchanging. They are different designs, so it probably will not perform properly. Look at the filaments of the bulbs if you want to see the differences. The 9004 filaments are cross-car, while the 9007 is longitudinal.
If you're looking for an upgrade, the 99 and later Sport lamps are pretty good. Hope this helps.