PageSourceSearch

https://www.patrimoinevivantdupaysdemillau.org/DesktopModules/Blog/js/dotnetnuke.blog.js?_=6.5.4.0&cdv=98

js patrimoinevivantdupaysdemillau.org collected 2026-10-06 03:09:29 UTC 3,261 bytes, 87 lines download raw bytes

1function BlogService($, settings, mid) {
2	var moduleId = mid;
3	var baseServicepath = $.dnnSF(moduleId).getServiceRoot('Blog');
4
5	this.ajaxCall = function (type, controller, action, id, data, success, fail) {
6		// showLoading();
7		$.ajax({
8			type: type,
9			url: baseServicepath + controller + '/' + action + (id != null ? '/' + id : ''),
10			beforeSend: $.dnnSF(moduleId).setModuleHeaders,
11			data: data
12		}).done(function (retdata) {
13			// hideLoading();
14			if (success != undefined) {
15				success(retdata);
16			}
17		}).fail(function (xhr, status) {
18			// hideLoading();
19			displayMessage(settings.errorBoxId, settings.serverErrorWithDescription + eval("(" + xhr.responseText + ")").ExceptionMessage, "dnnFormWarning");
20			if (fail != undefined) {
21				fail(xhr.responseText);
22			}
23		});
24	}
25
26	this.approvePost = function (blogId, postId, success) {
27		this.ajaxCall('POST', 'Posts', 'Approve', null, { blogId: blogId, PostId: postId }, success);
28	};
29
30	this.deletePost = function (blogId, postId, success) {
31		this.ajaxCall('POST', 'Posts', 'Delete', null, { blogId: blogId, PostId: postId }, success);
32	};
33
34	this.viewPost = function (blogId, postId, success) {
35		this.ajaxCall('POST', 'Posts', 'View', null, { blogId: blogId, PostId: postId }, success);
36	};
37
38	this.approveComment = function (blogId, commentId, success) {
39		this.ajaxCall('POST', 'Comments', 'Approve', null, { blogId: blogId, commentId: commentId, karma: 0 }, success);
40	};
41
42	this.deleteComment = function (blogId, commentId, success) {
43		this.ajaxCall('POST', 'Comments', 'Delete', null, { blogId: blogId, commentId: commentId, karma: 0 }, success);
44	};
45
46	this.karmaComment = function (blogId, commentId, karma, success) {
47		this.ajaxCall('POST', 'Comments', 'Karma', null, { blogId: blogId, commentId: commentId, karma: 0 }, function(data) {
48			if (data.Result === 'exists') {
49				// user already did this
50			};
51			if (success != undefined) {
52				success();
53			}
54		});
55	};
56
57	this.addComment = function (blogId, postId, parentId, comment, author, website, email, success) {
58		this.ajaxCall('POST', 'Comments', 'Add', null, { blogId: blogId, postId: postId, parentId: parentId, comment: comment, author: author, website: website, email: email }, success);
59	};
60
61	this.getCommentsHtml = function (blogId, postId, success) {
62		this.ajaxCall('GET', 'Comments', 'List', null, { blogId: blogId, postId: postId }, success);
63	};
64
65	this.addModule = function (paneName, position, title, template, success) {
66		this.ajaxCall('POST', 'Modules', 'Add', null, { paneName: paneName, position: position, title: title, template: template }, success);
67	};
68
69	this.exportBlog = function (blogId, success) {
70		this.ajaxCall('POST', 'Blogs', 'Export', null, { blogId: blogId }, success);
71	};
72
73	this.getVocabularyML = function (vocabularyId, success) {
74		this.ajaxCall('GET', 'Terms', 'VocabularyML', null, { vocabularyId: vocabularyId }, success);
75	}
76
77}
78
79function displayMessage(msgBoxId, message, cssclass) {
80	var messageNode = $("<div/>")
81				   .addClass('dnnFormMessage ' + cssclass)
82				   .text(message);
83	$(msgBoxId).prepend(messageNode);
84	messageNode.fadeOut(3000, 'easeInExpo', function () {
85		messageNode.remove();
86	});
87};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.