And when Simon saw that through laying on of the apostles' hands the Holy Ghost was given, he offered them money,
Note 1 at Ac 8:18: Simon saw some kind of visible manifestation of the presence of the Holy Ghost. This passage does not explain what that visible expression was. There are three other accounts of people receiving the baptism of the Holy Ghost in the book of Acts (Ac 2:4, 10:44-46, and 19:6), and in each instance they spoke in tongues. This was probably the manifestation Simon saw that caused him to offer the apostles money so that he too could give the Holy Ghost to people.
Note 2 at Ac 8:18: It is interesting to note that Simon wanted the ability to give the Holy Ghost to whomever he wanted so much that he was willing to pay for that power. He had already continued with Philip and was amazed as he beheld the miracles and signs that Philip did (Ac 8:13), but he didn't ask for the power to do miracles. It is therefore quite an endorsement as to the power of the Holy Ghost that Simon coveted the power of the Holy Ghost more than the power to work miracles. He previously had power when he was using sorcery, but nothing like the power of the Holy Ghost.