Problems, need help? Have a tip or advice? Post it here.
16 posts Page 1 of 2
Hi,

I'm just getting started with couch. I took the first steps as explained in the documentation. But when I added the code to my page this is shown on the bottom of it:

Fatal error: Undefined class name 'couch' in /homepages/45/d262021144/htdocs/.kte2/de/index.php on line 11


I copy-pasted the COUCH::invoke(); to my .php file. So I assume there can't be a typing mistake:

Code: Select all
<?php
require_once( 'couch/cms.php' );
include("../_html/head.php");
include("language.php");
include("../_html/nav.php");
include("home.xhtml");
include("../_html/foot.php");
COUCH::invoke();
?>


I put my pages together this way to make it easier to change the navigation and such things.

Besides that, is it possible to delete pages in couch? Not the original file just that couch won't list it anymore? So that I can rework stuff and include it later again?

Thanks!
Hi,

That is an unusual error.
Could you PM me your FTP and Couch credentials please? I'd like to take a closer look at the problem.
Thanks.
Hi,

The 'index.php' file that had the
Code: Select all
require_once( 'couch/cms.php' );

is actually residing within a subfolder and hence the the path needed is
Code: Select all
require_once( '../couch/cms.php' );

This is the modified code after I made the changes-
Code: Select all
<?php
require_once( '../couch/cms.php' );

// picture showing on the top of the page;
$headpicture='0';
// ------------------------------------;
include("../_html/head.php");
include("language.php");
include("../_html/nav.php");
include("home.xhtml");
include("../_html/foot.php");?>

<?php
COUCH::invoke();
?>

Had to make one more change -
Your php file was originally in utf-8 format and it was outputting a BOM header that was causing a 'header already send' warning. I resaved it as 'utf-8 without BOM' (using Notepad++) to rectify this.

Please check and confirm if things are working as expected.
Yes, it seems to be working. Thank you very much!

Since I already got your attention can you answer me the following questions:

is it possible to delete pages in couch? Not the original file just that couch won't list it anymore? So that I can rework stuff and include it later again?


And I got a free license before you changed your policy (non profitable page). What happens if I install the new version (or those of the future)? While I don't mind the link in the footer I would love to keep the rebranding option :).
is it possible to delete pages in couch? Not the original file just that couch won't list it anymore? So that I can rework stuff and include it later again?

I am not sure if I understood the question correctly, but if you meant how you could remove a template from the listing (left sidebar) in Couch admin, the procedure is as follows -
1. Remove the template physically from your site (you can also rename it temporarily).
2. Access the admin panel. Couch will sense that a listed template is missing and will prompt you to remove it from the admin panel as well (IMP: if the template is a cloned one and has cloned pages, all the pages need to be deleted first).

Since you no longer wish to get the template listed in Couch, simply remove the require_once( 'couch/cms.php' ); and COUCH::invoke(); lines and this will disassociate Couch from it.

Replying to your second query -
..I got a free license before you changed your policy (non profitable page). What happens if I install the new version (or those of the future)? While I don't mind the link in the footer I would love to keep the rebranding option..

All older licenses are respected and will work exactly the same as before. Incidentally, the older free license did not allow rebranding. It will simply not output the link in footer.

Hope this answers your questions. Do let me know.
Yes, thank you! So I just download and install the "free" version?

One last question (for now :) ) : Is it possible to manage the appearence of the pages in the admin panel (left side). Like I want the page that appeard last to be displayed on top of the list?
Please go ahead and upgrade. Your license will always remain valid.

Replying to your other question-
the order of the templates as shown in the left sidebar of admin panel can be easily changed by using the 'order' parameter of the 'template' tag. e.g.
Code: Select all
<cms:template title='Property' clonable='1' order='-1'>
...
</cms:template>

This is detailed at http://www.couchcms.com/docs/tags-refer ... plate.html.
I'll quote the relevant portion -
order
By default, all the templates defined for a web site are displayed in the admin panel in the order of their creation, the oldest one being on the top. This order can be manipulated by setting this parameter for each template. The smaller the number set as the order, the higher up the template appears in the list.

The default value of this parameter is '0'. You can give a template a negative value (-1 for example) to make it appear on the top. If you give another template a value of '-2', it will appear ahead of the one mentioned above.

Hope this helps.
Yes, this will help! Thanks again!

I got a new problem now: I wanted to add an editible dropdown region and save the value to a php variable. I added this code:

Code: Select all
      <cms:editable name="headpicture" label="Picture shown on top" desc="Select one from these"
      opt_values='Welcome=0 | Ronin=1 | HokusaiWave=2'
      opt_selected = '1'
      type='dropdown'
      />
      <cms:php>
         $cmsheadpicture = <cms:show headpicture />;
      </cms:php>


It doesn't work and I get this message displayed on the page:

Parse error: syntax error, unexpected ';' in /homepages/45/d262021144/htdocs/.kte2/couch/tags.php(1783) : eval()'d code on line 2


For a closer look, klick here

--

Edit: Ok, the message is gone when I select an option in the admin panel. The picture is still missing though

--

Edit: I figured it out :)
:)
KK wrote: Since you no longer wish to get the template listed in Couch, simply remove the require_once( 'couch/cms.php' ); and COUCH::invoke(); lines and this will disassociate Couch from it.


Is it possible to hide templates in the couch admin panel? :)
16 posts Page 1 of 2
cron