Archive for the ‘Windows 2003 Server Tips’ category

Monitoring Your VPS or Dedicated Server.

December 6th, 2010

One of the most important factors that you should be constantly monitoring with your VPS or dedicated server, especially if you host clients on it, is the uptime of it; this means that you should always be using some type of monitoring service to ensure that your VPS or dedicated server, and if it isn’t you need to ensure that you are notified of the down time ASAP so that you are able to sort the problem out yourself, or notify the support team of your web host to ensure that the down time caused is minimal and that your server will come back online ASAP.

If you are a web host which is providing a responsible and sensible service, then in your terms and conditions you will probably have conditions set out regarding up uptime, which in most cases states things such as if a customer’s service is down for over a certain amount of time, or if the monthly uptime record doesn’t meet the one which is guaranteed then customers are able to request a refund; this in itself should provide you with the motivation to fix a server problem if you have set such rules out in your terms and conditions, since most companies wouldn’t want a servers worth of customers requesting refunds since they don’t think they have been provided with the amount of uptime which has been guaranteed. Most web hosts use their own internal monitoring system for their servers, since in most cases it will alert them quicker to a problem than an external solution would since an internal system is most likely monitored more closely, but with an external solution in place as backup in case the internal one fails. One thing to consider is that most external monitoring services monitor your website or server from multiple geographically different locations which means that they are able to provide a more reliable source of information when it comes to checking to see whether your VPS or dedicated server is online or not when compared to a monitoring system which is monitoring your VPS or dedicated server from one location or from one country or data center, which means that the produced results might not always be accurate and reliable.

When considering uptime solutions for your VPS or dedicated server, you should always take into consideration the effect that a program might have on the performance of your VPS or dedicated server; for example if you use an internal solution then you might need to install an ‘agent’ program which posts data about your server back to the master monitoring node, since information such as the speed that your server’s CPU is running at and the amount of memory that your server has left are factors that can only be gained by internal access to your server unlike other factors such as whether certain services are running or not that can be found out easily via pinging the port which the service runs on. You want to try and maximize the uptime of your VPS or dedicated server, which means that you should optimize the programs that you have installed on it, so that they don’t use up too many resources since the most common reason for a server crashing is that there aren’t enough resources available to keep the operating system going, which means that it just crashes because it is unable to run for any longer on the scarce resources that are available for it.

Conclusion

In conclusion, with the use of either internal or external monitoring systems, you are able to maximize the uptime of your VPS Hosting or dedicated server, thus ensuring that your customers, if you host them on your server, are happy with the service and level of uptime that you have been able to provide them with; you are also ensuring if you use your server for other purposes such as for receiving emails or for a website that emails are received as often as possible, and that visitors will still return to your website thus increasing your amount of revenue that you earn from adverts if applicable. You can also optimize your VPS or dedicated server as well as the programs that it runs to ensure that the amount of resources used is far lower, thus ensuring that you can install some more applications on your VPS or dedicated server or leave it as it is so that it is able to run fast; if running cPanel, then you can use the new optimized version since this will run much fast on a lower specification machine since it has been designed to take up less memory and utilize less CPU.

If you choose to use an internal monitoring system then you gain the ability to monitor internal factors of your server, such as the amount of CPU and memory that is available for use by the operating system and programs that you have installed on your VPS or dedicated server – this is very important if you are running a server which is hosting web hosting and design clients, since you don’t want their websites going down because of a lack of resources. Other factors which you might want to consider when choosing a monitoring system is the accuracy of the results that are collected and in turn produced; for example, with an external monitoring system you will want to be considering how spread the multiple geographical monitoring stations are and with the case of an internal monitoring system, you should find out whether internal server resources can be monitored or not – this will give you an advantage since you will be able to monitor all aspects of your server then, both internal and external which means that accurate results should be produced.

Benefits of dedicated servers in games website.

November 24th, 2010

Every once life one is the time when he/she have his own game to play. In today’s market you can see allover digital games are more popular like xbox360, play station and Nintendo games capture the game markets. But can you think it why everyone likes to play online? And this base idea of dedicated server games theme.

