How To Guides

A little something about everything

internet marketing and website development made simple..

How to recover serveradmin access of teamspeak3/ts3 server after system reload.

This works but you should still stop and backup your ts3 server.

After you backup is complete follow these steps.

While ts3 server is stopped start the server using this command: (assuming you are running 64 bit server on windows)

(Drive):\Path\ts3server_win64.exe serveradmin_password=YourNewPassWord

(You can do this by making a shortcut and editing the target location as well)

Now you have an updated TS3 admin password, with this you can create a new privileged key.

Using puttytel.exe or any other telnet client to type the following commands:

(localhost if your server is hosted on the pc/server you are running telnet on, otherwise just use the ip or server name)

After the last command the server will respond with a token=YourNumbersAndLettersToeknID

Copy this and past it into your TS3 client under permissions > use privileged key.

How to setup FTP services on CentOS to work with webmin

First things first, make sure you are up to date on all of your packages,

yum update -y

Now you should install the FTP module

yum install vsftpd -y

Start the service

service vstfpd start

Now you will need to install Perl for the webmin qui to manage vsftpd

yum install perl -y (this is most likely already installed)

yum install perl-CPAN -y

yum install perl-CGI -y

Install the vftpd module for webmin

login, go to webmin, Webmin configuration, Webmin modules, from URL and enter: http://blog.shawnhyde.com/FILES%2f2013%2f12%2fvsftpd-2009-04-30-1755.wbm.gz.axdx

refresh webmin, go to services and vsftpd to configure it.

 

Moving database from MS SQL 2000 to 2005 or 2008 | Error / User / Roles / Delete

In order to fix this bug you can simply run this command on the effected database after you have used the backup (sql2000) / restore sql2005/2008) or detach attach methods.

command to run:

 

Replace "dbusername" with the problem user account. both should be the same.

This will remove the ghost user from the sql 2000 server and replace it with the new user on your sql 2005 / 2008 server. Be sure to have the user created before running this command.

Errors associated with this are as follows:

"login name must be specified Database user"

"The database principal owns a schema in the database, and cannot be dropped"

"user group or role already exists in the current database"

"can't delete sql user in database"

Quick fix for "PHP Notice: Undefined variable" errors PHP 5.0 / 5.1 / 5.2 / 5.3 / 5.4

After taking over an account from another firm, the customers site was getting errors like this? Generally I would rewrite the code into asp.net however I was in a hurry to find a quick solution.

Example of the errors:

PHP Notice: Undefined variable: city in path\dbconnect.PHP on line 3 PHP Notice: Undefined variable: state in path\dbconnect.PHP on line 4 PHP Notice: Undefined variable: ownership in path\dbconnect.PHP on line 5 PHP Notice: Undefined variable: priceMin in path\dbconnect.PHP on line 6 PHP Notice: Undefined variable: priceMax in path\dbconnect.PHP on line 7 PHP Notice: Undefined variable: bedMin in path\dbconnect.PHP on line 8 PHP Notice: Undefined variable: bedMax in path\dbconnect.PHP on line 9 PHP Notice: Undefined variable: bathMin in path\dbconnect.PHP on line 10 PHP Notice: Undefined variable: bathMax in path\dbconnect.PHP on line 11 PHP Notice: Undefined variable: sqftMin in path\dbconnect.PHP on line 12 PHP Notice: Undefined variable: sqftMax in path\dbconnect.PHP on line 13 PHP Notice: Undefined variable: acreMin in path\dbconnect.PHP on line 14 PHP Notice: Undefined variable: acreMax in path\dbconnect.PHP on line 15 PHP Notice: Undefined variable: yearMin in path\dbconnect.PHP on line 16 PHP Notice: Undefined variable: yearMax in path\dbconnect.PHP on line 17 PHP Notice: Undefined variable: garageMin in path\dbconnect.PHP on line 18 PHP Notice: Undefined variable: garageMax in path\dbconnect.PHP on line 19 PHP Notice: Undefined variable: listingID in path\dbconnect.PHP on line 20 PHP Notice: Undefined variable: ADDLISTING in path\dbconnect.PHP on line 21 PHP Notice: Undefined variable: UPDATELISTING in path\dbconnect.PHP on line 22 PHP Notice: Undefined variable: deletePhoto in path\dbconnect.PHP on line 23 PHP Notice: Undefined variable: deleteDisclosure in path\dbconnect.PHP on line 24 PHP Notice: Undefined index: priceMin in path\basic.PHP on line 4 PHP Notice: Undefined index: priceMax in path\basic.PHP on line 5 PHP Notice: Undefined index: state in path\basic.PHP on line 6 PHP Notice: Undefined index: city in path\basic.PHP on line 7 PHP Notice: Undefined index: ownership in path\basic.PHP on line 8

Obviously the site is using invalid code and the newer php5.x is more than happy to tell you about it.

You can fix your code or you can simply disable the error reporting:

 

Be sure to place the code inside your php tags:

 

How to create a basic asp.net contact form in vb.net

First thing you will need to do is specify the scripting language, content type and endcoding type in a page element. Language will be visual Basic, content Type will be text/html and ecoding will be UTF-8

Next you will want to specify the doctype, this will tell the browser exactly what type of HTML you are using in the page. We'll be using the following DTD HTML doc type.

Now we need to import the System.Web.Mail asp.net namespace for use with our basic contact form

Now that the page basics are setup we need to write some script that will handle the information browsers will provide when visiting your page. First you need to write the server side script call. Then include a runat="server" verable which will tell the server to run it locally on the server side so the browser cannot view the information. This is done to prevent souce view bots from gaining email address information in your contact form.

Server side code

then you need to end the runat=server code

 

add standard HTML elements

Now the form, form fields and content

 

 

You may want to add some validation to the above code in order to prevent bots from filling out your contact form.

Finally closing of page HTML elements