Git Product home page Git Product logo

Comments (4)

benjamminf avatar benjamminf commented on August 21, 2024

Hey @darylknight thanks for the report! From what I can tell, the EmbeddedAssetsService::parseUrl method is causing a server error for some reason. Since I'm wrapping a try/catch statement around most of that method, the only thing that could be causing a 500 error is the Essence PHP library. What version of PHP are you running? Essence requires minimum 5.5

from craft-embedded-assets.

benjamminf avatar benjamminf commented on August 21, 2024

If you add the following code inside the EmbeddedAssetsController class, this will let you inspect the server error:

protected $allowAnonymous = ['testUrl'];

public function actionTestUrl()
{
    $url = craft()->request->getQuery('url');
    $media = craft()->embeddedAssets->parseUrl($url);

    echo '<pre><code>';
    var_dump($media);
    echo '</code></pre>';

    exit;
}

Then visit yoursite.com/actions/embeddedAssets/testUrl?url=http://youtube.com... and see what happens

from craft-embedded-assets.

darylknight avatar darylknight commented on August 21, 2024

Hi Ben - thanks for getting back to me so fast. Your first instinct was right, I'd forgotten to crank up the PHP version on my staging server and it was running 5.4. Changed it to PHP 7 and everything's fine now. Thanks for a great plugin!

from craft-embedded-assets.

benjamminf avatar benjamminf commented on August 21, 2024

Ah awesome, it's usually never that simple! I'll add a check in the plugin for the PHP version so this doesn't catch anybody out again. Cheers! Ben.

from craft-embedded-assets.

Related Issues (20)

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.