Saturday, October 11, 2008
Archive
Minimize
Blog2mind
Minimize
Apr 5

Written by: donker
Sat, 05 Apr 2008 23:05:27 GMT

This script will move stuff from a DNN HTML module to a DNN Blog module. I needed it just now and I jot it down here so as not to forget it and if it helps you ... well so much the better.

1. Find the module you want to import. Note the ModuleID (click settings and you see the 'mid' in the querystring of your browser)

2. Find the Blog ID you want it to go (in your blog go to Blog Settings and note the BlogID in the querystring)

3. Run the following code in Host > SQL replacing the variables with their corresponding values:

INSERT INTO {objectQualifier}Blog_Entries
(BlogID, Title, Entry, AddedDate, Published, [Description], AllowComments, DisplayCopyright, Permalink)
SELECT @BlogID, 'Title', h.DesktopHtml, h.CreatedDate, 1, 'Descr', 1, 0, ''
FROM {objectQualifier}HtmlText h
WHERE h.ModuleId=@ModuleID

4. Go to your blog and edit the newly created entries. Note that (1) you might need to get a refresh of the module from cache and (2) your blog entry is at the date the HTML module was last edited.

 

Tags:
Privacy Statement  |  Terms Of Use
Copyright 2004-2008 Bring2mind