Everyone cannot afford to buy Xbox 360, play-station or Nintendo But; current games versions available on Internet are better than to play alone. There quality display, speed is specially made to give you a high quality excitement, and these kinds of things are possible through dedicated servers.

There quality, display, speed are in particular made to give you a far above the ground quality thrill, and these kinds of things are probable through dedicated servers. If you pay money for a game DVD, how much time you play? At one period, to play that game getting so boring, this is the major reason behind popularity of online games. With lend a hand of dedicated game servers’ people can play against someone else there is no want of same play station. This is the main reason, the online game providers never end require of dedicated game servers. Network bandwidth is one the crucial part in gaming business, because it must be compulsory always in upstream. Here home or office broadband Internet connection is not plenty. Normally with this type of connection, player does not get upstream bandwidth to host out-and-out game servers more than five to ten clients, but in the past years this is the only option was available for game hosting.

Couple of years before, the player who have the game, host the server and also run the client. However, on another side, the bandwidth provider of latest broadband service, handle the outgoing traffic at same time, therefore the host computer struggled to provide a good quality of service to the players on the network, while at the same time running the game on the same computer.

However, the online game providers realized, the importance of dedicated servers, because they need professional server to read data and transferring huge amounts of data as fast as players need it, therefore they purchased rack mounted server machines and collocated them inside Data Center Services to host their games Website. They paid monthly charges for it and the services they got is invaluable, these set ups improved the quality of their games.

Windows Server 2003 – Tips

April 20th, 2010

Windows Server 2003 – Tips

1) Disable the original Administrator account

In Windows Server 2003, for the first time, you CAN disable the Administrator account.   My point is that every hacker knows that Windows has a username called Administrator, so defend it by disabling the account. (Right Click the Administrator, Disable)  Obviously you must create another account with administrative privileges.

There are two variations of this tip.

a) You could disable the account from logging on across the network

b) You could rename the account and create a dummy administrator to confuse would be hackers

2) View Advanced Features

As you are an expert, display all those hidden menus and folders.

a) Go to the Active Directory Users and Computers, Select View (Menu) then check: Advanced Features.  Now you should see the ‘LostAndFound’ folder and so be able to check for any orphaned users.

b) Select the DNS Icon, View (Menu), Advanced.
This brings the DNS ‘Cached Lookups’ folder into view.

c) Device Manager, Show Hidden Devices.
This useful for troubleshooting Non Plug and Play devices.

3) The easiest way to bring up the System Icon

Here is my favourite keyboard short cut:
(Windows Key) + Pause/Break (Key)

4) Remote Desktop

The idea is to connect to the Windows Server 2003 from your XP Desktop.  Configure Remote Desktop from the System Icon, Remote (tab), Remote Desktop.  This will save you that long walk to the server room.

When you are logged on to your XP machine go to Accessories, Communication, Remote Desktop connection.  Incidentally, remote desktop was voted the top reason to migrate to XP and here it is on Server 2003.

5) Troubleshooting Error Messages.

a) Start, Help and Support, Troubleshooting Strategies (Bullet point 5)  Here is a wonderful selection of tools to lead you methodically through a problem.  Each hardware device will have its own troubleshooters.  They are excellent for making sure you have not overlooked something obvious.

b) Start, Help and Support, Error and Event Log Messages.  Just type in the error message which you find in the Event Viewer, make sure you are on line, and Microsoft will help diagnose the cause and a solution.

Guy Recommends:  A Free Trial of the Orion Network Performance Monitor (NPM) 9.5Review of Orion NPM

Solarwinds’ Orion performance monitor will help you discover what’s happening on your network.  Also this utility will guide you through troubleshooting; the dashboard will indicate whether the root cause is a broken link, faulty equipment or resource overload.  Because it produces network-centric views, the NPM is intuitive to navigate, and as result you can see easily what’s working and what’s not.

Perhaps Orion’s best feature is the way it suggests solutions.  Moreover, if problems arise out of the blue, then you can configure Orion NPM 9.5 to notify members of your team what’s changed and how to fix it.

