Inelastic-x-ray-scattering measurements of the dynamic structure factor, S(q,), of electrons in Al both in the solid phase at rising temperatures and in the liquid are presented. The double-peak structure of S(q,) for qϾq c (q c ϭplasmon cutoff vector͒, diminishes gradually with decreasing strength of the ion-core potential; the peak position and the sloping plateau of the S(q,) spectra for qϾq c do not exhibit marked changes upon melting. The plasmon energy for qϽq c shifts according to the variation of the electron density upon heating and melting, and does not respond to the loss of long-range order. ͓S0163-1829͑98͒03201-9͔