. Text blog A little bit of installation experience

Source: Internet
Author: User
Tags count iis insert
The first thing to get the source code (this look at other people's article good)

A dottextweb directory in the structure of the
source code is the Web directory.


adds a virtual directory to IIS, such as "blog", and the directory is dottextweb. Then modify the properties of Web project in DotText.sln to ensure that you can open this project (if so, you will





Project ("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Dottextweb", "http://localhost/DottextWeb/ Dottextweb.csproj "," {d5711ab8-be34-4d64-91a2-b68f310ca995} "


projectsection (projectdependencies) = Postproject


endprojectsection


projectsection (projectdependencies) = Postproject


endprojectsection


Endproject








changed to





Project ("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Dottextweb", "Http://localhost/blog/DottextWeb.csproj", " {d5711ab8-be34-4d64-91a2-b68f310ca995} "


projectsection (projectdependencies) = Postproject


endprojectsection


projectsection (projectdependencies) = Postproject


Endprojectsection


Endproject





immediately with vs.net Open this sln, all recompile. (At least the project should be able to get top, right)





the next step is to create a database


first create a database of your own. such as Blogdb. Then prepare to execute the following SQL script on this database

There are 3 SQL files under the
dottext\otherstuff\sql Scripts directory


dottextsetup_*** (The following is the version number). This is done first, to create the table structure in the database


Keywords.sql then execute this


Dottextsprocs.sql finally executes this and creates a stored procedure. But let's not do it now. First look at the following 2 bugs





***fix bug1***


the original author omitted a trigger was not created (some version was not created ...). This open source project is being updated every day. )


execute the following SQL to create this trigger


SET QUOTED_IDENTIFIER on


Go


SET ansi_nulls on


Go


CREATE TRIGGER Blog_content_trigger


on Blog_content


after INSERT, UPDATE, Delete


as





Declare @BlogID int





--get the current blogID


Select @BlogID = BlogID from INSERTED





--much more likely to is an insert than delete


--need to run on updates as down, incase an item is marked as inactive


if (@BlogID is null)


Begin


Select @BlogID = BlogID from DELETED


End





Update Blog_config


Set


Postcount = (Select Count (*) from blog_content Where blog_content.blogid = blog_config.blogid and Posttype = 1 and Ac tive = 1),


Commentcount = (Select Count (*) from blog_content Where blog_content.blogid = blog_config.blogid and Posttype = 3 and Active = 1),


Storycount = (Select Count (*) from blog_content Where blog_content.blogid = blog_config.blogid and Posttype = 2 and A ctive = 1),


Pingtrackcount = (Select Count (*) from blog_content Where blog_content.blogid = blog_config.blogid and Posttype = 4 A nd Active = 1)


Where BlogID = @BlogID


Go


SET QUOTED_IDENTIFIER off


Go


SET ansi_nulls on


Go





***fix bug2***


This file is called dnw_getrecentposts stored procedures, the inside and blog_content.id <> 50 off, otherwise the blogger ID 50 will never be displayed on the home page.





the next job, you need to determine how you are using the blog. . Text supports 3 different ways. Single-user physical multiuser and virtual multiuser


Single User We certainly will not use. Here we want to talk about the difference between the physical multi-user and the virtual multi-user. Text Blog looks like this when visiting a person's blog


Www.ncuhome.com/blog/xxx/xxx is the user name.


according to the general experience. There must be a directory of XXX or a virtual directory under the blog directory. When there are fewer users, no problem. But a lot of users are in trouble. You need to set up IIS to give all access control to. NET


Select the properties of the site--> home Directory--> config, add a suffix named * processing mode (even folder contains the past), set the processing ISAPI is


"P:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll"


at 2003, just insert the ISAPI. (I can't add to the XP Professional Edition.) Pain)


of course don't forget to add a default page to IIS Default.aspx





This is done, you can add a user test and perform the following SQL
with the Readme

INSERT into [Blog_config]


(


[UserName], [Password], [Email], [Title], [subtitle],


[Skin], [Host], [Author], [TimeZone],


[IsActive], [Language], [ItemCount], [allowserviceaccess], [lastupdated],


[News], [secondarycss],


[Application]


)


VALUES


(


' Aliy ', ' aliy ', ' joy@joycode.com ', ' aliy ', ' aliy ' blog ',


' marvin3-red ', ' blog.joycode.com ', ' Aliy ', 0,


1, ' Zh-chs ', 1, ' 7/28/2003 ', null, NULL,


' Aliy '


)





need to be aware of is the host field. Must be exactly the same as entered in the browser. For example, you have a site host is Ncuhome.com,ip is 210.35.247.34


then when you use http://ncuhome.com/blog/waterflier/you can access the blog of the user waterflier, but use http://210.35.247.34/blog/waterflier/ Can not be accessed. This is something that needs special attention.

















Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.