Apr 24, 2014

MS SQL Server - Configuring MS SQL Server for Remote Access

This is repost of this:

Configuring MS SQL Server for Remote Access

Extra info from my experience:

  1. If you have more then one SQL server instance make sure that they use different ports.
    Leave first one on 1433 and assign your new one 1434.
  2. In IP addressess section IPAII make sure to clear TCP Dynamic ports on the bottom.
When trying to connect using SSMS if you had to use different port from 1433 and have some named instance here is naming convention for SQL server address:

vs2008develop,1434\MSSQLSERVERR2

Apr 23, 2014

DotNetNuke - Skins - How to reuse parts of page - using custom control inside skin custom control

Inside your Skins package folder you have number of different skins:

root\_default\Skins\NewSkin\HomeSkin.ascx
root\_default\Skins\NewSkin\ProductsSkin.ascx

You want to reuse repeated functionality, no matter static HTML or server side oriented with DNN expressions.

Create blank ASCX and place your func. in it. You don't need .vb or .cs code file.

Key point is that your header should have attributes like this:

<%@ Control Language="vb" AutoEventWireup="true" %>

DotNetNuke Efficion Articles module - Tips & tricks

Efficion Articles modules


  • Article list - articles/items are displayed but cannot be selected
    • Go to Article details of article that cannot be selected and under section "Detail Type" make sure to choose something different from None like "Text/HTML"


Tips for Articles module :


This was for old version 3.2.6

Apr 14, 2014

ASP.NET Url parts

Just reposting from here:

http://stackoverflow.com/questions/40680/how-do-i-get-the-full-url-of-the-page-i-am-on-in-c-sharp

Request.ApplicationPath :   /virtual_dir
Request.CurrentExecutionFilePath :  /virtual_dir/webapp/page.aspx
Request.FilePath :  /virtual_dir/webapp/page.aspx
Request.Path :  /virtual_dir/webapp/page.aspx
Request.PhysicalApplicationPath :   d:\Inetpub\wwwroot\virtual_dir\
Request.QueryString :   /virtual_dir/webapp/page.aspx?q=qvalue
Request.Url.AbsolutePath :  /virtual_dir/webapp/page.aspx
Request.Url.AbsoluteUri :   http://localhost:2000/virtual_dir/webapp/page.aspx?q=qvalue
Request.Url.Host :  localhost
Request.Url.Authority : localhost:80
Request.Url.LocalPath : /virtual_dir/webapp/page.aspx
Request.Url.PathAndQuery :  /virtual_dir/webapp/page.aspx?q=qvalue
Request.Url.Port :  80
Request.Url.Query : ?q=qvalue
Request.Url.Scheme :    http
Request.Url.Segments :  /
    virtual_dir/
    webapp/
    page.aspx

Apr 8, 2014

MS SQL server administration tips

When you backup DB on SQL server A and restore it on SQL server B you may encounter problems.

Here is some tips that have helped me.

User that you have put in your connection string must be:
1. Delete it from Security / Users of your Database
2. If does not exists in SQL Server B Security / Users create it
3. DO NOT MAKE any user mapping of this user in step 2. Just create user
4. Go to Properties of SQL Server B and select Files. Change DB owner to your conn.str. user.

This should work now.

Generally you should have dbo owner & Public rights for your user in user mapping in Security tab of your database.

Step 1 is obligatory ! Proven ...




http://www.mssqltips.com/sqlservertip/2620/steps-to-drop-an-orphan-sql-server-user-when-it-owns-a-schema-or-role/

Apr 1, 2014

DotNetNuke - tips when copying existing Dnn to another server

You want to copy database and DNN folder to another web server and SQL server.
If you think you fixed conn. string and DNN keeps showing Install wizard make sure to do bellow steps.
SQL:
1. Drop user that is used for conn. string and recreate it on SQL server with DBO rights. Assign it to your database
2. Add in table PortalAlias your new domain because it probably changed.

Web.config
1. Use IIS section Conn.string & AppSettings to change conn.strings. Use  .   for local SQL and DON'T use integrated security since IIS does not work under them.ms

Verify in web.config did IIS designer screwed up conn string section.