<?php
// Create a new statement
$stmt = mssql_init('NewBlogEntry');
// Some data strings
$title = 'Test of blogging system';
$content = 'If you can read this, then the new system is compatible with MSSQL';
// Bind values
mssql_bind($stmt, '@author', 'Felipe Pena', SQLVARCHAR, false, false, 60);
mssql_bind($stmt, '@date', '08/10/2008', SQLVARCHAR, false, false, 20);
mssql_bind($stmt, '@title', $title, SQLVARCHAR, false, false, 60);
mssql_bind($stmt, '@content', $content, SQLTEXT);
// Execute the statement
mssql_execute($stmt);
// And we can free it like so:
mssql_free_statement($stmt);
?>