[thelist] outlook sucks hard. plus tip. (was email tip).

Joe Crawford jcrawford at avencom.com
Tue Jun 5 12:56:35 CDT 2001


".jeff" wrote:
> <tip type="email">
> 
> for those of you who use outlook express for email, i'm sure you get plenty
> pissed when you paste in some javascript code and outlook decides that some
> of your js comment lines are supposed to be links with the file: protocol
> prepended.  wanna know how to stop that?  it's super easy.  just make sure
> you've got at least one space after the double slashes.
> 
> bad:  file://this is the wrong way.
> good: // this is the right way.
> 
> </tip>

Jeff!

What a great tip! I have had people send me javascript code and had that
happen. Icky! Good to know there's a workaround.

But this is NOT an "email" tip - this is an "Outlook" (for Windows) tip.

Just as the most recent "Email viruses" are really "Outlook viruses" -
this is all about how stupid Outlook is. Or maybe it's more about how
smart it *thinks* it is. But Outlook sucks, and the more I hear about
this software, the more I avoid it like the plague. I'm sticking to
Netscape, pine, and Outlook for Mac for email.

I owe a tip fer sure:

<tip type="exporting csv files with php" author="Joe Crawford">

php + mysql makes it really easy to export a csv of data for use in
other ways. Check this out - it'll fire up a prompt box with a
timestamped CSV. Pretty simple to to. Make sure to not have any
whitespace before or after your <? ?> though - otherwise that whitespace
will interfere with sending the http headers necessary to make it work.

I have used this to export data into csvs for import into access and
into a palmpilot. very handy, really.

So here it is:

<?
/* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */
/* this was made by joe crawford. use at will!         */
/* http://artlung.com/ & http://artlung.com/lab/       */
/* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */
header("Content-type: application/x-unknown");
$EXPORT_TIME=time();
header("Content-disposition: attachment;
filename=export$EXPORT_TIME.csv");
/* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */
include('FileWhereYourConnectionInformationLives.php');
/* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */
YourConnectFunction() or die ("Cannot connect to server.");
/* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */
$query = "SELECT DISTINCT
		, NAME
		, ADDRESS
		, CITY
		FROM
			$db_table";
/* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */
$result=mysql_query( $query ) or die ("Cannot make query.");
/* this writes a header to make the data easier
   to import into your database program - say, Access */
echo "NAME\tADDRESS\tCITY\n";
/* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */
while ($row = mysql_fetch_array ($result))
	{
	echo $row['NAME'];
	echo "\t"; echo $row['ADDRESS'];
	echo "\t"; echo $row['CITY'];
	echo "\n";
	};
/* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */
?>
</tip>





--
Joe Crawford ||||||||||||||       mailto:jcrawford at avencom.com
||||||||||||||||||||||||             http://www.avencom.com
|||||||||||||||||||||||||||      Avencom: Set Your Sites Higher




More information about the thelist mailing list