Hi
I'm using a macro where i need to have Current URL.
How to get hte current URL in the velocity file. It would be good if get it with out usign javacript/jquery.
Using $req.getRequetURI will provide the current URL with out any query String parameters.
If we need query String parameters too, we have to use $req.getQueryString() method to written the query string too.
So using $req.getRequestURI and $req.getQueryString() will give us the current URL.
Alternatively,We can also get the current URL using the javascript methods.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.