Sign In  |  Register
 
 DotNetNuke Powered!
DotNetNuke Support Forums

Restoring a live website to local installation

Rate this topic:

Please Register to post a reply.
Another benefit of registration is the ability to subscribe to and recieve notifications of new posts.

AuthorMessages
Declic Video
Posts:57



11/20/2007 10:06 AM  

Hello John,


I use windows explorer to navigate to c:\inetpub\wwwroot, then right click and select "New" -> "Folder" and create a folder with the same name as your existing DNN installation.
If I choose for example mydnn as a folder, and I connect to http://localhost/mydnn, my website is showing, excepted that ALL my images are not shown. I need to edit each module, to find the correct path for the images. And the path is modified from:
/Portals/0/images/myimage.gif to
/mydnn/Portals/0/images/myimage.gif

WHY ? Where is my mistake ???

I have found that in HOST SETTINGS, relative paths is not null compared to my live website. It is set to \mydnn
How could I modify this please ???

I give up.
DV

John Mitchell
Posts:3040



11/20/2007 1:52 PM  

Hi DV,

This happens because your local machine only has one IIS website and to create new installs of DNN you have to create a virtual directory (mydnn in your example).

On a server your site is a unique IIS website that does not have that virtual folder.

There's a couple ways to fix this.  You could have your hosting provider create a virtual folder on your live website with the same name and have it point back to your root website.

Or, you could use PageBlaster to replace the /mydnn in the output of you pages.

Declic Video
Posts:57



11/20/2007 2:06 PM  
Hello John,

I am not sure that I have understood your answer. I will better explain my problem:
- My live website is just perfect and behavior is ok.
- I have made a backup of the database and of the folders/files
- I would like to replicate this website/dnn install on my local computer.
- I have followed various tutorial to install Microsoft SQL Server Express
- I have been able to install DNN in local, and then, I was interested in restoring my live dnn.
- Consequently, I have deleted the files of the recently created DNN, and replaced the files with the live files
- I have deleted the database and created a new one and restored my live database
- I have, of course, changed my web.config (as well as implemented the correct alias localhost/mydnn)
- I can run the website locally with http://localhost/mydnn
Unfortunatelly, for an unknow reason, the relative path is not empty but indicate /mydnn
(and consequently, all my images are broken because of this relative path not being null as it is the case on my live website).

Is it clearer ? I am sure there is something wrong I am doing. For example, with the new DNN install, the path is also /mydnn (or the name of the folder). Not empty. It is not normal. I looked to ALL DNN WEBSITE (yours and plenty other one, the path to images are /Portals/0/... and not /folder-name/Portals/0/... )
Where is my error ???

DV
John Mitchell
Posts:3040



11/20/2007 2:15 PM  
The problem is like I explained above.
Your local installation has the application path at localhost/mydnn, but live one does not have the extra folder.
When you create content locally it adds the /mydnn part into the records in your DB.
When you move the DB it still has the HTML from the local.

It is a common problem when you create content locally and then move the DB.
Declic Video
Posts:57



11/21/2007 9:04 AM  
It means that there is no solution to modify the database to remove this extra folder ?...
:-(((((


DV
John Mitchell
Posts:3040



11/21/2007 9:21 AM  
You could go through and edit all the content to remove the folder, but it is a lot easier to either create the folder on your live site, or to use PageBlaster to remove it from the output.
Declic Video
Posts:57



11/21/2007 9:51 AM  
When you say: "create the folder on your live site, I do not understand what you mean".
The folder is already on my live site. I have e:\hosting\...\mydnn\
And it is the same. But of course, my relative path in Host setting is empty.

DV
John Mitchell
Posts:3040



11/21/2007 9:57 AM  
Your hosting provider has to create a virtual folder in the IIS manager and point it at the same physical folder.
Declic Video
Posts:57



11/21/2007 10:04 AM  
???? But if I correctly understood, I will then have mydnn into the live website (relative path). Correct ???
And then, I need to correct all my webpages to reflect the change.
This is not really what I would like to do... Or I misunderstood ???


DV
John Mitchell
Posts:3040



11/21/2007 10:11 AM  
The /mydnn part will only be added to new content if that is the way you are accessing it on the Url.

You may just want to use the PageBlaster replacement method if that is a concern though.
Please Register to post a reply.
Another benefit of registration is the ability to subscribe to and recieve notifications of new posts.

Forums >DotNetNuke Support >General-DNN-Help > Restoring a live website to local installation



ActiveForums 3.7
Visit our Store for great DotNetNuke Modules and Skins
DNNMasters Sitemap/Google Sitemap 3.0

Item codeSM3-01
Price$29.00
Product Information 
DotNetNuke CSS NavMenu 3.3 (Developers)

Item codeCSSNM33DEV
Base Price$149.00
Product Information 
Snapsis PageBlaster 3.3.2 for DotNetNuke - Professional Edition

AuthorJohn Mitchell
Base Price$79.00
Product Information