All of these people saying "take a loan and you'll make money in the stock market" are wrong. You can't "make money" in stocks, from the perspective of choosing whether to take a loan, you can only "expect to make money". That's a huge difference.
And a number of experts say you shouldn't invest in stocks if you need the money in the next 5 years, so that's another strike against this advise.