redbaron76 / PongoCMS-Laravel-cms-bundle

a CMS bundle for Laravel 3.2 and Twitter Bootstrap 2.2.0
http://pongocms.com
Other
100 stars 32 forks source link

Where is the content? #21

Closed prawnsalad closed 11 years ago

prawnsalad commented 11 years ago

I've installed PongoCMS using the steps on the homepage - after fighting a few errors yesterday the bugs in master branch seems to have cleared up now.

I can access the CMS on /cms, but nothing is shown on the /home, /about-us or /blog pages? I haven't changed anything after installing the CMS so maybe I have missed something obvious?

Thanks

yovchev commented 11 years ago

// \bundles\cms\libraries\cmsutility.php on line 159
//  i think you need to cheek if isset before array_key_exists because is failing if you don't have segment 1

//if(array_key_exists($segments[1], Config::get('cms::settings.langs'))) {
if(isset($segments[1]) AND array_key_exists($segments[1], Config::get('cms::settings.langs'))) {
redbaron76 commented 11 years ago

Which platform / environment do you use?

Il giorno 04/feb/2013, alle ore 12:48, Darren notifications@github.com ha scritto:

I've installed PongoCMS using the steps on the homepage - after fighting a few errors yesterday the bugs in master branch seems to have cleared up now.

I can access the CMS on /cms, but nothing is shown on the /home, /about-us or /blog pages? I haven't changed anything after installing the CMS so maybe I have missed something obvious?

Thanks

— Reply to this email directly or view it on GitHub.

prawnsalad commented 11 years ago

Testing on OSX with PHP built in server. php -S 127.0.0.1:8000 -t public/

The pages /home, /about-us and /blog pages all return the default Laravel 404 page.

prawnsalad commented 11 years ago

Just to add to this.. working with a fresh install of PongoCMS.

If I set the url application config to 'index.php', then the defaut pongo pages work. However this does mean that no assets load.

redbaron76 commented 11 years ago

Could you please debug /cms/libraries/cmsrender.php ?

It must return the page object!

Then do the same with /about-us, /blog, etc.

Il giorno 05/feb/2013, alle ore 17:04, Darren notifications@github.com ha scritto:

Just to add to this.. working with a fresh install of PongoCMS.

If I set the url application config to 'index.php', then the defaut pongo pages work. However this does mean that no assets load.

— Reply to this email directly or view it on GitHub.

prawnsalad commented 11 years ago

https://github.com/redbaron76/PongoCMS-Laravel-cms-bundle/blob/master/libraries/cmsutility.php#L152

For me, this line returns a URL including the protocol and hostname. http://127.0.0.1:8000/blog/my-second-blog-post. If I change this line to just get the URI, ie. /blog/my-second-blog-post, then the default pages work. However, pagination in the blog leads to 404 pages (http://127.0.0.1:8000/blog?page=2). And no images are loading on the /about-us page as they are referring to a '/cms/' folder which does not exist.

Hope this helps!

prawnsalad commented 11 years ago

Just saw your reply. The debug line is not even reached as a 404 page loads. Making the temporary change mentioned in my previous reply does however show a page object.

redbaron76 commented 11 years ago

I think all this strange behaviour occurs because of the local PHP internal server... Don't you have MAMP or XAMP running just to test if it's because of it?

Never tested on local PHP internal server...

Il giorno 05/feb/2013, alle ore 18:09, Darren notifications@github.com ha scritto:

Just saw your reply. The debug line is not even reached as a 404 page loads. Making the temporary change mentioned in my previous reply does however show a page object.

— Reply to this email directly or view it on GitHub.

prawnsalad commented 11 years ago

Got it running under Apache on OSX now. No difference.

redbaron76 commented 11 years ago

Well... I just tested it on my local machine using PHP 5.4.4 internal server at port 8000... and it works correctly! Really don't know...

Please, zip your app you are working on (which doesn't work) and send it to me! f.fumis@gmail.com

I would like to test it by myself... Tnx

Il giorno 05/feb/2013, alle ore 18:41, Darren notifications@github.com ha scritto:

Got it running under Apache on OSX now. No difference.

— Reply to this email directly or view it on GitHub.

kurtfm commented 11 years ago

Same problem for me. Wondering if you figured out what this issues is.

kurtfm commented 11 years ago

Actually I figured mine out....

I had this in my application.php which worked for the default laravel install but not when using pongocms... 'url' => ''

I just updated it to use my localhost dev domain... all seems to work now.

ceri-richmond commented 11 years ago

Thanks @kurtfm - that worked for me too, added http://localhost:8888/public

@redbaron76 I didn't see this noted anywhere - I realise the need will be based on local set up but may be worth pointing out in the guide, had me stumped too.

Ceri

prawnsalad commented 11 years ago

Setting the url config is what solved my issue originally. It is noted on the homepage, pongocms.com but I had also missed it.

Probably a sign that it's not obvious enough yet, @redbaron76 :)