• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 316
  • Last Modified:

Trying to open window with relative url using Javascript

Im wanting to use javascript to open a new window. The pdf file to be opened in the new window is in the directory "Doc" relative to the current directory. Should the following code work or am I doing something wrong?


1 Solution
Try this, instead:


You may not need the first slash before the Docs item, but definitely use a single forward slash between Docs and charing.pdf
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now