0

How to hide file path when using anchor tag to open a pdf file?

asked 2014-12-14 14:49:47 +0800

bkstorm gravatar image bkstorm
38 3

I have a pdf file that is located at folder: webapp/file/test.pdf
Here is my zul file:

    <window title="new page title" border="normal">
    <a id="a" target="_blink" href="/file/test.pdf"
               image="/img/view.png">
    </a>
</window>

When I click on the image, browser will open the pdf file in a new tab, and URL will contains file path like that: localhost:8080/file/test.pdf
How can I hide /file/test.pdf in URL? Thanks.

delete flag offensive retag edit

4 Answers

Sort by ยป oldest newest most voted
0

answered 2014-12-14 16:13:09 +0800

Darksu gravatar image Darksu
1991 1 4

Hello bkstorm,

You could try using a Url Rewrite Filter. Please check the following:

http://tuckey.org/urlrewrite/

Best Regards,

Darksu

link publish delete flag offensive edit
0

answered 2014-12-14 23:01:06 +0800

bkstorm gravatar image bkstorm
38 3

OK, I'll try this and give you a result.

link publish delete flag offensive edit
0

answered 2016-11-23 16:16:23 +0800

kislay gravatar image kislay
1

hey i have a problem i am using wildfly 8.2 final and zkoss on java 1.8 i am using ... <image width="90px" height="90px" src="search1.png"> </image>

the page is loading but corresponding java controller is not working i am using doAfterCompose ()

link publish delete flag offensive edit
0

answered 2016-11-26 09:25:37 +0800

Darksu gravatar image Darksu
1991 1 4

Hello kislay,

Have you connected the view with the controller?

Please refer to the following:

https://www.zkoss.org/wiki/ZKDeveloper'sReference/MVC

Best Regards,

Darksu

link publish delete flag offensive edit
Your answer
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow
1 follower

RSS

Stats

Asked: 2014-12-14 14:49:47 +0800

Seen: 46 times

Last updated: Nov 26 '16

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More