Solved thread

This post is marked as solved. If you think the information contained on this thread must be part of the official documentation, please contribute submitting a pull request to its repository.

Trouble at the 2 tutorial

Hi, I start with phalcon, and I have an error that I do not understand during the tutorial 2 , I downloaded the zip (invo-master) but when I put it on my server:

(I use the last version of xampp, Windows 10x64)

Do you have any solutions?, thank you in advance

can you check the config file at app/config/config.php

'baseUri'        => preg_replace('/public([\/\\\\])index.php$/', '', $_SERVER["PHP_SELF"])
edited Mar '18

I'm guessing the URL prefix /invo-master is causing the problem.

Change it in your config.php to /

Or, your URI source is wrong:

// Use $_GET["_url"] (default)
$router->setUriSource(
    Router::URI_SOURCE_GET_URL
);

// Use $_SERVER["REQUEST_URI"]
$router->setUriSource(
    Router::URI_SOURCE_SERVER_REQUEST_URI
);

can you check the config file at app/config/config.php

'baseUri' => preg_replace('/public([\/\\])index.php$/', '', $_SERVER["PHP_SELF"])

I did what you told me, however in the example it's a config.ini file not config.php so I did this: http://www.image-heberg.fr/files/1522154898455791267.png

it works for the homepage but after not for this page: http://www.image-heberg.fr/files/15221549611912870556.png

http://www.image-heberg.fr/files/1522155064886438947.png

i try to modify that but i don't know very well the language so...



3.6k
Accepted
answer

can you check the config file at app/config/config.php

'baseUri' => preg_replace('/public([\/\\])index.php$/', '', $_SERVER["PHP_SELF"])

I did what you told me, however in the example it's a config.ini file not config.php so I did this: http://www.image-heberg.fr/files/1522154898455791267.png

it works for the homepage but after not for this page: http://www.image-heberg.fr/files/15221549611912870556.png

http://www.image-heberg.fr/files/1522155064886438947.png

i try to modify that but i don't know very well the language so...

try set (i personally don't like ini files)

baseUri = /invo-master/

can you check the config file at app/config/config.php

'baseUri' => preg_replace('/public([\/\\])index.php$/', '', $_SERVER["PHP_SELF"])

I did what you told me, however in the example it's a config.ini file not config.php so I did this: http://www.image-heberg.fr/files/1522154898455791267.png

it works for the homepage but after not for this page: http://www.image-heberg.fr/files/15221549611912870556.png

http://www.image-heberg.fr/files/1522155064886438947.png

i try to modify that but i don't know very well the language so...

try set (i personally don't like ini files)

baseUri = /invo-master/

It's working , thanks a lot ! It's weird I thought I tried but apparently no!