Wrox Programmer Forums
Go Back   Wrox Programmer Forums > PHP/MySQL > Beginning PHP
Beginning PHP Beginning-level PHP discussions. More advanced coders should post to the Pro PHP forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Beginning PHP section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
Old November 21st, 2004, 11:22 AM
Registered User
Join Date: Nov 2004
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default http_client.php shopping cart error

I am using a php based shopping cart. For some reason when I set up and account in the program, and try to check out I get this looping error.

Warning: feof(): supplied resource is not a valid stream resource in /includes/classes/http_client.php on line 374

Warning: fgets(): supplied resource is not a valid stream resource in /includes/classes/http_client.php on line 375

The funny thing about this is that this is Oscommerce based program. I have tried 3 different flavors of this program, and I keep running into the same error on all different programs. I can not get anybody to respond to me.
Here is the code information in question.

 * processHeader() reads header lines from socket until the line equals $lastLine
 * @scope protected
 * @return array of headers with header names as keys and header content as values
    function processHeader($lastLine = "\r\n") {
      $headers = array();
      $finished = false;

      while ( (!$finished) && (!feof($this->socket)) ) {
        $str = fgets($this->socket, 1024);
        $finished = ($str == $lastLine);
        if (!$finished) {
          list($hdr, $value) = split(': ', $str, 2);

Can you help me? I have searched all over the net for answers.

Similar Threads
Thread Thread Starter Forum Replies Last Post
error in shoppingcartbox (shopping cart in right ) gujju BOOK: ASP.NET 2.0 Website Programming Problem Design Solution ISBN: 978-0-7645-8464-0 0 December 12th, 2007 08:47 PM
Shopping Cart Error wdarnellg BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 0 October 23rd, 2007 11:04 AM
Free php shopping cart heerajee Pro PHP 1 April 20th, 2006 02:32 PM
shopping cart in php isheikh PHP How-To 1 October 22nd, 2004 08:17 PM
PHP Source Code for Shopping cart haribabu PHP How-To 0 January 27th, 2004 02:10 AM

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.