Error with “Add New Content”

For questions and problems with the CMS core. This board is NOT for any 3rd party modules, addons, PHP scripts or anything NOT distributed with the CMS made simple package itself.
farhadprm
Forum Members
Forum Members
Posts: 158
Joined: Mon May 28, 2007 2:40 pm

Error with “Add New Content”

Post by farhadprm »

Hi,
I have installed the version 1.9.2 CMSMS and right now I have the problem with the creation of new pages. When I click “Add New Content” and I try to create a new page, I receive the following error:

Code: Select all

INSERT INTO cms_content (content_id, content_name, content_alias, type, owner_id, parent_id, template_id, item_order, hierarchy, id_hierarchy, active, default_content, show_in_menu, cachable, secure, page_url, menu_text, markup, metadata, titleattribute, accesskey, tabindex, last_modified_by, create_date, modified_date) VALUES (77,'Projects','projects','content','1','71','15',1,'','',1,0,1,1,'0','','Projects','html','','','','','1','2011-01-22 15:35:54','2011-01-22 15:35:54')
Duplicate entry '77' for key 'PRIMARY'
Could somebody kindly explain what the problem could be?

Thank you in advance for your time

Far
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am

Re: Error with “Add New Content”

Post by Dr.CSS »

Do you have more than one {content} in your template?...
farhadprm
Forum Members
Forum Members
Posts: 158
Joined: Mon May 28, 2007 2:40 pm

Re: Error with “Add New Content”

Post by farhadprm »

Thank you for your reply.

yes, I havo more than one {content} in my template. But even if I try to create a page with "minimal template" I get the same error. However, in the meantime I edited "config.php" and I removed "mod_rewrite" and now I can add the pages, but still I did not understand what is the problem?

Many thanks
Far
Bilmartech
Forum Members
Forum Members
Posts: 50
Joined: Mon Feb 21, 2011 2:08 am

Re: Error with “Add New Content”

Post by Bilmartech »

I am experiencing the same exact problem now.. any solutions? When I create new content it says successful but does not show up in the pages in the admin section.

When i check the database the new page is there but the content_ID is 0 and if I attempt to add a new page via admin, I get the duplicate error because obviously content_ID 0 is what the new page content is trying to give that ID to.

I am not an expert but it appears to be something to do with the assigning of the unique content ID numbers that seems messed up some where?
Bilmartech
Forum Members
Forum Members
Posts: 50
Joined: Mon Feb 21, 2011 2:08 am

Re: Error with “Add New Content”

Post by Bilmartech »

OK so I played around with the database and have no idea if I should have done this BUT it worked!

I opened up the table for cms_content and clicked on the edit pencil next to the content_id row. On there I selected the drop down box next to extras that says auto_increment and went back and tried to add content again from the admin section and it worked.

I went back to the database and sure enough the page shows up there with the very next number in the content_id field...

So I have no idea why it did it or what but this seemed to work.. so my question now is... why did it happen in the first place and did will changing that setting cause anything else silly to happen in any way?
User avatar
factor1
Forum Members
Forum Members
Posts: 128
Joined: Thu Apr 13, 2006 11:24 pm

Re: Error with “Add New Content”

Post by factor1 »

im having similar issues, but the auto-increment didnt help me
farhadprm
Forum Members
Forum Members
Posts: 158
Joined: Mon May 28, 2007 2:40 pm

Re: Error with “Add New Content”

Post by farhadprm »

factor1 wrote:im having similar issues, but the auto-increment didnt help me
I have resolved the problem with upgrade cmsms to 1.9.4 version.
User avatar
factor1
Forum Members
Forum Members
Posts: 128
Joined: Thu Apr 13, 2006 11:24 pm

Re: Error with “Add New Content”

Post by factor1 »

got it. im on 1.9.4 now. issues on an old install that upgraded to 1.9.4, and issues on a clean install. each on a different server.
jcknight
New Member
New Member
Posts: 5
Joined: Fri Sep 10, 2010 3:50 am

Re: Error with “Add New Content”

Post by jcknight »

I also just installed 1.9.4 and have a similar problem where I have a default home page, and a second page(events), but when I goto add more content(another page) it says it was a successfully written to the database but no new pages can be seen in the list.

Any suggestions? oh yea I a unable to access my database directly, because of the isp.
jmcgin51
Power Poster
Power Poster
Posts: 1899
Joined: Mon Jun 12, 2006 9:02 pm

Re: Error with “Add New Content”

Post by jmcgin51 »

Running 1.9.4 (upgraded from earlier 1.9), and I can create new pages with no problems and they show up in the admin panel and on the front end.
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am

Re: Error with “Add New Content”

Post by Dr.CSS »

To get a good idea of what exactly is happening we need a good description, step by step, of what was done to get to this point, we try to duplicate them to see what the problem is...
User avatar
factor1
Forum Members
Forum Members
Posts: 128
Joined: Thu Apr 13, 2006 11:24 pm

Re: Error with “Add New Content”

Post by factor1 »

Basically, Log in, Add new page, submit. CMSms returns the user to the content view, with a success message, but the new content fails to show.

New content is in the DB, and can be accessed via its url.

Thus far the work around is to go to the site settings > advanced and clear the cache.

while that works. Its not a realistic fix to clear the cache ass you add new pages. This was not an issue from v 0.9 through 1.9.1.
uniqu3

Re: Error with “Add New Content”

Post by uniqu3 »

@factor1
turn debug mode on in config.php and check for any errors.
User avatar
factor1
Forum Members
Forum Members
Posts: 128
Joined: Thu Apr 13, 2006 11:24 pm

Re: Error with “Add New Content”

Post by factor1 »

no errors.

did a second install today, and it seems fine thus far.
RonnyK
Support Guru
Support Guru
Posts: 4962
Joined: Wed Oct 25, 2006 8:29 pm

Re: Error with “Add New Content”

Post by RonnyK »

Could you guys that experience this issue describe IF you are running php5.3 and IF you have the proper timezone set in the config.php.

It might be an issue with a difference between the server-time and the timezone in the config.php... Than the pages will show in some time, when the difference in time is passed....

Ronny
Post Reply

Return to “CMSMS Core”