6) To display your Username and Computer Name on the ‘My Computer’

Here is a tip for those who like to hack the registry.

Preliminary step, show the ‘My Computer’ icon, go to Control Panel, Display, Desktop (Tab), Customize Desktop, Check My Computer.

Principle: Find the setting for the My Computer object in the HKey_Classes_Root, substitute two variables for the original setting.   Warning:This is a particularly difficult registry change to make so export the registry FIRST. Regedit, File (menu), Export.

Getting Started

a) Use regedit to locate [HKEY_CLASSES_ROOT\CLSID\{20D04FE0-3AEA-1069-A2D8-08002B30309D} rename LocalizedString to LocalizedString.Old.  I advice this step in case anything goes wrong and you want to revert to how it was.

b) Create a new VALUE type Expand_SZ name it LocalizedString  Set the value of LocalizedString to %Username% at %Computername%

Windows 2000 Tips

Press F5 to refresh the 'My Computer', there is no need to logoff and certainly do not reboot.

7) Configure a short cut to 'Run As' a different user.

This tip only works on short cuts.  So create a short cut to one of your key programs, for example Active Directory Users and Computers.  Right click the short cut, Properties, Advanced (Button), Run with Different Credentials.  The idea behind 'Run As' is to encourage you to log on as an ordinary user, and then use 'elevated rights' when you need to run the administrative tools.  What it does is save you having to log off and then logon again as the administrator.

8) Taskbar appearance

Right Click the Grey Bar at the bottom of the screen, Properties - check out all the settings.

ASP.NET 3.5 Hosting and Visual Studio 2008

September 17th, 2009

ASP.NET 3.5 and Visual Studio 2008 bring great new functionality around Web development and design that makes building standards based, next generation Web sites easier than ever. From the inclusion of ASP.NET AJAX into the runtime, to new controls, the new LINQ data capabilities, to improved support for CSS, JavaScript and others, Web development has taken a significant step forward.

New Features in ASP.NET 3.5

With ASP.NET AJAX, developers can quickly create pages with sophisticated, responsive user interfaces and more efficient client-server communication by simply adding a few server controls to their pages. Previously an extension to the ASP.NET runtime, ASP.NET AJAX is now built into the platform and makes the complicated task of building cross-platform, standards based AJAX applications easy.

New ListView and DataPager Controls

The new ListView control gives you unprecedented flexibility in how you display your data, by allowing you to have complete control over the HTML markup generated. ListView‘s template approach to representing data is designed to easily work with CSS styles, which comes in handy with the new Visual Studio 2008 designer view. In addition, you can use the DataPager control to handle all the work of allowing your users to page through large numbers of records.

New Web Features in Visual Studio 2008

Visual Studio 2008 is the recommended tool for developing ASP.NET applications. Unlike previous versions of Visual Studio, which were targeted to a specific framework version (i.e., Visual Studio .NET 2003 targeted ASP.NET 1.1 and Visual Studio 2005 targeted ASP.NET 2.0), Visual Studio 2008 is multi-targeted, meaning that you choose from a drop-down list whether to have Visual Studio 2008 build applications against the ASP.NET 2.0, 3.0, or 3.5 frameworks. Visual Studio 2008 also includes an improved Designer experience, JavaScript debugging and IntelliSense features, and the ability to view and even step into the core .NET Framework code during debugging

New Web Design Interface

Visual Studio 2008 has incorporated a new Web designer that uses the design engine from Expression Web. Moving between design and source view is faster than ever and the new split view capability means you can edit the HTML source and simultaneously see the results on the page. Support for style sheets in separate files has been added as well as a CSS properties pane which clarifies the sometimes-complex hierarchy of cascading styles, so that it is easy to understand why an element looks the way it does. In addition Visual Studio 2008 has full WYSIWYG support for building and using ASP.NET Nested Master Pages which greatly improves the ability to build a Web site with a consistent look and feel.

JavaScript Debugging and Intellisense

