Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9053661
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T13:28:53+00:00 2026-06-16T13:28:53+00:00

How to open the PDF file using AJAX I tried this $.ajax({ type :

  • 0

How to open the PDF file using AJAX
I tried this

$.ajax({

          type : 'GET',
          url : ApplicationParameters.getWebRoot() + 'E_Books/pdf/previews/' + jsonRecord[0].previewUrl,
          data : strJsonParam,
          dataType : 'text',
          contentType : 'application/pdf',

          success: function(data){
          var opn = open("/E_Books/pdf/previews/"+jsonRecord[0].previewUrl);
          displayBook(opn);
          ebookStore.add(opn);
          ebookStore.sync();
    }
    ...

it open pdf file but I want open that in same window.it open in another window.
help please

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T13:28:54+00:00Added an answer on June 16, 2026 at 1:28 pm

    Replace your code with this:

                type : 'GET',
                url : ApplicationParameters.getWebRoot() + 'E_Books/pdf/previews/' + jsonRecord[0].previewUrl,
                data : strJsonParam,
                dataType : 'text',
                contentType : 'application/pdf',
    
                success: function(data){
                var opn = open("/E_Books/pdf/previews/"+jsonRecord[0].previewUrl, "_self");
                        displayBook(opn);
                        ebookStore.add(opn);
                        ebookStore.sync();
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

My question is similar to Download and open pdf file using Ajax But not
I want to open pdf file using installed adobe reader. I tried in the
I have tried to open a PDF file from the local disk. For example
I have for example .pdf file (path to that file). How to open this
I want open pdf file directly without asking open,save options(prompt window).In this temppath is
I'm using link tag to open a pdf file. when clicking that link, the
Using iText, I am wanting to open a PDF file, add some more pages
In my ASP.NET application,When I try to open PDF file by using the below
How can I open a PDF file that was stored in my iPad/iPhone, using
I wan't to open a pdf file on Xcode using phone gap[corodova 1.7.0]. Is

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.