0
manojreddy created
I am calling an API from Angular UI which uploads the image to the server to a physical path like ....../xyz/abc/pqr.png. Now I want to access this image from Angular UI like the following way.
<img src="url">
url will be something like <a class="postlink" href="http://1.2.3.4:80/xyz/abc/pqr">http://1.2.3.4:80/xyz/abc/pqr</a>
2 Answer(s)
-
0
Any updates??
-
0
define a variable in your ts file;
remoteServiceBaseUrl: string = AppConsts.remoteServiceBaseUrl;
and in your html file;
<img [src]="remoteServiceBaseUrl + '/xyz/abc/pqr.png'" >