In Visual Studio 2008, client-side JavaScript has now become a first-class citizen in regards to its debugging and Intellisense support. Not only does the Intellisense give standard JavaScript keyword support, but it will automatically infer variable types and provide method, property and event support from any number of included script files. Similarly, the JavaScript debugging support now allows for the deep Watch and Locals support in JavaScript that you are accustomed to having in other languages in Visual Studio. And despite the dynamic nature of a lot of JavaScript, you will always be able to visualize and step into the JavaScript code, no matter where it is generated from. This is especially convenient when building ASP.NET AJAX applications.

Enable parent paths for your site on a windows server

September 17th, 2009
How do I enable parent paths for a website on my server?

The following article explains how to enable parent paths for a website. By default, parent paths are disabled in IIS 6. Parent paths allow you to use “..” in calls to functions such as MapPath. Instead of specifying the full path, you can use “..” to reference a path relative to your current location.

Note: Enabling parent paths may create a security risk as it could allow someone to access files outside the root websites directory.

To enable parent paths for a website, please follow these steps:

  1. Log into your server through Terminal Services or Remote Desktop Connection.
  2. Click Start, select Programs, select click Administrative Tools and click Internet Information Services.

3. Expand the Server Name, expand Web Sites and find the domain name.

4. Right-click on the domain name and select Properties

5. On the Home Directory Tab under Application Settings click Configuration.

6. On the Options tab, check Enable parent paths

7. Click OK

SQL Server 2005 Features Comparison

September 17th, 2009

The Microsoft SQL Server 2005 product family has been redesigned to better meet the needs of each customer segment with four new editions: Express, Workgroup, Standard, and Enterprise. As a low-cost mainstream database, SQL Server 2005 delivers unprecedented value and functionality compared with competitive solutions. The four new editions offer a range of features, from high availability and robust scalability to advanced business intelligence tools, designed to empower the people across your organization through a more secure, reliable, and productive data management platform. Additionally, with the reduced application downtime, robust scalability and performance, and tight security controls, SQL Server 2005 represents a dramatic step forward in supporting the most demanding enterprise systems in the world. Because SQL Server is part of Windows Server System, you will also receive the added benefits through the increased manageability and integration that result from the common engineering strategy implemented across Windows Server System products.

To sign up for our Windows Dedicated Server solutions please go here:

In the following table, the “Comments” column provides comments on the specified feature. Numbers next to check marks indicate footnotes that appear at the bottom of the page. SQL Server 2005 Developer Edition and Evaluation Edition are not listed in the tables. These editions have the same feature set as the Enterprise Edition; the only difference between these editions is the licensing policies.

