Started getting No Content Given?

Help with getting the CMS CORE package up and running. This does not include 3rd party modules, PHP scripts, anything downloaded via module manager or from any external source.
Locked
Rabel
Forum Members
Forum Members
Posts: 31
Joined: Thu Mar 25, 2010 9:54 pm

Started getting No Content Given?

Post by Rabel »

Hi Everyone,
I am new to CMSMS and I have been working on the templates for a customer, I was using just content blocks with very Descriptive names like {content block="Project Section 850x500"}. After creating each template then I made a test page and each template worked fine until today when I came in and finished another template and tried to create a page and got this "No Content Given" error. I then tried the old templates i put together and got the same error. If I remove the block="blah blah" from one of the tags then it appears to work ok, but I am not sure why this started all of the sudden when no changes were made and it worked before. I went over a few threads but they only explained to add a basic content tag Few Questions

1. Any Ideas what caused this to happen when it did work?
2. Can I add a {content} that doesnt display in the cms? So I dont have to explain why this is different then the other content sections names and to not enter any information in it
3. Is there any other options around this problem?

I appreciate any help.
Thanks,
Randy
Last edited by Rabel on Tue Apr 20, 2010 10:57 pm, edited 1 time in total.
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am

Re: Started getting No Content Given?

Post by Dr.CSS »

Sorry you have to have one default content tag {content} in your template, you may be able to use the label parameter to label it as "Don't Use This" but really what's wrong with having one main content block...
Rabel
Forum Members
Forum Members
Posts: 31
Joined: Thu Mar 25, 2010 9:54 pm

Re: Started getting No Content Given?

Post by Rabel »

Thanks Dr. nothings really wrong with that but I wanted to keep everything uniform. Can you tell me why it did work and now it has stopped?

Thanks for the help.
Randy
tkemmere
Forum Members
Forum Members
Posts: 33
Joined: Fri Aug 11, 2006 1:00 pm

Re: Started getting No Content Given?

Post by tkemmere »

to Dr.CSS,

I came accross this problem too.

I'm building a site with two templates:
"1 whole" A page with a content block accross the whole width of the page;
"2 halves" A page with a two content blocks each using half the width of the page;

As I was designing the templates, and added the second content block, I saw that the {content block="xyz"} tag also generates a title in the editor. And since the 2 blocks come above oneanother there, I named them "left" and "right"! And then to keep things uniform, I named the single one in 1-whole.tpl "wide". Then the "no content given" error popped up, and I found this thread in the forum.

I suggest to add this bit of knowledge to the Help page of the content tag. It could go like this:
"Each template should contain one {content} tag, while second content blocks can have the block parameter". (I'm willing to add this to the forge, if you think this is appropriate).
tkemmere
Forum Members
Forum Members
Posts: 33
Joined: Fri Aug 11, 2006 1:00 pm

Re: Started getting No Content Given?

Post by tkemmere »

PS. Another thing for the help page on the Content tag:
The Label parameter is not listed under What parameters does it take?
But it does take it!

I'm using v1.6.6
RonnyK
Support Guru
Support Guru
Posts: 4962
Joined: Wed Oct 25, 2006 8:29 pm

Re: Started getting No Content Given?

Post by RonnyK »

I do see the parameter in the help of the tag.
(optional)label - Allows specifying a label for display in the edit content page.

Ronny
tkemmere
Forum Members
Forum Members
Posts: 33
Joined: Fri Aug 11, 2006 1:00 pm

Re: Started getting No Content Given?

Post by tkemmere »

Hi Ronny,

I suppose that is due to the version then. If you're using higher than 1.6.6, than this part label remark is no issue.

But I do suggest to put the remark about keeping the default {content} tag in, into the help-page. However I have no experience regarding submitting bug / enhancement suggestions. That is why I mention it here, and let you judge on it. If you find it worthy, I'm happy to submit it.

Regards.
RonnyK
Support Guru
Support Guru
Posts: 4962
Joined: Wed Oct 25, 2006 8:29 pm

Re: Started getting No Content Given?

Post by RonnyK »

I already put an extra line in the help of the plugin. ;)

No need for the BR for this. I dont recall that it was put in later, dont you see it on the bottom area, just above the UDT logic?

BTW, only last and semi-last (so 1.7.1 and 1.7 now...) are supported.

In the next release, the lang-file will be updated.

Could it be that you run another lang in the backend, which doesnt have the help in?

Ronny
tkemmere
Forum Members
Forum Members
Posts: 33
Joined: Fri Aug 11, 2006 1:00 pm

Re: Started getting No Content Given?

Post by tkemmere »

Re. the extra line: Cool!

Re. the label: On http://website/admin/listtags.php?sp_=e ... in=content

I see:
What does this do?

This is where the content for your page will be displayed. It's inserted into the template and changed based on the current page being displayed.
How do I use it?

Just insert the tag into your template like: {content}.
What parameters does it take?

   * (optional)block - Allows you to have more than one content block per page. When multiple content tags are put on a template, that number of edit boxes will be displayed when the page is edited.

     Example:

     {content block="Second Content Block"}

     Now, when you edit a page there will a textarea called "Second Content Block".
   * (optional)wysiwyg (true/false) - If set to false, then a wysiwyg will never be used while editing this block. If true, then it acts as normal. Only works when block parameter is used.
   * (optional)oneline (true/false) - If set to true, then only one edit line will be shown while editing this block. If false, then it acts as normal. Only works when block parameter is used.
   * (optional)size - Applicable only when the oneline option is used this optional parameter allows you to specify the size of the edit field. The default value is 50.
   * (optional)default - Allows you to specify default content for this content blocks (additional content blocks only).
   * (optional)assign - Assigns the content to a smarty parameter, which you can then use in other areas of the page, or use to test whether content exists in it or not.

     Example of passing page content to a User Defined Tag as a parameter:

              {content assign=pagecontent}
              {table_of_contents thepagecontent="$pagecontent"}

« Back to Menu
I'm running 1.6.6 "Bonde", all set to English, never changed.

Cheers.
Last edited by tkemmere on Sun May 09, 2010 12:36 pm, edited 1 time in total.
RonnyK
Support Guru
Support Guru
Posts: 4962
Joined: Wed Oct 25, 2006 8:29 pm

Re: Started getting No Content Given?

Post by RonnyK »

I see...

The label-parameter has been added to the help in the 1.7 branch just recently.

Ronny
Locked

Return to “[locked] Installation, Setup and Upgrade”