Some times for production systems, we need to have cleaner URLs, specially for APEX application in order to hide the details about the host or the parameters that are passed when we go from one page to another in an application.
This post is about giving a simpler way to do the same. I faced similar issue for one of out main production system where objective was to standardise our URLs. We have more then 20 applications running on same APEX installation having different application ID.
Here is what I did.
1) Check the document root of Apache
/slot/ems2154/oracle/product/Apache/Apache/Apache/htdocs in my case.
2) Suppose my APEX URL is some thing like this
and I want to make is some thing like
just for example I am using “test” as context root. In your case you can have any name. So when we hit this second URL (http://rws60106rems.us.oracle.com:7790/test), Apache will search for a file called test under document root (/slot/ems2154/oracle/product/Apache/Apache/Apache/htdocs).
So we can create a simple file in DocumentRoot location and name that file as test. Below should be the content of that file (in my case).
<html> <head> <title>Some Title</title> </head> <frameset rows="100%,*" border="0"> <frame src="http://your_host/pls/otn/f?p=xxxxx" frameborder="0" /> <frame frameborder="0" noresize /> </frameset> </html>
In your case you can change the src=<URL> accordingly. Bounce the Apache.
After that you can hit the URL http://rws60106rems.us.oracle.com:7790/test and it will work. Also it will not show any details about your application.
Hope this helps !!
4 thoughts on “Cleaner APEX URLs”
Good post, too bad I found it after weeks of trying.
We’ve done it the same way, the only snag – it works with IE, but not any other browser. We had to rename all our frames to test.html, because files with any other naming would just parse in the browser
I’ve tried it and it works fine but I’ve got a query. By adding the frame we lose the page title in the window title bar which could make life more difficult when communicating with users as it will be more difficult to find out which page they are in.
Any ideas or suggestions on how to workaround this?
OK, I answered my own question by aading this to the page template/s
window.parent.document.title = “#TITLE#”;