Scalability and Performance
Feature Express Workgroup Standard Enterprise Comments
Number of CPUs 1 2 4 No Limit Includes support for multicore processors.
RAM 1 gigabyte (GB) 3 GB Operating system maximum Operating system maximum Memory limited to maximum supported by operating system.
64-bit Support Windows on Windows (WOW) WOW checked checked *
Database Size 4 GB No Limit No Limit No Limit *
Partitioning * * * checked Support for large-scale databases
Parallel Index Operations * * * checked Parallel processing of indexing operations
Indexed Views * * * checked Indexed view creation is supported in all editions. Indexed view matching by the query processor is supported only in Enterprise Edition.
High Availability
Feature Express Workgroup Standard Enterprise Comments
Database Mirroring * * checked1 checked Advanced high availability solution that includes fast failover and automatic client redirection
Failover Clustering * * checked2 checked *
Backup Log-shipping * checked checked checked Data backup and recovery solution
Online System Changes checked checked checked checked Includes Hot Add Memory, dedicated administrative connection, and other online operations
Online Indexing * * * checked *
Online Restore * * * checked *
Fast Recovery * * * checked Database available when undo operations begin
1 Single REDO thread and the safety setting is always on.
2 Supports only two nodes.
Manageability
Feature Express Workgroup Standard Enterprise Comments
Auto Tuning checked checked checked checked Automatically tunes database for optimal performance.
Profiler *1 *2 checked checked *
SQL Server Management Studio Express See Comments checked checked checked Easy-to-use graphical management tool available as a separate download or included with the SQL Server Express w/Advanced Services download
Management Studio * checked checked checked Full management platform for SQL Server; includes Business Intelligence (BI) Development Studio.
Database Tuning Advisor * * checked checked Automatically suggests enhancements to your database architecture to improve performance.
Serviceability Enhancements checked checked checked checked Dynamic management views and reporting enhancements.
Full-text Search See comments checked checked checked Available for SQL Server Express in the SQL Server Express w/ Advanced Services download
SQL Agent Job Scheduling Service * checked checked checked *
1 This edition can be profiled from a Standard or Enterprise Edition of SQL Server 2005.
2 This edition can be profiled from a Standard or Enterprise Edition of SQL Server 2005.
Security
Feature Express Workgroup Standard Enterprise Comments
Advanced Auditing, Authentication, and Authorization checked checked checked checked *
Data Encryption and Key Management checked checked checked checked Built-in data encryption for advanced data security.
Integration with Microsoft Baseline Security Analyzer checked checked checked checked Scans your system to check for common security vulnerabilities.
Integration with Microsoft Update checked checked checked checked *
Programmability
Feature Express Workgroup Standard Enterprise Comments
Stored Procedures, Triggers, and Views checked checked checked checked *
T-SQL Enhancements checked checked checked checked Includes exception handing, recursive queries, and support for new data types.
Common Language Runtime and .NET Integration checked checked checked checked *
User-defined Types checked checked checked checked Extend the server with your own custom data types.
Native XML checked checked checked checked Includes XML indexing and full-text XML search.
XQuery checked checked checked checked *
Notification Services * * checked checked Allows the building of advanced subscription and publication applications.
Service Broker See comments checked checked checked SQL Server Express can exchange messages with other editions. Messages between instances of SQL Server Express must be routed through another edition.
Integration and Interoperability
Feature Express Workgroup Standard Enterprise Comments
Import/Export checked checked checked checked *
Integration Services with Basic Transforms * * checked checked Provides graphical extract, transform, and load (ETL) capabilities.
Integration Services Advanced Transforms * * * checked Includes data mining, text mining, and data cleansing.
Merge Replication checked1 checked2 checked checked *
Transactional Replication checked3 checked4 checked checked *
Oracle Replication * * * checked Transactional replication with an Oracle database as a publisher
Web Services (HTTP Endpoints) * * checked checked Support for native Web services, Web Services Description Language (WSDL), and Web authentication
1 Subscriber only.
2 Publish to up to 25 subscribers.
3 Subscriber only.
4 Publish to up to five subscribers.
Business Intelligence
Feature Express Workgroup Standard Enterprise Comments
Report Server See Comments checked checked checked Report Server is available for SQL Server Express in the SQL Server Express with Advanced Services download.
Report Builder * checked checked checked End-user reporting tool
Reporting Data Sources 1

*

checked checked checked *
Scale Out Report Servers * * * checked *
Data Driven Subscriptions * * * checked *
Infinite Clickthrough * * * checked *
Data Warehousing * * checked checked *
Star Query Optimization checked checked checked checked *
SQL Analytical Functions checked checked checked checked *
BI Development Studio See Comments

2

