<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>WebProNews &#187; Modules</title>
	<atom:link href="http://www.webpronews.com/tag/modules/feed" rel="self" type="application/rss+xml" />
	<link>http://www.webpronews.com</link>
	<description>Breaking News in Tech, Search, Social, &#38; Business</description>
	<lastBuildDate>Mon, 13 Feb 2012 04:32:37 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Yahoo Alpha Goes Beta</title>
		<link>http://www.webpronews.com/yahoo-alpha-goes-beta-2007-04</link>
		<comments>http://www.webpronews.com/yahoo-alpha-goes-beta-2007-04#comments</comments>
		<pubDate>Thu, 05 Apr 2007 00:04:16 +0000</pubDate>
		<dc:creator>WebProNews Staff</dc:creator>
				<category><![CDATA[Search]]></category>
		<category><![CDATA[beta]]></category>
		<category><![CDATA[Custom]]></category>
		<category><![CDATA[Digital]]></category>
		<category><![CDATA[Modules]]></category>
		<category><![CDATA[Yahoo]]></category>
		<category><![CDATA[Yahoo Alpha]]></category>

		<guid isPermaLink="false">http://www.webpronews.com/?p=36769</guid>
		<description><![CDATA[This isn't a typo: Yahoo!7 is running the search Alpha beta Down Under, offering a customizable start page people can equip with content modules from Yahoo's properties and others.
]]></description>
			<content:encoded><![CDATA[<p>This isn&#8217;t a typo: Yahoo!7 is running the search Alpha beta Down Under, offering a customizable start page people can equip with content modules from Yahoo&#8217;s properties and others.<br />
<span id="more-36769"></span></p>
<table width="400" cellspacing="0" cellpadding="2" border="0">
<tbody>
<tr>
<td align="center"><img width="400" height="200" border="0" class="irImage" alt="Yahoo Alpha Goes Beta" title="Yahoo Alpha Goes Beta" src="http://images.ientrymail.com/webpronews/article_pics/yahoo_alpha.jpg" /></td>
</tr>
<tr>
<td align="right" class="caption" style="padding-bottom: 10px; padding-left: 45px; padding-right: 45px;">Yahoo Alpha Goes Beta</td>
</tr>
<tr>
<td align="center" class="caption" style="padding-bottom: 0px;"><img width="334" height="21" alt="Who Can Compete with Google?" src="http://images.ientrymail.com/webpronews/salon/complete.gif" /></td>
</tr>
</tbody>
</table>
<p>It&#8217;s new, it&#8217;s pastel blue, it&#8217;s Web 2&#8230;dot 0. It&#8217;s <a href=http://au.alpha.yahoo.com>Yahoo Alpha (beta)</a>, ha ha. </p>
<p>
Until Amit Agarwal posted the news about Yahoo Alpha at <a href=http://labnol.blogspot.com/2007/04/yahoo-alpha-google-custom-search-engine.html>Digital Inspiration</a>, the project was running quietly for users in Australia and New Zealand on Yahoo!7, a partnership between Yahoo and the Seven Network.</p>
<p>
As module-based pages go (think Netvibes, Pageflakes, Google Personalized Home) Yahoo Alpha presents a much more economical design. Base choices for content modules on Alpha offer results from web or news search, Flickr, and Yahoo!7 Answers.</p>
<p>
They also go off-Yahoo property by making YouTube and Wikipedia results available in modules; users can also choose to have Sponsored Results, a module of paid search advertising, as part of Alpha. An option for custom modules permits users to set up blocks of content drawn from other websites.</p>
<p>
Agarwal guessed the Sponsored Results block could be a hint that Yahoo may match Google&#8217;s Custom Search Engine by sharing advertising revenue with Alpha&#8217;s users.</p>
<p>
A search for <a href=http://au.alpha.yahoo.com/search/web?p=tori+amos#0f1,-1,2b1,3cb1,4b1,5cb1,6c1,7c1>Tori Amos</a> on Alpha, with the Flickr and YouTube modules open, brings web, photo, and video search results for the artist to the front of the page.</p>
<p>
While search is at the core of Alpha&#8217;s usefulness, it appears to be just part of the equation. People can create an instant personalized search, with a variety of content from inside and outside Yahoo, on any topic. </p>
<p>
Alpha isn&#8217;t the first product to do this, but if Yahoo chooses to push Alpha globally in conjunction with their very popular Answers product, it might make a good cornerstone for Yahoo to finally build a social networking strategy on, with all of the pieces they have acquired over the past couple of years.</p>
<p>
<small></small></p>
]]></content:encoded>
			<wfw:commentRss>http://www.webpronews.com/yahoo-alpha-goes-beta-2007-04/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>More choice with WordPress widgets</title>
		<link>http://www.webpronews.com/more-choice-with-wordpress-widgets-2006-03</link>
		<comments>http://www.webpronews.com/more-choice-with-wordpress-widgets-2006-03#comments</comments>
		<pubDate>Mon, 13 Mar 2006 21:20:24 +0000</pubDate>
		<dc:creator>Neville Hobson</dc:creator>
				<category><![CDATA[Business]]></category>
		<category><![CDATA[blog]]></category>
		<category><![CDATA[Modules]]></category>
		<category><![CDATA[Sidebar]]></category>
		<category><![CDATA[typepad]]></category>
		<category><![CDATA[widgets]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://www.webpronews.com/?p=27593</guid>
		<description><![CDATA[Some interesting moves going on with the free <a href="http://www.wordpress.com/" class="bluelink">WordPress.com</a> hosted blog service in the area of ease of use in design and layout that adds to its attraction as an alternative to <a href="http://www.typepad.com/" class="bluelink">TypePad</a>, the hosted service you pay for.
]]></description>
			<content:encoded><![CDATA[<p>Some interesting moves going on with the free <a href="http://www.wordpress.com/" class="bluelink">WordPress.com</a> hosted blog service in the area of ease of use in design and layout that adds to its attraction as an alternative to <a href="http://www.typepad.com/" class="bluelink">TypePad</a>, the hosted service you pay for.</p>
<p>Coming this week are <a href="http://lorelle.wordpress.com/2006/03/10/playing-with-wordpresscom-new-sidebar-widgets/" class="bluelink">WordPress Sidebar Widgets</a>, functionality that lets you click-and-drag elements around in your blog sidebar in as easy a fashion as you already can with <a href="http://www.sixapart.com/typepad/news/2005/12/adding_sidebar.html" class="bluelink">TypePad Typelists</a>.</p>
<p>I&#8217;m especially interested in this as I&#8217;ve been experimenting with <a href="http://www.nevillehobson.com/2006/03/11/excellent-hack-for-k2-wordpress-theme/" class="bluelink">Sidebar Modules for K2</a>, the theme that this blog uses on the <a href="http://wordpress.org/" class="bluelink">WordPress</a> platform/application you install on your own server (ie, not the hosted service). After some initial difficulties with it, I&#8217;ve now got the modules working fine. These modules work in a similar fashion to the new widgets, ie, Ajax/JavaScript based that you click-and-drag on your screen to position them where you want. (Modules, widgets &#8211; what&#8217;s in a name?)</p>
<p>What&#8217;s key about this functionality is that you don&#8217;t need to know anything about the underlying code, nor have to dive into that code, in order to include and lay out the elements you want in your blog sidebar. That ease-of-use is one of TypePad&#8217;s key appeals. And the sidebar is a pretty important feature of your blog that provides visitors with a structure to enable them to easily navigate through your blog to find the things they&#8217;re interested in or that you want them to see, and which doesn&#8217;t distract from the primary content, ie, your posts.</p>
<p>I also have a <a href="http://nevon.wordpress.com/" class="bluelink">WordPress.com blog</a> which I&#8217;ve not really done much with. Now&#8217;s the time for a bit more experimenting.</p>
<p>I&#8217;d imagine that widget functionality will make its way across to the WordPress application soon. Then you&#8217;re in an interesting area of comparison with <a href="http://www.sixapart.com/movabletype/" class="bluelink">Movable Type</a> which, as far as I know, doesn&#8217;t have such functionality. Yet.</p>
<p>Speaking of K2, expectation is mounting about the coolness of the next version (it&#8217;s currently in beta). <a href="http://binarybonsai.com/archives/2006/03/12/wordpress-widgets/" class="bluelink">According to developer Michael Heileman</a>:</p>
<p><i>[] The next version of K2 will, and I&#8217;m being pretty humble here, blow itself out of the water. Any day now.</i></p>
<p>Very interesting choices for bloggers.</p>
<p>Add to <a href="javascript:void   window.open('http://digg.com/submit?phase=2&#038;url='+encodeURIComponent(window.location.href)+'&#038;ei=UTF-8','popup','width=520px,h  eight=420px,status=0,location=0,resizable=1,scrollbars=1,left=100,top=50',0)">DiggThis</a></p>
<p>Neville Hobson is the author of the popular <b><a href="http://www.nevillehobson.com/">NevilleHobson.com blog</a></b> which focuses on business communication and technology.
<p>Neville is currentlly the VP of New Marketing at <a href="http://www.crayonville.com/">Crayon</a>. Visit Neville Hobson&#8217;s blog: <b><a href="http://www.nevillehobson.com/">NevilleHobson.com</a></b>. </p>
]]></content:encoded>
			<wfw:commentRss>http://www.webpronews.com/more-choice-with-wordpress-widgets-2006-03/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Excellent hack for K2 WordPress theme</title>
		<link>http://www.webpronews.com/excellent-hack-for-k-wordpress-theme-2006-03</link>
		<comments>http://www.webpronews.com/excellent-hack-for-k-wordpress-theme-2006-03#comments</comments>
		<pubDate>Sat, 11 Mar 2006 21:54:57 +0000</pubDate>
		<dc:creator>Neville Hobson</dc:creator>
				<category><![CDATA[Business]]></category>
		<category><![CDATA[blog]]></category>
		<category><![CDATA[hack]]></category>
		<category><![CDATA[Modules]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Sidebar]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://www.webpronews.com/?p=27549</guid>
		<description><![CDATA[One of the things I continue to find a bit tricky with <a href="http://wordpress.org/" class="bluelink">WordPress</a> and the customized <a href="http://binarybonsai.com/wordpress/k2/" class="bluelink">K2 theme</a> I have on <a href="http://www.nevillehobson.com/" class="bluelink">this blog</a> is tweaking the sidebar to include or exclude elements on certain pages.
]]></description>
			<content:encoded><![CDATA[<p>One of the things I continue to find a bit tricky with <a href="http://wordpress.org/" class="bluelink">WordPress</a> and the customized <a href="http://binarybonsai.com/wordpress/k2/" class="bluelink">K2 theme</a> I have on <a href="http://www.nevillehobson.com/" class="bluelink">this blog</a> is tweaking the sidebar to include or exclude elements on certain pages.</p>
<p>Until now, I&#8217;ve been digging into the code in the sidebar <a href="http://en.wikipedia.org/wiki/PHP" class="bluelink">PHP</a> file and, through trial and error (and mostly luck), have ended up with results I&#8217;ve more or less been happy with. No dreaded parse error messages after my tweaking nor major display disasters.</p>
<p>All this has been fine for what displays on <a href="http://www.nevillehobson.com/" class="bluelink">this blog&#8217;s</a> home page. Where I&#8217;ve really run into difficulties is getting things to display or not display in the sidebar on other pages such as individual posts, archive pages, category pages, etc. For instance, I&#8217;ve never been able to get the RSS subscription options to display on any page other than the home page. This is all to do with the conditional statements in the PHP code where I&#8217;ve scratched my head over code like this -</p>
<p><i>&lt;?php /* If this is a category archive */ } elseif (is_category()) { ?&gt;&lt;?php printf( __(&#8216;You are currently browsing the %1$s weblog archives for the \&#8217;%2$s\&#8217; category.&#8217;), &lt;a href=&#8221; . get_settings(&#8216;siteurl&#8217;) .&#8217;&#8221;&gt;&#8217; . get_bloginfo(&#8216;name&#8217;) . &lt;/a&gt;&#8217;, single_cat_title(&#8221;, false) ) ?&gt;</i></p>
<p>But no more!</p>
<p>I&#8217;ve just installed a very nifty hack for K2 called <a href="http://getk2.com/forum/showthread.php?t=37" class="bluelink">Sidebar Modules</a> written by <a href="http://nybblelabs.org.uk/" class="bluelink">Ben Sherratt</a>. As described by Ben:</p>
<p><i>A hack for K2 to allow you to edit the contents of your sidebar. Drag and drop the modules, add your own custom content, decide what to display where, and other general funky stuff.</i></p>
<p>Funky indeed. It works a treat. It makes it so simple and easy to do exactly what you want to do, shielding you almost completely from any code editing. Reminds me of the ease of use with <a href="http://www.sixapart.com/typepad/news/2005/12/adding_sidebar.html" class="bluelink">TypePad Typelists</a>.</p>
<p>If you use K2 on your WordPress 2.x blog, this hack is indispensable. Ben, thanks for developing it.</p>
<p>Speaking of WordPress, <a href="http://wordpress.org/development/2006/03/security-202/" class="bluelink">version 2.0.2 has just been released</a>. This is described as a security fix. Looks like <a href="http://trac.wordpress.org/query?milestone=2.0.1" class="bluelink">quite a few bug fixes</a> as well. I&#8217;m currently running 2.0.1 and do plan to upgrade. Soon.</p>
<p>[Edit] I&#8217;ve encountered a little problem so I&#8217;ve disabled Sidebar Modules for the moment. <a href="http://getk2.com/forum/showthread.php?t=453" class="bluelink">Help requested</a> in the <a href="http://getk2.com/forum/" class="bluelink">K2 Forum</a>.</p>
<p>Add to  <a href="javascript:void   window.open('http://digg.com/submit?phase=2&#038;url='+encodeURIComponent(window.location.href)+'&#038;ei=UTF-8','popup','width=520px,h  eight=420px,status=0,location=0,resizable=1,scrollbars=1,left=100,top=50',0)">DiggThis</a>  | <a href="javascript:void   window.open('http://myweb2.search.yahoo.com/myresults/bookmarklet?t='+encodeURIComponent(document.title)+'&#038;u='+encodeURICompo  nent(window.location.href)+'&#038;ei=UTF-8','popup','width=520px,height=420px,status=0,location=0,resizable=1,scrollbars=1,left=10  0,top=50',0)">Yahoo! My Web</a></p>
<p>Neville Hobson is the author of the popular <b><a href="http://www.nevillehobson.com/">NevilleHobson.com blog</a></b> which focuses on business communication and technology.
<p>Neville is currentlly the VP of New Marketing at <a href="http://www.crayonville.com/">Crayon</a>. Visit Neville Hobson&#8217;s blog: <b><a href="http://www.nevillehobson.com/">NevilleHobson.com</a></b>. </p>
]]></content:encoded>
			<wfw:commentRss>http://www.webpronews.com/excellent-hack-for-k-wordpress-theme-2006-03/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Creating Perl Modules for Web Sites</title>
		<link>http://www.webpronews.com/creating-perl-modules-for-web-sites-2005-09</link>
		<comments>http://www.webpronews.com/creating-perl-modules-for-web-sites-2005-09#comments</comments>
		<pubDate>Tue, 20 Sep 2005 19:35:59 +0000</pubDate>
		<dc:creator>A.P. Lawrence</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[Modules]]></category>
		<category><![CDATA[perl]]></category>
		<category><![CDATA[Web]]></category>

		<guid isPermaLink="false">http://www.webpronews.com/?p=23212</guid>
		<description><![CDATA[When you are writing your own code, you are more apt to use someone else's module than write your own, unless your project gets fairly large and complex.
]]></description>
			<content:encoded><![CDATA[<p>When you are writing your own code, you are more apt to use someone else&#8217;s module than write your own, unless your project gets fairly large and complex.</p>
<p>Small scripting tasks just don&#8217;t need the advantages modules offer. However, there is a case where modules might make perfect sense: web server cgi scripts often repeat the same tasks. Putting those common features into a module can make your web scripting easier.</p>
<p>For example, I need to call Google&#8217;s ad generating code from just about any script that creates a page. I could just hard code it into every script, but suppose I want to change the way it displays or abandon Google entirely and replace the ads with something else? Putting the code in a module other scripts can call gives me that flexibility.</p>
<p>Another advantage to keeping the code separate is that I don&#8217;t have to worry about clashing variable names: variables I use in the module won&#8217;t conflict with variables in the calling script and vice versa.</p>
<p>Modules aren&#8217;t difficult to create: </p>
<p><code>package MyStuff;<br />
require Exporter;</p>
<p>our @ISA=qw(Exporter);<br />
our @EXPORT=qw(newad midad);<br />
our $VERSION=1.00;</p>
<p>sub newad {<br />
..<br />
}</p>
<p>sub midad {<br />
..<br />
}</code></p>
<p>Fill in the code, and that&#8217;s a working module. I have it in MyStuff.pm, and call it from any script:</p>
<p><code>#!/usr/bin/perl5<br />
use MyStuff;<br />
..<br />
newad();<br />
..</code></p>
<p>Modules do have to return a true value; you&#8217;ll often see them end with &#8220;1;&#8221; to be sure of that.</p>
<p>That&#8217;s all it takes. MyStuff.pm does have to be placed somewhere in @INC; I put it at /usr/local/lib//perl5/site_perl/5.8.4/MyStuff.pm</p>
<p>*Originally published at <a href="http://www.aplawrence.com">APLawrence.com</a></p>
<p>A.P. Lawrence provides SCO Unix and Linux consulting services http://www.pcunix.com</p>
]]></content:encoded>
			<wfw:commentRss>http://www.webpronews.com/creating-perl-modules-for-web-sites-2005-09/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Great Plains Sales Order Processing and Invoicing Modules  Tips for consultant</title>
		<link>http://www.webpronews.com/great-plains-sales-order-processing-and-invoicing-modules-tips-for-consultant-2004-12</link>
		<comments>http://www.webpronews.com/great-plains-sales-order-processing-and-invoicing-modules-tips-for-consultant-2004-12#comments</comments>
		<pubDate>Wed, 15 Dec 2004 17:57:10 +0000</pubDate>
		<dc:creator>Andrew Karasev</dc:creator>
				<category><![CDATA[Business]]></category>
		<category><![CDATA[Modules]]></category>
		<category><![CDATA[sales]]></category>
		<category><![CDATA[Tips]]></category>

		<guid isPermaLink="false">http://www.webpronews.com/?p=13309</guid>
		<description><![CDATA[Microsoft Great Plains - main Microsoft Business Solutions application for US and Latin American (except Brazil, where MBS promotes Navision) markets is built with multiple modules.  In the case of Sales automation you - software selection specialist should consider two Microsoft Great Plains modules: Sales Order Processing (SOP) and Invoicing.  You should understand the difference between the two and see which one is the best fit for your company.  Let's consider two modules SOP and Invoicing.  We'll give you non formal view, based on our consulting practice.
]]></description>
			<content:encoded><![CDATA[<p>Microsoft Great Plains &#8211; main Microsoft Business Solutions application for US and Latin American (except Brazil, where MBS promotes Navision) markets is built with multiple modules.  In the case of Sales automation you &#8211; software selection specialist should consider two Microsoft Great Plains modules: Sales Order Processing (SOP) and Invoicing.  You should understand the difference between the two and see which one is the best fit for your company.  Let&#8217;s consider two modules SOP and Invoicing.  We&#8217;ll give you non formal view, based on our consulting practice.</p>
<p>Common Features.  SOP and Invoicing have these features  </p>
<p>	Sales Automation &#8211; this is obvious statement.  </p>
<p>	Posting to GL and Bank Reconciliation &#8211; this means that automated posting across Microsoft Great Plains is applicable to both modules as well as to the whole Great Plains design.</p>
<p>	Integration with Accounts Receivable (AR) module  &#8211; Great Plains has very clear structure of base modules: GL (core), AR, AP, IV (inventory control).  When you post document from SOP or Invoicing &#8211; system creates posted RM Sales transaction (Invoice) in Accounts Receivable module</p>
<p>	Integration with Inventory Control Module &#8211; both modules are integrated with Inventory Control &#8211; this means that you can select items from the inventory as well as non inventoried items and have them as Invoice lines.</p>
<p>Sales Order Processing Additional Features.  These are what you don&#8217;t have in Invoicing  </p>
<p>	Quote/Sales Order/Back Order/Return &#8211; you have workflow.  You can start with quotation, then you can transfer quote to sales order (with Items allocation or without it in Inventory control).  Then sales order can be transferred to Invoice or Backorder (in the case of shortage)  </p>
<p>	Process Holds &#8211; you can have holds with password protection placed on the way of transferring quote to invoice or order.  Other holds functions are: printing, fulfilling and posting.  However we would like to tell you about our experience.  In 10+ years of our consulting practice we had only couple of clients who used this holds feature</p>
<p>	Quote/Order/Invoice types &#8211; you can define these types and have different workflows associated with each of them.  Imagine &#8211; Internet Orders you transfer to internet invoices, government quotes you either void or transfer to government orders, etc.</p>
<p>Do I need consultant?  It is probably good idea to have consultant to do the upgrade.  We strongly recommend you to use consultant in the following cases</p>
<p>	You have Dexterity customization</p>
<p>	You are doing migration from Pervasive/Ctree to Microsoft SQL Server/MSDE, especially when you have third-parties without migration tools</p>
<p>	You have a lot or ReportWriter Modified Great Plains Reports</p>
<p>	You have old version of Great Plains: Dynamics or eEnterprise 6.0 or prior &#8211; in this case you can not appeal to Microsoft Technical Support &#8211; it is discontinued </p>
<p>	Your Great Plains has more than 20 users and you have to have upgrade done over the weekend &#8211; if it fails &#8211; you have business problems</p>
<p>	You don&#8217;t have support &#8211; in this case you have to select your Microsoft Business Solutions Partner and pay for the annual support/enhancement plan &#8211; you will get new registration key and will be ready for the upgrade</p>
<p>Andrew Karasev is Chief Technology Officer in Alba Spectrum Technologies  USA nationwide Microsoft CRM, Microsoft Great Plains customization company, based in Chicago, California, Texas, New York, Georgia and Florida and having locations in multiple states and internationally (<a href="http://www.albaspectrum.com">www.albaspectrum.com</a>), he is Dexterity, SQL, C#.Net, Crystal Reports and Microsoft CRM SDK developer.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.webpronews.com/great-plains-sales-order-processing-and-invoicing-modules-tips-for-consultant-2004-12/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Writing Pluggable ColdFusion Modules</title>
		<link>http://www.webpronews.com/writing-pluggable-coldfusion-modules-2003-06</link>
		<comments>http://www.webpronews.com/writing-pluggable-coldfusion-modules-2003-06#comments</comments>
		<pubDate>Thu, 05 Jun 2003 16:56:08 +0000</pubDate>
		<dc:creator>Stijn Dreezen</dc:creator>
				<category><![CDATA[Business]]></category>
		<category><![CDATA[coldfusion]]></category>
		<category><![CDATA[Modules]]></category>
		<category><![CDATA[writing]]></category>

		<guid isPermaLink="false">http://www.webpronews.com/?p=4590</guid>
		<description><![CDATA[When you have to bugfix, extend or review a ColdFusion application, there's a good chance that you'll find yourself browsing a directory tree representing the navigation on the site. Within these directories, typically some 40 or 50 files with names like list.cfm, insertform.cfm, insertaction.cfm, etc. reside.
]]></description>
			<content:encoded><![CDATA[<p>When you have to bugfix, extend or review a ColdFusion application, there&#8217;s a good chance that you&#8217;ll find yourself browsing a directory tree representing the navigation on the site. Within these directories, typically some 40 or 50 files with names like list.cfm, insertform.cfm, insertaction.cfm, etc. reside.</p>
<p>You know you&#8217;re going to be in trouble, because as so often happens, your customer does not know exactly what he wants, or where he wants it. And now he wants this specific part of the site to reside in another part of the site, or more parts, &#8230; with security on it&#8230; and with some extra functionality, and&#8230; oh, we don&#8217;t have enough budget for more.</p>
<p>Without even taking a look at the code, you know you&#8217;re going to have to redo a lot of links (yes yes, they were linked dynamically, but the way it&#8217;s tied up together now it&#8217;s just not possible to make it work within the context of the new location on the site).</p>
<p>If you start feeling a little guilty at that point, knowing you used to write code like this too, and you&#8217;re worried about the mental state of the guy who needs to look into your code afterwards, for any reason, here&#8217;s a small tutorial for a fairly simple technique which I often use, and it does the job. It ain&#8217;t exactly Fusebox (which I can recommend to you all; this technique works fine as a fuse too), but it is proper coding and it gets the job done. </p>
<p>Let&#8217;s kick off.</p>
<p>The one and only thing I actually have to tell you is to create all your links like so:</p>
<p>-=<code2>=-</p>
<p>What exactly do I mean by this?</p>
<p>Every hyperlink you create in this module posts to itself, keeping all URL variables intact. The <code>ReplaceList</code> carefully strips all the URL variables you wish to change, so that your next call to the module meets the settings you intend in this hyperlink.</p>
<p>The most important thing here is that pressing the hyperlink doesn&#8217;t affect any other code which may be executed outside of your module&#8217;s scope. Hence, we can plug the module anywhere.</p>
<p>Some Practical remarks:</p>
<p>We try to replace URL variables which may or may not exist.</p>
<p>Presetting these variables not only saves us from writing a lot of extra <code>isdefined</code> checks, but placing all these variables on top of the module gives us a quick and easy way to view all of the different behavours this module contains. We can get a good idea of what the module does, even without looking at the code, so as an example I &#8216;m going to preset some URL variables:</p>
<p>-=<code3>=-</p>
<p>Why the mm_ ????</p>
<p>The mm is derived from the module&#8217;s name: MyModule. Imagine we place this module next to another module which also contains an &#8220;action&#8221; variable, I don&#8217;t want the modules to affect each other&#8217;s variable settings, so by preceeding the variable name with an abbreviation of the module&#8217;s name, there is a good chance the modules will not conflict.</p>
<p>The code I pasted below is a sample module in which I try to show in code what I explained above. The code is not tested; I just wrote it top-to-bottom, but you will get the picture. I &#8216;m convinced you learn more from a sample piece of code that may throw an occasional error (so you have to investigate the code), rather than just plugging in working sample code and changing some static text without looking at how it really works.</p>
<p>-=<code4>=-</p>
<p><b>First published at <a href="http://www.developer.be">developer.be</a></b></p>
<p>Certified Advanced ColdFusion 5 Developer<br />
<br />
Focus on: coldfusion, content management / spectra , oracle.</p>
<p>Current projects: Writing a lightweight content management system (appframework), Kreynet IRC Network</p>
<p>http://www.marbie.net/</p>
]]></content:encoded>
			<wfw:commentRss>http://www.webpronews.com/writing-pluggable-coldfusion-modules-2003-06/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Ten Ways to Make the Most of IIS</title>
		<link>http://www.webpronews.com/ten-ways-to-make-the-most-of-iis-2003-05</link>
		<comments>http://www.webpronews.com/ten-ways-to-make-the-most-of-iis-2003-05#comments</comments>
		<pubDate>Fri, 02 May 2003 16:26:52 +0000</pubDate>
		<dc:creator>Matt J. Foley</dc:creator>
				<category><![CDATA[Business]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[Code]]></category>
		<category><![CDATA[IIS]]></category>
		<category><![CDATA[Modules]]></category>
		<category><![CDATA[Netcraft]]></category>

		<guid isPermaLink="false">http://www.webpronews.com/?p=4021</guid>
		<description><![CDATA[As an IIS administrator it sometimes gets downright annoying having to fend  off all the insults from Apache admins I meet claming innate server superiority.  Generally the discussion about Web administration starts first with all the  various security holes plaguing IIS and the negative press the platform garnered  over the last year.
]]></description>
			<content:encoded><![CDATA[<p>As an IIS administrator it sometimes gets downright annoying having to fend  off all the insults from Apache admins I meet claming innate server superiority.  Generally the discussion about Web administration starts first with all the  various security holes plaguing IIS and the negative press the platform garnered  over the last year.</p>
<p>Then it invariably moves to a discussion about how  <a href="http://www.netcraft.com">Netcraft</a>  and other stats sites show Apache as  the dominant server on the Web, or how a certain big site uses Apache, or how  there are so many cool <a href="http://httpd.apache.org/docs/mod/">modules</a>  to add to Apache.  Pointing out that scads of non-identified corporate in-house  servers run IIS, or that it too is a free server (since it comes with the  operating system), or that there are in fact plenty of cool  <a href="http://www.iisfaq.com/default.asp?View=P11">add-ons for IIS</a> (including  many that provide <a href="http://www.genusa.com/isapi/isapisrc.html">source code</a>)  &#8212; all this does little to dissuade these server chauvinists of their opinion.   Rather than whining about rude Apache admins, however, I thought it would be a more  useful response simply to write down some of the ways I&#8217;ve found of improving  IIS.  So without further delay here are my top ten tips for making the most  of your IIS. </p>
<p> <b>Tip 10: Customize Your Error Pages</b><br /> Although this is quite simple to do, few people seem to take advantage of it.  Just select the &#8220;Custom Errors&#8221; tab in MMC and map each error, such as 404, to  the appropriate HTML or ASP template.  Full details can be found  <a href="http://www.15seconds.com/issue/980210.htm">here</a>.  If you want  an even easier solution &#8212; or if you want to let developers handle the mapping  without giving them access to the MMC &#8212; use a product like  <a href="http://www.customerror.com">CustomError</a>. </p>
<p> <b>Tip 9: Dive into the MetaBase</b><br /> If you think Apache is powerful because it has a config file, then take a look  at the MetaBase.  You can do just about anything you want with IIS by editing  the MetaBase.  For example, you can create virtual directories and servers;  stop, start and pause Web sites; and create, delete, enable and disable  applications. </p>
<p> Microsoft provides a GUI utility called MetaEdit, somewhat similar to RegEdit,  to help you read from and write to the MetaBase.  Download the latest version  <a href="http://support.microsoft.com/default.aspx?scid=KB;EN-US;q232068&#038;">here</a>.   But to really  impress those UNIX admins &#8212; and to take full advantage  of the MetaBase by learning how to manipulate it programmatically &#8212; you&#8217;ll  want to try out the command-line interface, officially called the IIS  Administration Script Utility.  Its short name is adsutil.vbs and you&#8217;ll  find it in C:inetpubadminscripts, or else in  %SystemRoot%system32inetsrvadminsamples, together with a host of other  useful administrative scripts. </p>
<p> A word of caution though:  Just like Apache conf files, the MetaBase is pretty  crucial to the functioning of your Web server, so don&#8217;t ruin it.   <a href="http://support.microsoft.com/default.aspx?scid=KB;EN-US;Q300672&#038;">Back it up first</a>. </p>
<p> <b>Tip 8: Add spell checking to your URLs</b><br /> Apache folks always brag about cool little tricks that Apache is capable of  &#8212; especially because of the wealth of modules that can extend the server&#8217;s  basic functionality.  One of the coolest of these is the ability to fix URL  typos using a module called mod_speling. Well, thanks to the folks at Port80  Software, it now appears that IIS admins can do this trick too, using an  ISAPI filter called <a href="http://www.urlspellcheck.com">URLSpellCheck</a>.   You can check it out right on their site, by trying URLs like  <a href="http://www.urlspellcheck.com/fak.htm">www.urlspellcheck.com/fak.htm</a>,  <a href="http://www.urlspellcheck.com/faq1.htm">www.urlspellcheck.com/faq1.htm</a>  &#8212; or any other simple typo you care to make. </p>
<p> <b>Tip 7: Rewrite your URLs</b><br /> Cleaning your URLs has all sorts of benefits &#8212; it can improve the security  of your site, ease migration woes, and provide an extra layer of abstraction  to your Web applications. Moving from a ColdFusion to an ASP based site, for  example, is no big deal if you can  remap the URLs.  Apache users have long  bragged about the huge power of mod_rewrite &#8212; the standard Apache module for  URL rewriting.  Well, there are now literally a dozen versions of this type  of product for IIS &#8212; many of them quite a bit easier to use than mod_rewrite,  which tends to presume familiarity with  regular expression arcana.  Check out,  for example, <a href="http://www.qwerksoft.com/products/iisrewrite/">IIS ReWrite</a>  or <a href="http://www.isapirewrite.com/">ISAPI ReWrite</a>.  So brag no  more, Apache partisans. </p>
<p> <b>Tip 6: Add browser detection</b><br /> There are a lot of ways to build Web sites, but assuming everybody has a  certain browser or screen size is just plain stupid.  Simple JavaScript  sniff-scripts exist for client-side browser detection, but if you are an IIS  user you can do better with a product called  <a href="http://www.browserhawk.com/">BrowserHawk</a> from CyScape.  The  Apache world doesn&#8217;t really have something comparable to this popular,  mature and well-supported product.  Speaking of CyScape, they&#8217;ve recently  added an interesting-looking related product called  <a href="http://www.browserhawk.com/products/country/intro.asp">CountryHawk</a>  that helps with location detection, but so far I haven&#8217;t had the  language- or location-sensitive content to warrant trying it out. </p>
<p> <b>Tip 5: Gzip site content</b><br /> Browsers can handle Gzipped and deflated content and decompress it on the  fly.  While IIS 5 had a gzip feature built-in, it is pretty much broken.  Enter  products like <a href="http://www.pipeboost.com/">Pipeboost</a> to give us  better functionality &#8212; similar to what Apache users have enjoyed with  <a href="http://www.remotecommunications.com/apache/mod_gzip/">mod_gzip</a>.   Don&#8217;t waste your  bandwidth &#8212; even Google encodes its content, and their  pages are tiny. </p>
<p> <b>Tip 4: Cache your content</b><br /> While I&#8217;m on the topic of improving performance, remember to make your site  cache friendly.  You can set expiration headers for different files or directories  right from the MMC.  Just right click on an item via the IIS MMC, flip to the  &#8220;HTTP Headers&#8221; tab, and away you go.  If you want to set cache control headers  programmatically &#8212; or even better, let your site developers do it &#8212; use  something like <a href="http://www.cacheright.com">CacheRight</a>.  If you  want to go further and add reverse proxy caching, particularly for generated  content, use a product like <a href="http://www.xcache.com/home/default.asp?c=45&#038;p=352">XCache</a>  &#8212; which also throws in compression. </p>
<p> It might involve more time and expense to take full advantage of caching, but  when you watch your logs shrink because they don&#8217;t contain tons of pointless  304 responses, and your bandwidth consumption drop like a stone, even while  your total page views increase over the same period, you&#8217;ll start to understand  why this particular tip was so important.  Cache friendly sites are quite rare,  but there is plenty of information available online about the enormous benefits  to be had by doing it right:  Check out  <a href="http://www.web-caching.com">Brian Davidson&#8217;s page</a>, this nifty  tutorial from <a href="http://www.mnot.net/cache_docs/">Mark Nottingham</a>,  and <a href="http://webmaster.info.aol.com/index.cfm?sitenum=2&#038;article=12">what AOL has to say</a>  on the subject. </p>
<p> <b>Tip 3: Tune your server</b><br /> Tuning IIS is no small topic &#8212; whole books and courses are dedicated to it.  But  some good basic help is available online, such as this piece from IIS guru  <a href="http://www.iisadministrator.com/Articles/Index.cfm?ArticleID=16144">Brett Hill</a>,  or this <a href="http://support.microsoft.com/default.aspx?scid=KB;EN-US;q308186&#038;">Knowledge Base article</a>  from Microsoft itself.  However, if you don&#8217;t feel like getting your hands dirty  &#8212; or can&#8217;t afford the time and expense of turning yourself into an expert &#8212;  take a look at <a href="http://www.xcache.com/home/default.asp?c=51&#038;p=334">XTune</a>,  from the makers of XCache.  It&#8217;s performance tuning wizards step you through the  process of tuning your IIS environment, making expert recommendations along the way. </p>
<p> <b>Tip 2: Secure your server with simple fixes</b><br /> Sure people are going to attack sites, but you don&#8217;t have to be a sitting duck  if you&#8217;re willing to make even a small effort.  First off, don&#8217;t advertise the  fact that you are running IIS by showing your HTTP server header.  Remove or  replace it using something like <a href="http://www.servermask.com">ServerMask</a>  &#8212; probably the best twenty-five bucks you&#8217;ll ever spend.  You can go farther  than this by removing unnecessary file extensions to further camouflage your  server environment, and scanning request URLs for signs of exploits.  There  are number of commercial products that do user input scanning, and Microsoft  offers a free tool called  <a href="http://www.microsoft.com/technet/treeview/default.asp?url=/technet/security/tools/tools/urlscan.asp?frame=true">URLScan</a>  which does the job.  URLScan runs in conjunction with  <a href="http://www.microsoft.com/technet/treeview/default.asp?url=/technet/security/tools/tools/locktool.asp">IISLockDown</a>,  a standard security package which should probably be installed on every IIS  server on the planet.  These are simple fixes that could pay off big, so do them now. </p>
<p> <b>Tip 1: Patch, patch, patch!</b><br /> Okay, we in the IIS world do have to patch our systems and make hotfixes.   However, as a former Solaris admin I had to do the same thing there, so I am  not sure why this is a big surprise.  You really need to keep up with the  patches, Microsoft is of course the  <a href="http://www.microsoft.com/technet/treeview/default.asp?url=/technet/security/current.asp">definitive source</a>,  but if you can also use the highly-regarded www.cert.org.  Simply search on &#8220;IIS&#8221;. </p>
<p> Well there you have it: 10 tips for IIS admins to improve their servers.  Some  of the tips might become obsolete once IIS 6 is gold, but, for now at least,  W2K and NT IIS admins should apply a few of these today and sleep a little better at night. </p>
<p>Reprinted with permission from <a href="http://www.port80software.com">Port80 Software</a>.</p>
<p>Matt Foley is a former Solaris sysadmin who was turned to the &#8220;darkside&#8221; and is now works for a large southern California hosting and Web agency. He quite likes Windows now in spite of himself.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.webpronews.com/ten-ways-to-make-the-most-of-iis-2003-05/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Apache Shared Modules in Delphi</title>
		<link>http://www.webpronews.com/apache-shared-modules-in-delphi-2003-05</link>
		<comments>http://www.webpronews.com/apache-shared-modules-in-delphi-2003-05#comments</comments>
		<pubDate>Thu, 01 May 2003 17:28:11 +0000</pubDate>
		<dc:creator>Brian Long</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[Magazine]]></category>
		<category><![CDATA[Modules]]></category>
		<category><![CDATA[Server]]></category>
		<category><![CDATA[Support]]></category>
		<category><![CDATA[Web]]></category>
		<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://www.webpronews.com/?p=4003</guid>
		<description><![CDATA[Back in Issue 69 (May, 2001) of <a href="http://www.thedelphimagazine.com/">The Delphi Magazine</a> in <a href="http://www.thedelphimagazine.com/samples/1222/1222.htm"><i>Apache Shared Modules</i></a>, I looked at the Apache Web server running on Linux and how Kylix could be used to write CGI applications and also Apache shared modules or DSOs (the main thrust of the article). That was shortly after Kylix had been released, and discussed how to overcome a variety of problems, including the fact that the standard Apache binary distribution is not suitable for using shared modules.
]]></description>
			<content:encoded><![CDATA[<p>Back in Issue 69 (May, 2001) of <a href="http://www.thedelphimagazine.com/">The Delphi Magazine</a> in <a href="http://www.thedelphimagazine.com/samples/1222/1222.htm"><i>Apache Shared Modules</i></a>, I looked at the Apache Web server running on Linux and how Kylix could be used to write CGI applications and also Apache shared modules or DSOs (the main thrust of the article). That was shortly after Kylix had been released, and discussed how to overcome a variety of problems, including the fact that the standard Apache binary distribution is not suitable for using shared modules.</p>
<p>This update looks at what issues need to borne in mind when using Delphi 6 to create Web applications for Apache running on Windows. Fortunately, things are a bit simpler here than they are in Linux (a welcome relief). This article should be considered an update to the original article rather than standalone, so if you are unfamiliar with Apache and DSOs (or shared modules) I recommend you have a read of it. Just ignore any references to Linux issues along the way, particularly about recompiling Apache (there is no need to do this with the Windows version of Apache).</p>
<p>Your first question might be to ask why we should bother looking at Apache anyway. After all, Apache on Windows is certainly not as well established as Apache on Linux, or IIS on Windows. Well, you should consider that whilst Windows 2000 Professional ships with a copy of IIS, it only has a 10 user limit. If you want your Web server to work well you will need to upgrade to Windows 2000 Server and get the appropriate additional licensing.</p>
<p>More things in Apache&#8217;s favour include the fact that it is completely free and has its full source code freely available for download. Additionally, it is straightforward to configure through one textual configuration file and has updates made to its source code tree far more frequently than IIS. On top of this, the main source code base is evidently well established, given the mass acceptance of Apache on Internet servers (primarily Unix systems), and the documentation states that it can even load up ISAPI DLLs.</p>
<p>There is also the fact that the basic logic you place in a WebBroker or WebSnap application is much the same no matter what Web server protocol you are targeting, so you can easily target Apache Web server from your existing Web server applications by creating a new project file set up appropriately. A minimal amount of work can result in another Web server platform that you can say that you target.<br />
Additionally, it is just at home on Windows 95, 98 or Me as it is under Windows NT or 2000, so can be used for non-sensitive Web servers on a company Intranet. If you need to test Apache out (because you are thinking of setting up a Linux Web server, for example), trying it out under Windows can be much more comfortable if you are new to Linux. Get the hang of what&#8217;s required of Apache in Windows, then that is one problem out of the way when you set up your Linux box.</p>
<p>Anyway, the bottom line is that it provides another option on top of Microsoft&#8217;s IIS or PWS, or Netscape server, or CGI applications, so it can be useful to know how to take advantage of it.</p>
<p><b>Choosing Apache 1 or Apache 2</b></p>
<p>Apache 2 was released after Delphi 6 and introduces some important issues. The Apache 2 module format differs from the Apache 1 module format and as a consequence, Delphi 6 can only work with Apache 1.x.</p>
<p>To build shared modules for Apache 2 requires Delphi 7, which introduces additional <a href="http://www.blong.com/Articles/Apache%20For%20Windows/ApacheWindows.html#Figure1">support for Apache 2.x</a>. The key difference in an Apache 2.x shared module, when compared with an Apache 1.x shared module is the project file usesclause. Shared modules targeting Apache 1.x use the ApacheApp.pas unit, whereas Apache 2.x projects use ApacheTwoApp.pas.</p>
<p><b>Note:</b> Delphi 7 has only been certified for use with Apache up to version 2.0.39 as that was the most current version available when it was sent to manufacturing. Apache 2.0.40 introduces more changes that break the Delphi support and requiring modifications to the support units. However, all is not lost as <a href="http://www.drbob42.com/delphi7/apache2040.htm">unofficial patch information</a> supplied by a Borland engineer is available online that allows Apache 2.0.40 and higher to be used with shared modules written in Delphi.</p>
<div align="center">
<img src="http://images.ientrymail.com/devnewz/Delphi7NewWebApp.gif"><br />
<b>Figure 1: Delphi 7 Apache support</b>
</div>
<p>Kylix 3 was released just before Delphi 7 (indeed Delphi 7 includes a copy of the Delphi language version of Kylix 3 in the box), but Apache 2 support did not make it into that product. This may happen with an update pack, but in the meantime you could always try &#8220;borrowing&#8221; the pertinent Apache 2 source files from your copy of Delphi 7 and using those instead of the Apache 1 files in your shared module project. The Apache source files are located in $(DELPHI)SourceInternet, where $(DELPHI) is the main Delphi installation directory.</p>
<p>The units used in Apache 1 applications are:</p>
<ul>
<li>ApacheApp.pas, used in the project source</li>
<li>ApacheHTTP.pas, used by ApacheApp</li>
<li>HTTPD.pas, used by ApacheApp and ApacheHTTP</li>
</ul>
<p>The files used in Apache 2 applications are:</p>
<ul>
<li>ApacheTwoApp.pas, used in the project source</li>
<li>ApacheTwoHTTP.pas, used by ApacheTwoApp</li>
<li>HTTPD2.pas, used by ApacheTwoApp and ApacheTwoHTTP</li>
</ul>
<p>So in theory you could copy the Apache 2 support files across to your project directory and modify the project usesclause to use ApacheTwoApp instead of ApacheApp.</p>
<p><b>Note:</b> that this suggestion is speculative &#8211; I haven&#8217;t tested it.</p>
<p><b>Installing Apache</b></p>
<p>Before writing any Apache shared modules, you need to get hold of Apache and install it. You can get a ZIP file containing the source code from <a href="http://httpd.apache.org/dist/httpd">httpd.apache.org/dist/httpd</a>, but that requires you to have Visual C++ to compile it. Instead, I recommend you get the precompiled version without source code from <a href="http://httpd.apache.org/dist/httpd/binaries/win32">httpd.apache.org/dist/httpd/binaries/win32</a>. I downloaded version 1.3.20, <a href="http://httpd.apache.org/dist/httpd/binaries/win32/apache_1.3.20-win32-no_src-r2.msi">apache_1.3.20-win32-no_src-r2.msi</a>, which is a Windows Installer file that can be used to install Apache. Clearly this means you need the Windows Installer on your machine, but if you haven&#8217;t you can download it from the Microsoft Web site.</p>
<p>The last time I checked there were two main versions of Apache available, one is a version 1.x (<a href="http://www.apache.org/dist/httpd/binaries/win32/apache_1.3.26-win32-x86-no_src.msi">Apache 1.3.26</a>) and one is a version 2.x (<a href="http://www.apache.org/dist/httpd/binaries/win32/apache_2.0.40-win32-x86-no_ssl.msi">Apache 2.0.40</a>). As discussed earlier, if you are using Delphi 6 you must download the 1.x version as support for 2.x only arrives in Delphi 7.</p>
<p>Before installing, you should terminate any other Web servers you have running (I had IIS running on Windows 2000), as they will typically all fight for the same default TCP port (port 80). I suspended IIS through the Internet Information Services Control Panel applet (in Control Panel&#8217;s Administrative Tools folder).</p>
<p>When you run the file, the installation wizard will start:</p>
<div align="center">
<img src="http://images.ientrymail.com/devnewz/InstallApache.gif"><br />
<b>Figure 2: Installing Apache for Windows</b>
</div>
<p>When it gets around to asking you about your Web server information, you will be best placed to answer the questions. Since I want to access my Web server by specifying its machine name (Cube), that&#8217;s what I tell the installation program:</p>
<div align="center">
<img src="http://images.ientrymail.com/devnewz/InstallApacheSettings.gif"><br />
<b>Figure 3: Specifying my Web server settings</b>
</div>
<p>This will mean I can browse to http://Cube from anywhere on my network and gain access to Cube&#8217;s Web server.</p>
<p>Notice in Figure 3that the installation asks if you wish Apache to run as a service. On Windows NT/2000, this will be a good choice for a production system, as it keeps Apache running from boot-up to shutdown, but is not recommended on Windows 9x, as it is still at an experimental stage on these platforms.</p>
<p>On a development system (and on Windows 9x), you might find it easier to choose the other option, which installs it for manual invocation in a console window. This option makes it straightforward to debug your Apache shared modules and is the recommended option when installing on Windows 9x.</p>
<p><b>Controlling Apache</b></p>
<p>When installation is done, about 4Mb of disk space will have been consumed (even though the installation program suggests it will take about 15Mb) and Apache should be ready for use. Depending whether you chose to install Apache as a service or not, your Apache Start menu folder will be organised differently. Figure 4shows the menu structure for the service installation.</p>
<div align="center">
<img src="http://images.ientrymail.com/devnewz/StartMenuGroup1.gif"><br />
<b>Figure 4: The Apache service Start Menu Group</b>
</div>
<p>If you chose the other option (manually starting Apache in Figure 3), the Control Apache Servermenu will not be present, but you will have one extra menu item under Apache httpd Server, which says Start Apache in Console.</p>
<p>If you installed Apache as a service, it will be running each time you start Windows. You can stop Apache with the Stopmenu item and start it with the Startitem. The Restartitemwill attempt to stop Apache if it is running, and then start it again. This is a convenient way of getting Apache to re-read its configuration file, after you have made changes to it.</p>
<p>If Apache is installed for manual invocation, the Start Apache in Consoleitem will start the Apache process in a console window (in Apache 1.3.4 and earlier, this option was called Apache Server). This process can be terminated by pressing Ctrl+Cin the console window (in version 1.3.13 and later) or by clicking the console window&#8217;s cross button (in version 1.3.15 and later).</p>
<p>For both installation types, you can also terminate Apache by passing it appropriate command-line switches (it might be convenient to add a new shortcut with this command line to the Apache Start menu folder, if you installed it for manual invocation):</p>
<p>C:Program FilesApache GroupApacheApache.exe -k shutdown</p>
<p>When Apache is running, you can invoke your Web server&#8217;s home page, with <a href="http://localhost/">http://localhost</a>, and you should get the default Apache home page:</p>
<div align="center">
<img src="http://images.ientrymail.com/devnewz/ApacheHomePage.gif"><br />
<b>Figure 5: The default Apache homepage</b>
</div>
<p><b>Writing a Shared Module</b></p>
<p>To create a shared module in Delphi 6, choose File | New | Other&#8230;, then choose Web Server Application. In the Web Server Application wizard, choose Apache Shared Module (DLL)and press OK. This creates a DLL-based WebBroker application, where we need to focus on the project file (choose Project | View Source).</p>
<p><b>Note:</b> Delphi 7 and later will give you a <a href="http://www.blong.com/Articles/Apache%20For%20Windows/ApacheWindows.html#Figure1">choice of Apache versions</a> to target, which affects the Apache support unit used in the project source file.</p>
<p>The default content of the project file looks like:</p>
<p>-=<code2>=-</p>
<p>In this case, I saved the project as <a href="http://www.blong.com/Articles/Apache%20For%20Windows/ApacheTest.zip">ApacheTest.dpr</a>, which will generate a binary file called ApacheTest.dll. To keep things consistent with the modules supplied with Apache, I added the compiler directives below to the project file to change the output name to mod_ApacheTest.so instead (so is the file extension of DLL equivalents on Linux, called shared objects).</p>
<p>-=<code3>=-</p>
<p><b>Note:</b> you can also use the Applicationpage of the project options dialog to change the extension and prefix. The other change here was to update the default exported module record name from Project1_module, resulting in:</p>
<p>-=<code4>=-</p>
<p>At this point, the application can have functionality added to it, as in any other WebBroker project. In my sample shared module I have a Web action set up on the Web module (double-click the Web module or use the property editor for the Actionsproperty) that has no PathInfo, but sends a simple piece of HTML back in itsOnActionevent handler.</p>
<p>-=<code5>=-</p>
<p>This should suffice to prove whether we can get a DSO working or not.</p>
<p><b>Using The Shared Module</b></p>
<p>The next step is to compile the project into the correct directory, and tell Apache to use it. In the project options dialog, the Directories/Conditionalspage specifies where the compiled executable will be placed (the Output directory: option). Set this to wherever Apache stores its shared modules, which, on a default setup, is C:Program FilesApache GroupApachemodules. Now compile the project (Ctrl+F9) and the shared module will take its place alongside all the default ones.</p>
<p>The final step is to modify the configuration file. One of the menu items in the Configure Apache Server group will bring up the configuration file in Notepad. Scroll down to the commented section entitled <i>Dynamic Shared Object (DSO) Support</i>. In this section, you will see a number of commented LoadModule directives to which we need to add another. We also need to add a Location directive to identify which URLs will invoke the shared module. For example, you may wish all requested URLs that start with /delphito be handled by your shared module.</p>
<p>This is the generic template for what needs to go in the config file:</p>
<p>-=<code6>=-</p>
<p>The bits you customise are:</p>
<ul>
<li><code>module_record_name</code> is the symbol exported by the project file and is case-sensitive. In Listing 2 you can see this is ApacheTest_module</li>
<li><code>library_name</code> is taken from the ModuleNamevariable (from the ApacheApp unit) and defaults to the name of the shared module binary file, with any relative path needed to access it. In my example, this will be modules/mod_ApacheTest.so</li>
<li><code>URL</code> is the case-sensitive URL portion that identifies what URLs should be serviced by the shared module. For the example, this will be /delphi</li>
<li><code>content_type</code> is taken from the case-insensitive ContentTypevariable and defaults to a lowercase string that includes the module name without the extension, with -handlerappended. In my example, this is mod_apachetest-handler</li>
</ul>
<p>If we plug these bits into the framework above, we get this:</p>
<p>-=<code7>=-</p>
<p>Add these LoadModuleand Locationdirectives to the configuration file and then save it.</p>
<p><b>Note:</b> just before restarting Apache you should be aware of the ClearModuleListdirective. If this is present in the configuration file you should ensure it occurs before your LoadModuledirectives, as it unloads both statically linked modules and also dynamically loaded modules (shared modules).</p>
<p>Now you can restart Apache (as described earlier) and you will be able to browse to <a href="http://localhost/delphi">http://localhost/delphi</a>. The Web server application will respond accordingly with the simple HTML string:</p>
<div align="center">
<img src="http://images.ientrymail.com/devnewz/SharedModule.gif"><br />
<b>Figure 6: A shared module in action</b>
</div>
<p><b>Note:</b> since the URL portion of the Locationdirective is case-sensitive, browsing to <a href="http://localhost/Delphi">http://localhost/Delphi</a> will give an error 404, page not found error.</p>
<p><b>Debugging Shared Modules</b></p>
<p>In order to debug a shared module, you must ensure Apache is not running. If Apache is installed as a service, stop its execution with the appropriate menu item. If Apache was installed for manual invocation, make sure it is not running in any console windows.</p>
<p>Since your shared module is loaded by Apache when it starts, you must tell Delphi about this host application. In the Run | Parameters&#8230;dialog, enter the full path to Apache in the Host Applicationfield:</p>
<div align="center">
<img src="http://images.ientrymail.com/devnewz/DebugParameters.gif"><br />
<b>Figure 7: Telling Delphi how to debug your shared module</b>
</div>
<p>Now go to the debugger options dialog (Tools | Debugger Options&#8230;) and enable the Debug spawned processescheckbox.</p>
<p>Now you can set breakpoints in your shared module code as you would in any normal application (although to be honest, I could only get this operational under Windows 2000; my Windows 98 tests proved unsuccessful). When you press the Run button (or F9), Delphi launches Apache, which then loads up the shared module allowing it to be debugged.</p>
<p>When you are finished debugging, remember to terminate Apache in the correct manner, as described earlier. In other words, do not simply reset the debugged process (Ctrl+F2) as Apache may not shut down properly. Either use the Startmenu item (if available) or the corresponding command-line or, if Apache is running in a console window, press Ctrl+C in that window.</p>
<p>Originally appeared at <a href="http://www.blong.com/Articles/Apache%20For%20Windows/ApacheWindows.html">http://www.blong.com</a>.</p>
<p>Besides authoring a Borland Pascal problem-solving book published in 1994, and co-authoring an early Delphi bookpublished in 1996, Brian is a regular columnist in The Delphi Magazineand has had numerous articles published in Linux Format, Developers Review, Computing, Delphi Developers Journal and EXE Magazine. and on the Borland Developer NetworkWeb site. Find out more about Brian and his consulting services, visit http://www.blong.com.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.webpronews.com/apache-shared-modules-in-delphi-2003-05/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Page Caching using memcached
Database Caching 1/43 queries in 0.029 seconds using memcached
Object Caching 538/642 objects using memcached

Served from: webpronews.com @ 2012-02-13 01:17:01 -->
