I have a lightweight online shopping site based on JSP and XML, and I'm wondering what the particular weaknesses of this system are as opposed to, say, PHP and MySQL?
JSP and PHP are both view technologies. JSP has the advantage of being backed by Java (EE) which is a strong language and platform. PHP has the advantage of being the easiest and most public adoptable web programming language ever. The disadvantages speaks for itself.
To develop a robust webapplication following the OO ideology, pick JSP (as long as you don't embed raw Java code in it the '90s way using scriptlets). If you're in a hurry and/or don't care about future maintainability and want to develop an e-commerce website in one day, then pick PHP.
XML and RDBMS are both ways to store data. RDBMS in turn, however, offers the ability to use SQL as language to select and manipulate specific data which can be done tremendously much more efficient than ever possible with XML.
Comparing JSP+XML with PHP+MySQL is a bit like comparing apples with oranges. XML however bites you much more as being a data store, so you would really prefer MySQL "in spite of" that it goes with PHP. You can however access databases as good with Java. To start, there you have the JDBC API for. All with all, I'd prefer JSP+SQL.
I know JSP can use Java APIs, but I feel PHP has a more "natural" relationship with HTML and also has the benefits of being dynamically typed, and is far more widespread and in-demand. Is there a reason for this?
It's the most easy to pickup by ones knowing absolutely nothing about programming. All you need to have is a simple webserver and a texteditor. It's very fast to develop with PHP as it has instant feedback and there are countless tutorials and code snippets available on the web. Further you have also much more choice of free PHP web hosting while you have to pay a bit more for a solid JSP/Servlet hosting.