checked3 checked checked Integrated development environment for building and debugging data integration, OLAP, data mining, and reporting solutions.
Enterprise Management Tools * checked checked checked Integration with SQL Management Studio, SQL Server Profiler, SQL Server Agent, Backup/Restore.
Native Support for Web Services
(Service Oriented Architectures)
checked4 checked5 checked checked Allows access to data from any device.
Analysis Services * * checked checked Powerful analytics and data mining capabilities.
Unified Dimensional Model (UDM) * * checked checked Enterprise business data model enables fast, interactive, ad hoc analysis of large data sets. Builds smarter reports that leverage centralized business logic and key performance indicators (KPIs), as well as the performance of UDM.
Business Analytics * * checked checked Multidimensional Expression (MDX) scripts and MDX debugger, .NET stored procedures, Time Intelligence, KPI Framework.
Advanced Business Analytics * * * checked Account intelligence, metadata translation, perspective and semi-additive measures.
Proactive Caching * * * checked Provides automated caching for greater scalability and performance.
Advanced Data Management * * * checked Partitioned cubes, parallel processing, server synchronization.
Full Writeback Support * * * checked Dimension and cell writeback
Data Mining * * checked checked Nine algorithms including decision and regression trees, clustering, logistic and linear regression, neural networks, naive bayes, association, sequence clustering, and time series. Build smarter reports that leverage centralized business logic and KPIs, as well as the performance of UDM.
Advanced Performance Tuning * * * checked Additional options for tuning data mining models for the highest accuracy, performance, and scalability.
SQL Server Integration Services Data Flow Integration * * * checked Perform data mining prediction and training operations directly in your operational data pipelines.
Text Mining * * * checked Convert unstructured text data to structured data for analysis via reporting, online analytical processing (OLAP), or data mining.
1 This edition can be profiled from a Standard or Enterprise Edition of SQL Server 2005.
2 Report Designer only.
3 Report Designer only.
4 Reporting Services only.
5 Reporting Services only.

Installing DNS On Windows 2003

September 17th, 2009

Installing DNS On Windows 2003

This tutorial will cover the installation of DNS on a Windows 2003 system. By reading through this tutorial you will learn about caveats that need to be noted when installing one of the most important services on a Windows network.

Ensure that you have Windows Server 2003 Std is installed and that a static IP address has been assigned. Figure 1.1 depicts how DNS should be configured and under the advanced TCP/IP settings.  In the DNS settings you must point the server to itself for DNS resolution.  If external internet names need to be resolved you can configure a forwarder so that the requests are sent to the DNS server of the ISP or an external DNS server.  Selecting a DNS server that is consistently up is paramount as external name resolution rests on this resource.

Figure 1.1

Install Microsoft DNS Server

Click on Start, Control Panel, Add or Remove Programs and then on Add or Remove Windows Components.  Then click on Components list, then click on Networking Services and then click Details, select the Domain Name System (DNS) check box, and then click OK. Follow the below figure 1.2 for guidance.

Figure 1.2

After installing DNS you will need to test if the installation was successful and if you are able to resolve names.  Nslookup is a built-in utility that can be used to test if the service has been installed and configured correctly.  Remember to test both internal and external names before concluding your tests. After typing Nslookup it connects to the configured server within your TCP/IP properties or if you run this command form a client it will connect to the DNS server handed out by DHCP.  You will then be able to type in the name you want to lookup i.e. www.google.com or machine.localdomain.net it will then resolve the name to an IP address if this happens you have installed and configured DNS correctly.

C:\>nslookup
*** Default servers are not available
Default Server:  UnKnown
Address:  127.0.0.1
help
Commands:   (identifiers are shown in uppercase, [] means optional)

NAME - print info about the host/domain NAME using default server
NAME1 NAME2 - as above, but use NAME2 as server
help or ? - print info on common commands
set OPTION - set an option
All - print options, current server and host
[no]debug - print debugging information
[no]d2 - print exhaustive debugging information
[no]defname - append domain name to each query
[no]recurse - ask for recursive answer to query
[no]search - use domain search list
[no]vc - always use a virtual circuit
domain=NAME - set default domain name to NAME
srchlist=N1[/N2/.../N6] - set domain to N1 and search list to N1,N2, etc.
root=NAME - set root server to NAME
retry=X - set number of retries to X
timeout=X - set initial time-out interval to X seconds
type=X - set query type (ex. A,ANY,CNAME,MX,NS,PTR,SOA,SRV)
querytype=X - same as type
class=X - set query class (ex. IN (Internet), ANY)
[no]msxfr - use MS fast zone transfer
ixfrver=X - current version to use in IXFR transfer request
server NAME - set default server to NAME, using current default server
lserver NAME - set default server to NAME, using initial server
finger [USER] - finger the optional NAME at the current default host
root - set current default server to the root
ls [opt] DOMAIN [> FILE] - list addresses in DOMAIN (optional: output to FILE)
-a - list canonical names and aliases
-d - list all records
-t TYPE - list records of the given type (e.g. A,CNAME,MX,NS,PTR etc.)
view FILE - sort an ‘ls’ output file and view it with pg
exit - exit the program.

Install MySQL on a Windows Server

September 17th, 2009

Install MySQL on a Windows Server

The following article explains how to install MySQL on a Windows Server. The process involves downloading the latest version of MySQL directly to your Windows server and then installing the software. MySQL is a free product. Once installed, you may begin creating and using MySQL databases on your server

To install MySQL, please follow these steps:

  1. Log into your server through Terminal Services or Remote Desktop Connection.
  2. Open a Web browser and load http://dev.mysql.com/downloads/mysql/4.1.html
  3. Download Windows (x86) ZIP/Setup.exe
  4. Unzip the file you downloaded above and run Setup.exe.
  5. Click Next to begin the installation wizard.
  6. Select Typical Installation and click Next.
  7. Click Install. The installation will take a few moments.
  8. Click Next until you reach the Wizard Completed screen.
  9. Check Configure the MySQL Server now and click Finish.
  10. Click Next to begin the MySQL Server Instance Configuration Wizard.
  11. Select Detailed Configuration and click Next.
  12. Select Server Machine and click Next.
  13. Select Multifunctional Database and click Next
    .
  14. For InnoDB Tablespace Settings, leave the default settings and click Next.
  15. Select Online Transaction Processing (OLTP) and click Next.
  16. Check Enable TCP/IP Networking, leave the default Port Number and click Next.
  17. Select Standard Character Set and click Next.
  18. Check Install as Windows Service, uncheck Include BIN directory in Windows PATH and click Next.

  19. Enter a password for your root user, uncheck Create an Anonymous Account and click Next.
  20. Click Execute to complete the installation.

Installing PHP on a Windows Server

September 17th, 2009

How do I install PHP on a Windows Server?

The following article explains how to install PHP on a Windows Server running IIS 6. The process involves downloading the latest version of PHP directly to your Windows server and then installing the software. PHP is a free product.

To install PHP, please follow these steps:

  1. Log into your server through Terminal Services or Remote Desktop Connection.
  2. Open a Web browser and load http://www.php.net/downloads.php
  3. Download the Windows PHP5.x ZIP package.
  4. Create a new directory, c:\PHP.
  5. Unzip the file you downloaded above into c:\PHP.
  6. Create a new directory, C:\PHP\phpsessions.
  7. Right click the C:\PHP folder and select Properties.
  8. On the Security Tab click Add.
  9. Type IUSR_COMPUTERNAME (where computer name is the name of your computer) in the text area, click Check Names and then click OK.
  10. Select the IUSR_COMPUTERNAME user, check the Full Control box and click OK.
  11. Open C:\PHP\php.ini-dist in Notepad.
  12. Within the file, make the following replacements:
    • Replace ;extension=php_mysql.dll with extension=php_mysql.dll
    • Replace ;session.save_path = “/tmp” with session.save_path = “C:\PHP\phpsessions”
    • Replace session.gc_maxlifetime = 1440 with session.gc_maxlifetime = 43200
    • Replace SMTP = localhost with SMTP = smtp.yourdomain.com
    • Replace ;sendmail_from = me@example.comThis e-mail address is being protected from spam bots, you need JavaScript enabled to view it with sendmail_from = user@yourdomain.comThis e-mail address is being protected from spam bots, you need JavaScript enabled to view it
  13. Save the file as C:\windows\php.ini.
  14. Copy C:\PHP\libmysql.dll and C:\PHP\ext\php_mysql.dll to the C:\windows\system32 folder.
  15. Open IIS located under Control Panel -> Administrative Tools -> Internet Information Services (IIS) Manager.
  16. Right click Web Service Extensions and select Add a new Web service extension.
  17. Enter php as the Extension Name, check Set extension status to Allowed and Click Add.
  18. Enter the path to C:\PHP\php5isapi.dll and click OK.
  19. Right click Web Sites and select Properties.
  20. On the ISAPI Filters tab, click Add.
  21. Enter php as the Filter Name, enter C:\PHP\php5isapi.dll as the Executable and click OK.
  22. On the Home Directory tab, click Configuration.
  23. Click Add.
  24. Enter C:\PHP\php5isapi.dll as the Executable, enter php as the Extension and click OK.
  25. On the Documents Tab, click Add.
  26. Enter index.php and click OK.
  27. A popup box may appear asking if you want to apply the settings to certain websites. Choose specific websites to enable PHP on or Select All and click OK.
  28. Right click your Computer Name, expand All Tasks and click Restart IIS.
  29. Choose Restart IIS from the dropdown menu and click OK.

