Setting open permissions like this is usually the wrong thing to do. What leads you to believe it is the solution you want? What are you trying to do, what do you expect to happen, and what actually happens? Do you have Apache configured and running, or do you just want local access to the
xampp docs? Whatever the case, it seems as if setting permissions to 777 is a bit of a sledgehammer approach.
Beyond that, your
chmod syntax is incorrect:
chmod -R 777 /path
-R flag goes before the mode specification, not after it. It is also probably a capital
R and not a lower case
r (but I don't use Linux so don't take my word on that - look at the manpage to get all the gory details).