How can I use "open a File in new window" in drupal 7?

Comments

Devin Carlson’s picture

Assigned: rmwolinski » Unassigned
Status: Active » Closed (works as designed)

Add target="_blank" to the link.

Example: <a href="/sites/default/files/file_name.pdf" target="_blank">File</a>.

See the HTML Anchor Element page on the Mozilla Developer Network for more details.

rogical’s picture

Version: 7.0 » 7.9
Status: Closed (works as designed) » Active

just confused when display an image and set 'Link image to' file, how can I add 'target="_blank"'?

hack theme is not a good way, there should be a good way to end users for UX.

Version: 7.9 » 7.x-dev

Core issues are now filed against the dev versions where changes will be made. Document the specific release you are using in your issue comment. More information about choosing a version.