Solved

How to Serve Images In Apache Over a portal url

Posted on 2014-03-15
3
307 Views
Last Modified: 2014-05-09
Hi Guru's,

Need some help. Here is my situtaion.

I have apache and Jboss on same machine with reverse proxy setup to serve images,css,js and other static files and the url I use to access is.

http://jboss_Apache_Machine_host_IP:80/myappcontext/myappname/Home
Example:
http://10.106.11.192/myappcontext/myappname/Home

Now while using this url for enabling SSO(I think its Oracle webcenter or radiant one sso) the SSO admin adds the above mentioned url to the portal as a hyper link. we login to portal and click on the link which gives us the logged in username and we let it get into the application. But here is the issue is the url changes when we access the application via portal's link. It becomes something like below:

http://portal_host_IP_address/portal/some_static_number/http%3B/myappcontext/userloginpage

Example: http://10.106.11.122/portal/server.pt/gateway/PTARGS_0_12018_4345_378/http%3B/10.106.11.192/myappcontext/myappname/Home

Now the issue is all the images are referring a link like below and throws a 404 error when we access via portal as we serve images and css,js as alias and document root in apache.

http://portal_host_IP_address:80/myapp_images/login_banner.gif

note: Here myapp_images is the alias name we use in apache to serve images.

This throws a 404 error when accessed via portal, but if we access the same url without portal(direct url i.e :http://jboss_Apache_Machine_host_IP:80/myapp_images/login_banner.gif) its coming up fine but here the requirement is to serve everything via portal url only as people who are not in intranet network also shall be able to access.

Please suggest how do it do it to make it work via portal url i.e http://portal_host_IP_address:80/myapp_images/login_banner.gif
0
Comment
Question by:Ramakanta Sahoo
  • 2
3 Comments
 
LVL 29

Expert Comment

by:fibo
ID: 39951877
Item 1 on the checklist: are U sure that the URL written in your html / webapp are relative to the home page, and not complete http://?
Could you paste the jsp source code of one such link?
0
 
LVL 4

Accepted Solution

by:
Ramakanta Sahoo earned 0 total points
ID: 40040644
Currently we have changed our java code to dynamically serve images with the referred url.
0
 
LVL 4

Author Closing Comment

by:Ramakanta Sahoo
ID: 40053067
Had to do java code change for dynamically serve the images
0

Featured Post

Scale it in WD Gold

With up to ten times the workload capacity of desktop drives, WD Gold hard drives employ advanced technology to deliver among the best in reliability, capacity, power efficiency and performance.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
.htaccess mod_rewrite: page name gets repeated multiple times 2 63
java JDK Download 7 78
New OSQA server has a ton of fake users 4 55
Ways to assess https/ssl websites 3 87
Most of the developers using Tomcat find it easy to configure the datasource in Server.xml and use the JNDI name in the code to get the connection.  So the default connection pool using DBCP (or any other framework) is made available and the life go…
If you've heard about htaccess and it sounds like it does what you want, but you're not sure how it works... well, you're in the right place. Read on. Some Basics #1. It's a file and its filename is .htaccess (yes, with a dot in the front). #…
This is used to tweak the memory usage for your computer, it is used for servers more so than workstations but just be careful editing registry settings as it may cause irreversible results. I hold no responsibility for anything you do to the regist…
Many functions in Excel can make decisions. The most simple of these is the IF function: it returns a value depending on whether a condition you describe is true or false. Once you get the hang of using the IF function, you will find it easier to us…

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now