•  Coleen
  • 89.2% (Honored)
  • YAF Commander Topic Starter
Hi Everyone (Again!) 🙂

I've finally been able to get the forums on my local host to look and work like I want them to.

I have the YAF.Net installed on my hosting service's server, but of course those files don't have all the changes to the formatting that I made on my local host. I know that the files I need to move are mostly located in the themes and should be able to upload them with no issues. My question is this - are there any web.config files that would be different between my local host and the server that I need to worry about?

I am also still wondering about the set up of the email for the forums (please see this thread: "DB Connection Failure"  and my last entry in regards to setting up the email, or I can re-post my question over here?) I just want to make sure that I don't screw up the installation of the YAF.Net on my hosted server test website when I upload my files from my local host. Has anyone been through this process that can offer advice?

Thanks for everyone's help, it is greatly appreciated!

IF YAF is running properly on your host server, and the versions match (example YAF v1.9.6.1 on both host and local) - then you can upload/replace ANY files on the server installation. If it were me, I would download EVERYTHING IN THE YAF directories to my local computer (a safe folder out of the way) - so that just incase something goes wrong, you can just restore the original files that were one the server...

I would refrain from over-writing web.config, db.config, and app.config - those are the YAF config files.

The db.config and mail.config will be different between the local and the host server.

Your changes that you made to your site's appearance won't be in those files.

Regarding your mail configuration, you will have to have an email account setup on your mail server for YAF to use to send mail through. Then you also need the mail server's SMTP dns name or IP (such as "" for a gmail server). I will post a sample mail.config later that will show you where to put those values.
If you can't find it using the forum search, try my signature link -- searches this site using Google: Google is my Friend 
  •  Coleen
  • 89.2% (Honored)
  • YAF Commander Topic Starter
Thanks so much squirrel :)

I was able to get my files all uploaded to the server - the only issue I had/have is with the session timeout settings. If I am inactive for even 10 minutes on the "live" test forums my session times out and I have to re-login. I don't like that and I tried to reset the time out:

<forms name=".YAFNET_Authentication" protection="All" timeout="43200" cookieless="UseCookies"/>

I changed it to timeout="99999" but ended up with an error and had to change it back. Do you know what the highest value is that I can set this at so the user's session doesn't time out while users are reading posts? If they are idle for too long they will lose their session and I don't want them to have to continually sign back in. So far though, that seems to be the only issue - except that I have to set security. Is there a discussion some where that can give me some pointers on setting security so that when a member signs up, they have to be approved before they can post?

On the email, I do have an email account set up for use with the forums - I just need to know how to configure the mail files to get it to work correctly.

Once again your help is greatly appreciated. Thank you!

  •  Coleen
  • 89.2% (Honored)
  • YAF Commander Topic Starter
Okay, I'm not sure if I should start a new thread for these issues or not. I'll post them here, and if you think a new thread should be started, please let me know.

I'm in testing mode for the forums now and have several people helping me test. There are a few things that I need to fix and don't know where to start to fix them.

First, as I've already mentioned, I'm having timeout issues. I am REALLY frustrated with this! I've changed the timeout length here:

<authentication mode="Forms">
<forms name=".YAFNET_Authentication" protection="All" timeout="99999" cookieless="UseCookies"/>

But that doesn't work. It still logs me out after 10 minutes, and it is driving me absolutely nuts! I went and read the articles that were linked under this thread: Urgent, Yaf timeout  thread, but honestly can't make heads or tails of WHERE to change the session timeout from this link: MSDN SessionState element  because the code shown shows it as part of the <sessionState element, but when I do a search in my Yaf forums code for <sessionState - even searching the entire project, it finds nothing! I find lots of info under just sessionstate, but have no idea where/what/how to change any of it to fix the timeout issues I'm having.

Put simply, I'd like my sessions to work like they do here. I have logged in ONCE to these forums. I know cookies are used, (and I have cookies enabled in my code as you can see above) but I am STILL getting logged out after 20 minutes (I actually think it's only 10 minutes!) and this problem is driving nuts! Can someone please explain where I need to change the timeout settings?

Second I am having issues with user/member roles. I don't want members to immediately have access to the forums as soon as they register. I.e., they need to be approved before they can have read/write access to any of the posts on the forums. Is there some information somewhere on how to set this up? I thought I had it figured out, and yet it is not working correctly.

If anyone has some information on these issues I'd really appreciate the help.


Ok two problems two solutions.

1. To fix the issue with the session timeout you need to add a machine key to your web.config. You can generate one here... 

2. To setup a approve user first forum there is a guide + video available


Hope this helps.
  •  Coleen
  • 89.2% (Honored)
  • YAF Commander Topic Starter
Awesome - Thank you on BOTH accounts! The machine key did the trick (I've been logged in without a timeout for 31 minutes now!)

I just didn't quite understand the first link for the Machine key info on the other thread - thanks for the Key generator link. In case anyone else has this issue, the code needs to go in the web.config file under the <system.web> section; so the code would look something like this:

<machineKey validationKey="insert code from the machine key generator here"
decryptionKey="code from machine key generator" validation="SHA1" decryption="AES" />

Of course there is a whole lot of other code that goes in the <system.web> section, so don't overwrite it, but put your machine key in that section. In fact,you will see a section where there is a <!--'remmed--> statement for the machine key - put your key generated code under it, and it will work.

The setup for the approved member is easy, once you know the steps - thank you! I had set the "Require User Login" in the Host settings but did not know about setting the "Is Start" flag. That helped a LOT - thank you very much! :)


About Us

The YAF.NET is an open source .NET forum project. YAF.NET is supported by an team of international developers who are build community by building community software.

Powered by Resharper Donate with PayPal button

Project Twitter Updates

Copyright © YetAnotherForum.NET & Ingo Herbote. All rights reserved