I have this wierd thing happening where I parse a text file to create nodes and publish them. The problem I am having is that the nodes "appear" to be published when the process is complete, but they are not viewable on the Web site. So, I know they are published becuase the node has a URL and it has an unpublish button available. Additionally, I can list the various nodes (using @nodeName) in a page in order to link to them. However, when I click a page in the list (output by xslt macro) I get a blank white screen. This is until I go to manually publish the node and then I can see the content.
The parser and publish code looks like this:
...
//Set props
policeDoc.getProperty("SubSite").Value = police.SubSite;
policeDoc.getProperty("Title").Value = police.Title;
policeDoc.getProperty("Urn").Value = police.Urn;
policeDoc.getProperty("Description").Value = police.Description;
policeDoc.getProperty("Content").Value = police.Content;
//Publish the node
policeDoc.Publish(author);
//Tell umbraco to publish the document
library.UpdateDocumentCache(policeDoc.Id);
...
Anyone have any ideas?? I'm stuck in limbo here... :)
No dice, and I don't do that on other API calls as the set of properties saves it immediately (I think). Man, I am seeing some strange behavior now. It appears that I can't even see the pages when doing a manual publish....hmmm
Ok, it seems that I had some template issue here as opposed to a publishing problem. So, I deleted umbraco.config and re-ran my content parser and all is well. The umbrac.config was pointing to template="0" (which is obviously incorrect).
Pages not being published
Hi all,
I have this wierd thing happening where I parse a text file to create nodes and publish them. The problem I am having is that the nodes "appear" to be published when the process is complete, but they are not viewable on the Web site. So, I know they are published becuase the node has a URL and it has an unpublish button available. Additionally, I can list the various nodes (using @nodeName) in a page in order to link to them. However, when I click a page in the list (output by xslt macro) I get a blank white screen. This is until I go to manually publish the node and then I can see the content.
The parser and publish code looks like this:
Anyone have any ideas?? I'm stuck in limbo here... :)
Thanks,
Nik
Hi Nik,
Try adding a policeDoc.Save(); right before the policeDoc.Publish
HTH,
Peter
CORRECTION: The "Link to Document" awlays seems to be empty, even when I do a manual publish. This is 4.0.2.1 on Win 2003.
Thanks!
Hi Peter, thanks. I will try that.
-- Nik
No dice, and I don't do that on other API calls as the set of properties saves it immediately (I think). Man, I am seeing some strange behavior now. It appears that I can't even see the pages when doing a manual publish....hmmm
Ok, it seems that I had some template issue here as opposed to a publishing problem. So, I deleted umbraco.config and re-ran my content parser and all is well. The umbrac.config was pointing to template="0" (which is obviously incorrect).
Thanks for your help!
-- Nik
G** Damnit! Now it's back to template="0" again! Has anyone seen this in the past?
Thanks,
Nik
Do you have a default-template defined for the document-type your creating?
Yeah, it's set to the right one??
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.