Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

just, not work #1

Closed
DaffyDuke opened this issue Dec 10, 2017 · 2 comments
Closed

just, not work #1

DaffyDuke opened this issue Dec 10, 2017 · 2 comments

Comments

@DaffyDuke
Copy link

Hello,
Perhaps my version of php is not supported yet ?
I got this error :

getlegos git:(master)  php getlegos.php 8939             
8939PHP Fatal error:  Uncaught Error: Call to undefined function curl_init() in /tmp/getlegos/getlegos.php:18
Stack trace:
#0 /tmp/getlegos/getlegos.php(36): url2json('https://www.leg...')
#1 /tmp/getlegos/getlegos.php(106): recupInfos('8939')
#2 /tmp/getlegos/getlegos.php(115): moulinette('8939')
#3 {main}
  thrown in /tmp/getlegos/getlegos.php on line 18

If it should help, url in code is https://www.lego.com//service/biservice/search\?fromIndex\=0\&locale\=fr-FR\&onlyAlternatives\=false\&prefixText\= but it looks like real one should be something like https://www.lego.com/fr-fr/service/buildinginstructions/search\#\?search\&text\=8939%2520Lesovikk%2520Bionicle

If it should helps :

getlegos git:(master)  php -v
PHP 7.1.11-0ubuntu0.17.10.1 (cli) (built: Nov  1 2017 16:30:52) ( NTS )
Copyright (c) 1997-2017 The PHP Group
Zend Engine v3.1.0, Copyright (c) 1998-2017 Zend Technologies
    with Zend OPcache v7.1.11-0ubuntu0.17.10.1, Copyright (c) 1999-2017, by Zend Technologies

@nicolaswurtz
Copy link
Owner

Hi !
You're missing "php-curl" extension and you need to install it.
If you are using debian/ubuntu, it's very easy :
apt install php-curl
And then, restart the web server, it should works fine !

@DaffyDuke
Copy link
Author

Hi, yep, thank you, it worked fine, a quick update to INSTALL.md ? :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants