Last post Jan 08, 2007 05:30 PM by binLaden
Jan 02, 2007 09:05 AM|familyweb|LINK
OK, I'm giving this a try. Downloaded the starter kit and ran it on my computer, runs with no errors. When I upload it to my website I'm getting two errors: I have not changed any thng except logged in as an admin. Would appreciate help in getting me online
before I get to frustrated and go to FrontPage. Thank you..
<!-- Web.Config Configuration File --><configuration> <system.web> <customErrors mode="Off"/> </system.web></configuration>
<!-- Web.Config Configuration File --><configuration> <system.web> <customErrors mode="RemoteOnly" defaultRedirect="mycustompage.htm"/> </system.web></configuration>
Jan 02, 2007 10:53 AM|XIII|LINK
and welcome to the ASP.NET forums.
OK, I'm giving this a try. Downloaded the starter kit and ran it on my computer, runs with no errors. When I upload it to my website I'm getting two errors: I have not changed any thng except logged in as an admin.
probably the thing is that you haven't changed anything like connectionstring settings after uploading it on the server. To get a better, more detailed, error explanation does as this error message says: change the mode of the customErrors element in the
web.config and upload it again to your webserver in order to see more details.
Also you might be interested in this article:
Jan 02, 2007 04:04 PM|familyweb|LINK
Thank you Kriz,
I uploaded the DB.sql per the article. Still have the same error msg. Now working on changing the connection strings. Thanks for the info.
Jan 02, 2007 04:34 PM|XIII|LINK
Still have the same error msg.
Did you also change the setting of the customerrormode? After you solved the problem be sure to set it back to the original setting because else it could provide valuable information to people with less positive intentions.
Jan 02, 2007 05:19 PM|familyweb|LINK
Yes, I changed custom error mode to "off" . Now I have the same error code excep it shows "off" now ?????
Do I need to add that whole string to web config to read the errors????? ie.....defaultredirect="mycustompage.htm"/> ???????
Where would I send that?? I'm sorry but I'm lost...
Jan 02, 2007 06:06 PM|familyweb|LINK
I read another post, I think my problem is the same as binLaden: My string is pointing to my local machine: here is my web config:
<add name="Personal" connectionString="Data Source=.\SQLExpress;Integrated Security=True;User Instance=True;AttachDBFilename=|DataDirectory|Personal.mdf" providerName="System.Data.SqlClient" />
<add name="LocalSqlServer" connectionString="Data Source=.\SQLExpress;Integrated Security=True;User Instance=True;AttachDBFilename=|DataDirectory|aspnetdb.mdf" />
<compilation debug="true" />
<forms loginUrl="Default.aspx" protection="Validation" timeout="300" />
<globalization requestEncoding="utf-8" responseEncoding="utf-8"/>
<siteMap defaultProvider="XmlSiteMapProvider" enabled="true">
description="SiteMap provider which reads in .sitemap XML files."
type="System.Web.XmlSiteMapProvider, System.Web, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
Sounds like I need to point it to my remote website using a DB name, username and password. Not real obvious to this newby where it would go???? Can anyone help??? Thank you in advance. ............I'm putting the cart before the horse some, but if I can
at least see the starter kit on my website I'll invest more time in studying this aspnet stuff.......
Jan 02, 2007 08:04 PM|binLaden|LINK
You are correct about the problem. Your connection strings are pointing to your local server (SQL Express).
If your goal is to host your starter kit upon a remote site then you must point your connection strings to a database residing on the remote site, too.
Some web hosters support SQL Express. In that case you just need your provider to attach your existing database to their SQL Express service.
Other web hosters do not use SQL Express. In such case you should use a SQL Server database.
Either way, the web hoster will provide you with information that will alllow you to access your database.
Here is what a remote SQL Server connection string looks like (note: for personal web site you only need 1 sql server database, which run about $10 - $15 per database per month). This code goes into web.config. Its a good idea to comment out rather than
remove your good local code.
<!--this is a comment example
Everything between the comment brackets are commented out
connectionString="Data Source=***remote database connection string goes here. It will look like "sql.myprovider.com;" without quotes***
User ID=***put your SQL Server userid here***;
Initial Catalog=***put the name of your remote DATABASE here***;"
I hope this gets you on your way. There is more to come, and eventually you will end up rewriting a lot of the C# code for performance reasons, but otherwise what fun would it be? : )
If you run into any name collisions (I didn't) on your remote server just add a GUID.
good luck, & happy new year! -yoshiro (mark) aoki
Jan 02, 2007 10:01 PM|familyweb|LINK
Thank you very much, I'm giving it a try. "Just add a GUID" you make that sound so simple..... Thanks again...Happy new year..
Jan 03, 2007 03:11 AM|XIII|LINK
most hosters only provide SQL Server so I would suggest, to keep the price low, that you only use 1 database and have all the tables of the personal starter kit and those needed by membership in one and the same database. So this means that the connectionstrings
for the Personal and LocalSqlServer should point to the same database (also take a look at
http://www.connectionstrings.com/). Your provider should provide the connectionstring that points to your database.
After that you can connect to it with SQL Server Management Studio to create all the necessary tables. Normally the needed .sql file to create the Personal database ships with the project that you created on your dev machine in the App_Data folder. If not
you can obtain it from MSDN. To create all the necessary stuff for the membership tables you can run this command on your dev machine:
%windir%\Microsoft.NET\Framework\v2.0.50727\aspnet_regsql.exe -E -S localhost -d pubs -A all -sqlexportonly c:\membership.sql
which creates at location c:\ the membership.sql file which you can run against your remote database.
Jan 03, 2007 10:25 AM|familyweb|LINK
Thanks to all who tried to help me. Microsoft lead me to believe ASPNET was for the casual website builder. It looks like fun, but it's just to much of a learning curve for me. The biggest problem I see is getting it posted on a remote site. I tried dailyrazor.com
and getting info from them was like pulling teeth. I'm going to try a blog instead.
Thank you Kris & Mark for trying to help me. Have a great New Year!!!!!!!!!!!!!!!!!!
Jan 03, 2007 12:51 PM|XIII|LINK
I'm going to try a blog instead.
I can recommend using the free dasBlog blog engine. I also use it for my blog. It doesn't use SQL Server but xml instead. When you follow the guide that comes with it to set the necessary settings, most of the time just providing users write access to certain
folders, everything goes smoothly. And if you're interested to have custom macros installed you can take a look at one of my articles:
Creating custom macros for dasBlog.
Jan 03, 2007 03:56 PM|binLaden|LINK
Personally, I consider it a bug in the Starter Kit documentation when a user tries but fails to deploy.
good luck familyweb-san.
Jan 04, 2007 09:26 AM|XIII|LINK
I changed custom error mode to "off" . Now I have the same error code excep it shows "off" now ?????
since it's xml in your web.config it's also case sensitive so it should be Off, not off. This mode will not lead you to another page but will instead provide you with a more detailed view on the error.
Jan 08, 2007 05:30 PM|binLaden|LINK
I heard that Aquest Hosting, which is a pretty knowledgeable ASP .NET hoster with competent non-outsourced service,
is building a blog service. It might even be free, but Im not sure. Its at