Forum for discussing general topics related to Couch.
7 posts Page 1 of 1
EDIT: Fixed it myself, however the only question I have now is why do my post pages have a .html extension? The PHP on the page loads, even though it says the page is html?

I have enabled prettyURL's in config.php by changing '0' to '1', generated the htaccess and placed in .htaccess on the server, however, pages cannot be found, such as portfolio.php ends up becoming portfolio/portfolio.php and gives a 404, however /portfolio/ loads it, how can i stop it from locating to /portfolio/portfolio.php ? Another issue is that the different posts load as .html pages instead of php pages, why is this? In this case this stops PHP from working on these pages such as footer.php.

Another problem is that when I'm on /portfolio/ and I click "Home", it tries to load /portfolio/index.php rather than index.php, how can I stop this?

Thank you.
It seems your your menu is using relative links e.g.
<a href="portfolio.php">Portfolio</a>

With prettyURLs on you visit the page as 'http://www.yoursite.com/porfolio/' but now the relative link contained on the page becomes
<a href="http://www.yoursite.com/porfolio/portfolio.php">Portfolio</a>

To remedy the situation, either -
a. Use absolute links e.g.
<a href="http://www.yoursite.com/portfolio.php">Portfolio</a>

b. or better still, use cms:link tag to output the right link e.g.
<a href="<cms:link masterpage='portfolio.php' />">Portfolio</a>

Please see http://www.couchcms.com/docs/tags-reference/link.html

As an aside, you might also notice that the JS and CSS links are wrong if you are using relative links with them. Again, you need to convert them to absolute links or use cms:link tag.
Please take a look at this part of our tutorial (scroll down to the PrettuURLs section) -
http://www.couchcms.com/docs/tutorials/ ... -ends.html

Hope this helps.
Thank you, that worked.

For some reason my page within /couch/snippets won't load Javascript, possibly due to not being able to find the .js file, however they are both within the main directory and it finds the stylesheet absolutely fine.

Both files in header.php are like so :

/css.css
/script.js

However it only finds /css.css, I know this isn't a problem with Couch, so thank you for your help on the pagelinks.
Ok, so it seems you managed to solve the problem while I was in the process of posting a solution :) Anyways, do take a look at the cms:link discussion in it.

Replying to your other query
why do my post pages have a .html extension? The PHP on the page loads, even though it says the page is html?

That is how pretyURLs work in Couch.
The templates look like folders e.g. 'potfolio.php' becomes '/portfolio/' while its cloned pages look like .html pages within the parent folder e.g. '/portfolio/somepage.html'.
The extension you see does not affect how the pages work internally i.e. PHP remains PHP internally and works just the same. So don't worry about PHP.

As for the CSS not working, please read my post above. It discusses why JS and CSS might fail with prettyURLs if you use relative paths.

Hope this helps.
KK wrote: Ok, so it seems you managed to solve the problem while I was in the process of posting a solution :) Anyways, do take a look at the cms:link discussion in it.

Replying to your other query
why do my post pages have a .html extension? The PHP on the page loads, even though it says the page is html?

That is how pretyURLs work in Couch.
The templates look like folders e.g. 'potfolio.php' becomes '/portfolio/' while its cloned pages look like .html pages within the parent folder e.g. '/portfolio/somepage.html'.
The extension you see does not affect how the pages work internally i.e. PHP remains PHP internally and works just the same. So don't worry about PHP.

As for the CSS not working, please read my post above. It discusses why JS and CSS might fail with prettyURLs if you use relative paths.

Hope this helps.


As long as they work, then that's great. I'll look into why my JS can't be found as I edited the post above. Thank you.

While you're active on this thread, I know it has probably been answered before in other posts, but I can't seem to find a direct answer from you.

Due to CouchCMS becoming opensource, are we allowed to completely remove "Powered by CouchCMS" from the website (Auto generated & put in the footer by myself), this isn't a problem for my personal website due to this being a great CMS, however some clients I work with don't appreciate it being in the footer, so in this case would they have to buy a license or is the license only for customising the admin page now?

And is there any plans in the future on having "yearly" and/or bi-yearly plans, rather than per-website? Such as £40/year gets x amount of extra features and custom admin pages, £80/year gets x amount more than tier 1? This would be great for us developers/designers to buy into rather than our clients having to pay more money for a license and be able to offer your product more often as well as giving money.
The open-source license (CPAL - as explained on http://www.couchcms.com/products/), mandates 'attribution' on the front-end as well as the back-end. You are free to turn off the auto-generated footer link if you wish to manually place an attribution link somewhere on the page.

The alternate commercial license allows you to remove the link completely and even use your company's link/name instead (white-labeling) but it costs $39/site.

As regards to the yearly fees you suggested, I've tried to keep the licensing simple and so it is just flat one-time $39.
I don't want to take names, but if you compare Couch to CMSes that cater to the same segment, you'll find that Couch costs less than half of what they charge.

Finally, I cannot resist saying this - I don't see anyone who uses Couch on a commercial project charge anything less than a $1000 atleast (please correct me if my understanding is wrong). Is $39 really that big a slice off that total?

Would like to have your thoughts :)
KK wrote: The open-source license (CPAL - as explained on http://www.couchcms.com/products/), mandates 'attribution' on the front-end as well as the back-end. You are free to turn off the auto-generated footer link if you wish to manually place an attribution link somewhere on the page.

The alternate commercial license allows you to remove the link completely and even use your company's link/name instead (white-labeling) but it costs $39/site.

As regards to the yearly fees you suggested, I've tried to keep the licensing simple and so it is just flat one-time $39.
I don't want to take names, but if you compare Couch to CMSes that cater to the same segment, you'll find that Couch costs less than half of what they charge.

Finally, I cannot resist saying this - I don't see anyone who uses Couch on a commercial project charge anything less than a $1000 atleast (please correct me if my understanding is wrong). Is $39 really that big a slice off that total?

Would like to have your thoughts :)


Well I've just recently had a client who wouldn't pay the extra $39 since they were certain "I could find something cheaper or create one myself", it was either lose the client, or take less money myself, obvously $39 isn't much to take out of my own pocket but when someone such as myself is just starting up, I'm charging as low as £150-£200 ($200-$250) for some work in order to get some local clients in order to get a name for myself. In the end I pretty much said take it or leave it, either have a small affiliate link in your footer or pay up, they went with the affiliate link of course.

I must thank you for all your work on Couch though, great CMS and great support. Thank you. :)
7 posts Page 1 of 1