简体   繁体   中英

POST to php and return page with posted data

i have a download.php file and an index.php file. I want download.php to post data to index.php and then show index.php in the browser window with the posted data inside of it. Is this possible? I thought i could use curl for this but that isn't working. Please help me.

What is going wrong in your code ? You can use Curl.

Try this : http://www.askapache.com/php/sending-post-form-data-php-curl.html

You can do this using jQuery.post()

//post the data
$.post('ajax/test.html',{ name: "test", time: "2pm" }, function(data) {

    //replace the .result div with the
    //response from the server
    $('.result').html(data);

});      

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM