Giter VIP home page Giter VIP logo

Comments (1)

chopin2256 avatar chopin2256 commented on August 27, 2024

There is an error in my index file, but the library works correctly. Here is what you can do to fix the error:

Change:
$result .= $this->amazonLayout($i, $amazon);

To.

$result .= amazonLayout($i, $amazon);
Basically, I put a function called amazonLayout (its just a suggestion), and I called it incorrectly with the $this variable. The reason this is incorrect, is because $this only works on objects, and amazonLayout is simply a function, not within a class.
Date: Mon, 3 Feb 2014 12:42:15 -0800
From: [email protected]
To: [email protected]
Subject: [Amazon] Fatal error: Using $this when not in object context (#1)

Hello,

I'm very glad I found your library as I've been looking for exactly something like that to build an Amazon-based application for my website. Now, I'm trying to deploy your library on my server, but everything I get is a PHP warning which afaik is usually caused by calling a non-static method statically:

Fatal error: Using $this when not in object context in /home/some_dir/Amazon-master/index.php on line 28

Could you please push an working version of this library as I see it works just fine on your site.

Thanks in advance,

Alex


Reply to this email directly or view it on GitHub.

from amazon.

Related Issues (1)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.