on 06-29-2005 1:54 PM
Hello,
I've created a phone book in DynPro.
I would like to extend this phone book by adding a picture next to each person. We have a network folder located at:
main-jr-fs1\Pics\ which contain all the workers pictures in jpeg. The name of the file is the User ID Number. My problem is how to bind the Image object source to the file, I can't simply put the path: "
main-jr-fs1\Pics\". At first I thought to upload the relevant image to a binary attribute in the Context and bind the Image to this Attribute but it looks like "source" accepts only String. Is there a solution to this? Meaning, can I bind jpg file to an application when the file is not added to the application excplicitly (Clearly I wont upload 4,000 images and deploy it with the app... )
Roy
Hi Roy,
Instead of copying the files to the default directory, you can create a folder as "RoyImages" in "C:\" and you can create HTTP alias in the visual adminstrator.
You can access the file using
http://<<hostname>>:portName/RoyImages/<<image file name>>
1. Copy of the image files to some location in the server (eg: c:\RoyImages)
2. Create a HTTP alias(eg. RoyImages) in the Visual Adminsitrator pointing to the file location (eg: c:\RoyImages).
3. Set the linkToURL reference property to http://<<servername>>:50000/RoyImages/<<Image file name>>
For creating the HTTP alias refer to the blog "Creating an HTTP Alias in WAS"
/people/renjith.andrews/blog/2005/03/31/creating-an-http-alias-in-was
Regards,
Santhosh.C
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi,
You can try this !
put your images in this path
\sap\<server instance name>\JC00\j2ee\cluster\server0\temp\webdynpro\web\sap.com\tcwddispwda\global\sapIcons
and u can then access it as ~sapIcons/<image name with extension>
Regards
Bharathwaj
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Wait, I thought to put it on the IIS and set the image the http:// URL but your idea sounds even better, this way the images will be "protected" from "outside" browsing. So I got where to put the images but I didn't figure out how to access it. Can you please explain me in more details how to get to this path from the code?
10X,
Roy
I did not mean to be harsh to you, sorry.
There are several possibilities:
- Put all these images into a Web Dynpro component and use the WDURLGenerator to create URLs that may be used as image source
- Put all these images anywhere where your application may access them and use these URLs for the image source.
I darkly remember that there is the possibility to create own alias names like "~sapicons" but I have to check it out first.
Ok, Valery knows where to do this, thanks.
Armin
Message was edited by: Armin Reichert
Hey Val,
Two questions:
1. Where do I find HTTP Server Settings on the Visual Administrator? I couldn't find it. I am using SP11 by the way.
2. After creating such an alias, does this mean that these pics will be available to anyone inside the LAN who browses to this URL? If yes, is there any way to prevent this and allow only applications that are running inside the portal context approach this directory? I can do the same on the IIS but one of the reasons I don't want to is because of that...
Roy
Message was edited by: Roy Cohen
It is here:
Root(SID)-> Server 0 (your-server-ID) -> Services -> HTTP Provider.
Open "Aliases" tab. Btw, I was wrong -- "~sapicons" alias implemented somehow different.
After creating an alias all content becomes publically available. Sadly, I don't know how to restrict access. Try to post this question on General WebAS forum.
VS
Hey I think I got it, I'll put Virtual directory on the IIS and refer to it dynamiclly. Am I right?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
70 | |
26 | |
9 | |
9 | |
7 | |
6 | |
4 | |
4 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.