I'm trying to create a BlogPost from code and I have trouble with the tags. Even the value published is well shown on the blog, the tag value is not visible from the BlogPost Editor and it's deleted if I publish the post again.
Here some piece of code. Is some one familiar with that ? or there is something to do with the Tag Type ? Thanks for any help.
privatevoid publish(long
id)
{
Digipoint.AntArticMatters.DataLayer.
GuestBook gb = new Digipoint.AntArticMatters.DataLayer.GuestBook
();
gb.LoadByPrimaryKey(id);
DocumentType type = DocumentType.GetByAlias("BlogPost"
Experiencing the same or a similar problem on a client site. Tags on blog posts seemingly randomly disappear. Seems to be related to editing a previously published post.
We do not create or edit any blog post programatically.
I've noticed that if I type a tag or two and then wait a second, a "dropdown" type of deal appears and I can select what is (hopefully) the list of tags I've typed.
However, it never works properly and the full list of what I've typed rarely appears. Either way, it's a start and so i recommend in the meantime you click on that and hope for the best... Also, IE seems to be the most reliable browser for this (sadly).
Also, you have to type all of the comma-separated tags at once. if you type a new tag and click the "tag" button, all of the tags are replaced with that one.
BlogForUmbraco4 post publishing
I'm trying to create a BlogPost from code and I have trouble with the tags. Even the value published is well shown on the blog, the tag value is not visible from the BlogPost Editor and it's deleted if I publish the post again.
Here some piece of code. Is some one familiar with that ? or there is something to do with the Tag Type ? Thanks for any help.
id)
{
Digipoint.AntArticMatters.DataLayer.
();
gb.LoadByPrimaryKey(id);
);
umbraco.BusinessLogic.
.GetUser(0);
;
(1111);
.MakeNew(text, type, u, 1111);
newdoc.Save();
newdoc.getProperty(
).Value = gb.Message;
newdoc.getProperty(
;
newdoc.CreateDateTime =
.Now;
newdoc.Save();
newdoc.Publish(u);
umbraco.
.PublishSingleNode(newdoc.Id);
I believe that the "tags" datatype has to be comma seperated, even if there is only one tag in the list. Try something like:
Experiencing the same or a similar problem on a client site. Tags on blog posts seemingly randomly disappear. Seems to be related to editing a previously published post.
We do not create or edit any blog post programatically.
Any ideas or suggestions?
Thanks!
I've noticed that if I type a tag or two and then wait a second, a "dropdown" type of deal appears and I can select what is (hopefully) the list of tags I've typed.
However, it never works properly and the full list of what I've typed rarely appears. Either way, it's a start and so i recommend in the meantime you click on that and hope for the best... Also, IE seems to be the most reliable browser for this (sadly).
Looking forward to a better solution :)
Dave
Also, you have to type all of the comma-separated tags at once. if you type a new tag and click the "tag" button, all of the tags are replaced with that one.
is working on a reply...