Wednesday, February 15, 2012

How to get WAMP to work with MSSQL


Download Wamp.
Next, Download the newest add-on of php.
Next, download ntwdblib.dll: HERE

Steps:
1) Install WAMP 
2) Install latest php addon.
3) Click on the WAMP icon -> PHP -> Version and select 5.3.1. 
4) Click on the WAMP icon -> PHP -> PHP Extensions then check php_mssql andphp_pdo_mssql
(Wamp will restart and give you few errors, ignore them)
5) Restart WAMP one more time to ensure settings are saved. 
6) Finally, place ntwdblib file in the two following directories:
wamp\bin\php\php5.3.1
wamp\bin\apache\apache2.2.11\bin
7) Restart wampserver, and you're finished!

Still the problem exists, open php.ini file and edit the following line
  ;extension=php_mssql.dll
Uncomment the above line then it looks like
   extension=php_mssql.dll

Save the file and restart the Wamp server.

Below is the sample php script for MS SQL connection


<?php

$Server = "localhost";
$User = "your_name";
$Pass = "your_password";
$DB = "examples";

//connection to the database
$dbconn = mssql_connect($Server, $User, $Pass)
  or die("Couldn't connect to SQL Server on $Server");

//select a database to work with
$selected = mssql_select_db($DB, $dbconn)
  or die("Couldn't open database $myDB");

//declare the SQL statement that will query the database
$query = "SELECT name from test ";

//execute the SQL query and return records
$result = mssql_query($query);

$numRows = mssql_num_rows($result);
echo "<h1>" &#46; $numRows &#46; " Row" &#46; ($numRows == 1 ? "" &#58; "s") &#46; " Returned </h1>";

//display the results
while($row = mssql_fetch_array($result))
{
  echo "<br>" &#46; $row["name"&#93;;
}
//close the connection
mssql_close($dbconn);
?>



For XAMPP:

Edit the below code in php.ini file
;extension=php_mssql.dll
Uncomment the above line then it looks like
extension=php_mssql.dll


Monday, January 2, 2012

Wiki Engines


I have listed down the best wiki engines.

Mediawiki (Wikipedia) -- End Users/Desktop, Education
Tikiwiki -- Needing not just a robust wiki, but a full-featured CMS/Groupware with a bug tracker, discussion forums, blogs, etc.
DokuWiki -- Private, small to medium companies
Foswiki -- Enterprise, Corporate, Business, Intranets, Personal use, Community building, Educational, Intranet, Extranet

BananaDance -- Users,Buidling entire websites,Building product manuals,building community websites, and of course building anything needing a wiki!

I just compared above wiki engines using wikimatrix.org click here to compare. Wikipedia provides a list of wiki engine Wikipedia list. To compare all the wiki's available, use this website Wikimatrix