PHP Classes

File: index_webpage.php

Recommend this page to a friend!
  Classes of Evert Ulises German Soto   cURL Easy and Fast   index_webpage.php   Download  
File: index_webpage.php
Role: Example script
Content type: text/plain
Description: Retrieving and Save Request in File
Class: cURL Easy and Fast
Send HTTP request to remote servers using Curl
Author: By
Last change: the post fields are changed
Date: 11 years ago
Size: 482 bytes
 

Contents

Class file image Download
<?php
require("curl.class.php");

$options = array(
   
"url" => "http://localhost/wArLeY_cURL/process_page.php",
   
"data" => "web",
   
"data_filename" => "example_webpage.html",
   
"post" => "1",
   
"return_transfer" => "1",
   
"post_fields" => "nombre=Evert Ulises&apellidos=German Soto")
);

$obj = new wArLeY_cURL($options);
$resp = $obj->Execute();
echo
$obj->getError();

// You can redirect to open saved file or you can do anything...
header("location: ".$resp);
?>