To test your installation of PHP, please follow these steps:

  1. Open up Notepad and create a new document.
  2. Add the following text into your new document: <?php phpinfo(); ?>
  3. Save this new file to your website root as phpinfo.php.
  4. In a Web browser, navigate to phpinfo.php.

How to use ASPMail to send email from a web page

September 17th, 2009

How to use the ASPMail component to send email from a web page

Using the component is pretty simple. It really only involves three main steps which are:

  1. Creating the object
  2. Setting the properties
  3. Calling the SendMail method

Send an email with ASPmail

The following code is an example of how to use AspMail from VBScript:

<%
Set Mailer = Server.CreateObject(“SMTPsvg.Mailer”)
Mailer.FromName = “Test Form”
Mailer.FromAddress= ” joebloggs@domainname.comThis e-mail address is being protected from spam bots, you need JavaScript enabled to view it
Mailer.RemoteHost = “mailhost.localisp.net”
Mailer.AddRecipient “John Smith”, “jsmith@another
domainname.com
Mailer.Subject = “Test Product!”
Mailer.BodyText = “Dear John” & VbCrLf & “Your test order has been processed!”
if Mailer.SendMail then
Response.Write “Mail sent…”
else
Response.Write “Mail send failure. Error was ” & Mailer.Response
end if
Set Mail = Nothing
%>

Form Handling

All or partial input for a message may come from a form. For example, a form posted to the server with a request method of GET (i.e.

) may provide the message recipient’s email address, subject and message text as follows:

Mailer.AddRecipient Request.QueryString(“ToName”), Request.QueryString(“ToAddress”)
Mailer.Subject = Request.QueryString(“Subject”)
Mailer.BodyText = Request.QueryString(“MsgBody”)

The form may also use the POST method (i.e. ) in which case the code would look as follows:

Mailer.AddRecipient Request.Form(“ToName”), Request.Form(“ToAddress”)
Mailer.Subject = Request.Form (“Subject”)
Mailer.BodyText = Request.Form (“MsgBody”)

You can use any mixture of static and dynamic data in setting the components properties as dictated by your needs. For example, you may wish to send the mail to a single user. In this case you could modify the code to look something like this:

Mailer.AddRecipient “John Smith”, ” jsmith@alocalhost.comThis e-mail address is being protected from spam bots, you need JavaScript enabled to view it
Mailer.Subject = Request.QueryString(“Subject”)
Mailer.BodyText = Request.QueryString(“MsgBody”)

Generic Form Handling

In some cases users may wish to use a number of different forms to send email with the same block of code. ASP allows you to loop through each QueryString or Form variable and append each one to string variable which is then assigned to the BodyText property.

strMsgHeader = “Form information follows” & vbCrLf
for each qryItem in Request.QueryString
strMsgInfo = strMsgInfo & qryItem & ” – ” & request.querystring(qryItem) & vbCrLf
next
strMsgFooter = vbCrLf & “End of form information”
Mailer.BodyText = strMsgHeader & strMsgInfo & strMsgFooter

To return form contents in the original form order your code might be…

strMsgHeader = “Form Information Follows: ” & vbCrLf
for i = 1 to Request.Form.Count
strMsgInfo = strMsgInfo & Request.Form.Key(i) & ” – ” & Request.Form.Item(i) & vbCrLf
next
strMsgFooter = vbCrLf & “End of form information”
Mailer.BodyText = strMsgHeader & strMsgInfo & strMsgFooter

PHP Freelancer