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

  • SEARCH
  • Home
  • 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 5956823
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T18:18:46+00:00 2026-05-22T18:18:46+00:00

The scenario is as follows: There are two php pages named page1.php and page2.php.onClick

  • 0

The scenario is as follows: There are two php pages named page1.php and page2.php.onClick of a button in page3.php a ajax request is sent to page1.php. I have to redirect this request to page2.php where the processing takes places. Now I need to get the processed data in page1.php and convert it to json and send the json response to page3.php. So page1.php acts like an intermediate page for the communication between page3.php and page2.php.

If I use header(“Location:page2.php”) in page1.php then I cannot get the processed data from page2.php.(As I need the processed data in page1.php)
Please suggest how this can be done?

  • 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-05-22T18:18:47+00:00Added an answer on May 22, 2026 at 6:18 pm

    Can you not just require page2.php?

    What I mean is:

    page3.php  ->  AJAX request to page1.php
    page1.php  ->  $request = json_decode(AJAX request from page3.php)
                   require page2.php
    page2.php  ->  process $request
                   populate $response
    page1.php  ->  echo json_encode($response)
    page3.php  ->  AJAX response from page1.php
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

The scenario is as follows, I have 3 objects (i simplified the names) named
Ok so the usage scenario is as follows: I have a button that opens
im using sql server 2008. my scenario is as follows. there is a user
The scenario is as follows. My Order model has an after_create that contacts a
My scenario is as follows. I have 7 tabs (one for each day) using
The architecture for this scenario is as follows: I have a table of items
I've confused myself nicely here. My scenario is as follows: function DesignPad() { function
I have an sql scenario as follows which I have been trying to improve.
I have the following scenario. I have two methods of populating a GridView with
AFAIK, there are two ways of passing data to the view from controller :

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.