In the late 1800s, the townspeople of Phoenix were seeking a connection with the Southern Pacific's Sunset Route, which passed about 25 miles south of them. Once receiving authorization from Congress to build a railroad line through the Gila River Indian Reservation, the Maricopa and Phoenix Railroad commenced construction with mainly Mexican immigrants in 1886, completing the line in 1887. The line connected with the SP at a point called "Phoenix Junction", which is now the current town of Maricopa. The line contributed greatly to the growth of Phoenix in its early years.
This railroad was most likely abandoned in the early 1940s (at least before 1948, as a dated railroad map does not show this line). By the time it was abandoned, it was under control of the Arizona Eastern Railroad (itself a subsidiary of the Southern Pacific), and was known as the Maricopa Branch.
The exact routing of the M&P is not known; however it is believed that most of AZ Route 347 lies atop the former railbed. The unknown routing has also caused some dispute about the northern terminus of the M&P: while "Phoenix" forms part of the name of the railroad, and while most historians agree that the railroad did not reach as far north as Phoenix, there is disagreement on whether or not the railroad reached as far as Tempe, or if it terminated in West Chandler. One suspect in this debate is the Tempe to West Chandler spur of the Union Pacific (former SP). Its routing seems to align with where the M&P would have traveled, and so it is believed that this UP spur was once part of the M&P, meaning the northern terminus of the M&P was at Tempe. More evidence that suggests the northern terminus was in Tempe are some of the names that the railroad company went through during its history, namely the Phoenix, Tempe and Mesa Railway, and the Maricopa and Phoenix and Salt River Valley Railway. Detractors to this argument state that these names only indicate the intention of the railroad to reach those towns/areas, and not the actual destinations themselves.
So where exactly did the M&P lay its tracks? We may never know for sure.