Binary Expressions

Next Page »

2009-5-5

Client-side Image Maps with XHTML 1.1 Strict

Filed under: — Adam @ 8:16 am

I oddly just realized now that Mozilla Firefox is not handling client-side image maps correctly as it should with a DTD of XHTML 1.1 Strict in text/html. I will not go into test cases unless one finds it necessary as everything has been laid out in the two links below. However, why has this not been resolved or is there a proper solution to this matter? I have not been able to find a answers and oddly this issue has been brought up back in 2001. One would think enough time has past.

Any explanation, comments, or help would be greatly appreciated.

Source: Image map handling
Source: Bug 109445 - Referencing a client-side image map declared with id attribute doesn’t work in text/html (usemap)

2009-4-28

PHP - mssql_query() Error

Filed under: — Adam @ 7:16 am

Background Knowledge


I’m running PHP v5.2.9-2 with SQL Server 2005 Express on Windows Server 2003 R2 SP2.

Error Message


Warning: mssql_query() [function.mssql-query]: message: Unicode data in a Unicode-only collation or ntext data cannot be sent to clients using DB-Library (such as ISQL) or ODBC version 3.7 or earlier. (severity 16)

Solution


Specify the database columns within your database query (select filed1, field2 from foo). Avoid doing queries with the wildcard (*), select * from foo.

Source: PHP Manual on MSSQL_Query()

2009-4-26

A Favorite Quote of Mine

Filed under: — Adam @ 8:41 pm

“If you keep doing what you’ve always done, you’ll keep getting what you’ve always gotten.”

Jim Rohn
Motivational speaker and author

2009-4-23

Example of a Basic MSSQL Query using PHP

Filed under: — Adam @ 5:22 pm

An example of a basic MSSQL (Microsoft SQL Server/SQL Server Express) query using PHP.

1
2
3
4
5
6
7
8
9
$szQry = "SELECT column1, column2 FROM foo";
$szDBConn = mssql_connect("host","username","password");
mssql_select_db("database_name", $szDBConn);
$saResults = mssql_query($szQry, $szDBConn);
while($obResults = mssql_fetch_row($saResults))
{
   echo $obResults[0]." ".$obResults[1];
}
mssql_close($szDBConn);

Comments/description of Example

Line #1
SQL statement that will be sent to the MySQL database server.
Line #2
MSSQL database login credentilas; host (127.0.0.1), username and password.
The “host” is the server name or IP address of your database server. If your host has multiple instances the “host” value would be formatted like so “foo\bar”. If your using SQL Server Express the “host” name locally would be “.\SQLEXPRESS”.
Line #3
Select database using the login credentials provided above.
Line #4
Send SQL statement to database.
Line #5-8
Fetch results returned back from the SQL statement. I use a while loop to enumerate through each row of results returned. If you know only one row is going to be retunred the while loop is not necessary.
Line #9
Close database connection.

2009-3-7

Canada’s Version of the Ant and Grasshopper

Filed under: — Adam @ 10:38 am

Background Knowledge


It appears this depiction of the Canadian political left and right originated as far as I can tell by johnnyslow [at] gmail [period] com around the end of the 2005. I recently heard the below of what I’m reposting on Charles Adler radio show.

I was so impressed by this analogy I had to post it for others that may have not read it yet.

Classic Version


The ant works hard in the withering heat all summer long, building his house and laying up supplies for the winter. The grasshopper thinks he’s a fool, and laughs and dances and plays the summer away.

Come winter, the ant is warm and well fed. The shivering grasshopper has no food or
shelter, so he dies out in the cold.

THE END

The Canadian Version


The ant works hard in the withering heat all summer long, building his house and laying up supplies for the winter. The grasshopper thinks he’s a fool, and laughs and dances and plays the summer away.

Come winter, the ant is warm and well fed. So far, so good, eh?

The shivering grasshopper calls a press conference and demands to know why the ant should be allowed to be warm and well fed while others less fortunate, like him, are cold and starving.

The CBC shows up to provide live coverage of the shivering grasshopper,
with cuts to a video of the ant in his comfortable warm home with a table laden with food. Canadians are stunned that in a country of such wealth, this poor grasshopper is allowed to suffer so while others have plenty.

The NDP, the CAW and the Coalition Against Poverty demonstrate in front
of the ant’s house. The CBC, interrupting an Inuit cultural festival special from Nunavut with breaking news, broadcasts them singing “We Shall Overcome.”

Jack Layton grants in an interview with Mike Duffy that the ant has gotten rich off the backs of grasshoppers, and calls for an immediate tax hike on the ant to make him pay his “fair share”.

In response to polls, the Liberal Government drafts the Economic Equity and Grasshopper
Anti-Discrimination Act, retroactive to the beginning of the summer.

The ant’s taxes are reassessed, and he is also fined for failing to hire grasshoppers as helpers. Without enough money to pay both the fine and his newly imposed retroactive taxes, his home is confiscated by the government. The ant moves to the US and starts a successful agribiz company.

The CBC later shows the now fat grasshopper finishing up the last of the ant’s food, though spring is still months away, while the government house he is in, which just happens to be the ant’s old house, crumbles around him because he hasn’t bothered to maintain it.

Inadequate government funding is blamed, Bob Rae is appointed to head a commission of inquiry that will cost $10,000,000.

The grasshopper is soon dead of a drug overdose, the Toronto Star blames it on the obvious failure of government to address the root causes of despair arising from social inequity.

The abandoned house is taken over by a gang of immigrant spiders, praised by the government for enriching Canada’s multicultural diversity, who promptly set up a marijuana grow op and terrorize the community.

THE END

This invented compare and contrast parable of the ant and grasshopper is the best way of discussing the political right and left.

Source: Charles Adler On The Edge
Source: Ralph’s World

2009-3-5

Windows Vista SP1 - Explorer Not Refreshing CD/DVD Drives

Filed under: — Adam @ 1:46 pm

Background Knowledge


I have Windows Vista Ultimate with Service Pack 1 with the following optical media drives. The system is approximately one year old.

  • Manufacture: LG
  • Model: HL-DT-STDVD-ROM_GDRH20N
  • Firmware version: 0D04
  • Manufacture: LG
  • Model: HL-DT-ST DVD+-RW GSA-H73N
  • Firmware version: B103

Problem


There are two issues I’m experiencing all resulting in the fact that windows explorer is not refreshing the drive contents and/or drive volume label. Both issues occur on CD/DVD reader and CD/DVD writer drives. As well I’ve tried multiple discs from ones I’ve burnt to discs that were commercial produced and these discs all work fine on other computer systems.

  1. My Computer/Windows Explorer is not refreshing the CD/DVD drive contents.
  2. My Computer/Windows Explorer is not refreshing the CD/DVD volume label.

Issue #1 - Drive Contents

One of two scenarios occur. One, at times if I’m taking a disc out of one of the drives and then put another one in the contents of the drive is not refreshed or Windows Explorer will prompt to format the disc even though the disc is not blank and has been fixated (closed disc).

Two, after burning a CD/DVD I am rarely ever am able to view the contents of the disc via Windows Explorer. Again I’m prompted with a dialog to format the disc even though the disc can not be blank. Oddly again both issues are gone when I view the contents of the drive via the command prompt.

If I eject the CD/DVD out of the drive using Windows Explorer not pressing the eject button on the drive itself then putting the disc back into the computer usually allows me to view the contents of the disc within Windows Explorer.

The only reliable way I’m able to see the current contents of a given CD/DVD is by using the command prompt.

Issue #2 - Volume Label

The CD/DVD volume label rarely appears correctly within windows explorer. If it does by chance, it is then stuck with that volume label until I reboot Windows Vista. Trying to refresh by pressing F5 does not help. Even if I eject the CD/DVD from the either drive by pressing the eject button on the drives themselves or clicking on eject with the mouse the drive label still shows/appears as if there is a CD/DVD in the drive.

The only reliable way I’m able to see the correct volume label at all times is by using the command prompt.

Solution


I’m not aware of any solution, only work a rounds is doing one of the following list below. However these work a rounds are not perfect nor practical/logical. Even using an alternative application to Windows Explorer I still found issues of the correct volume name of the disc. Even if a disc was not in the drive it would still show a volume name. Although at least if you accessed the drive it would refresh the contents of the disc.

  • Only use “eject” button within Windows Explorer and not on the physical drive.
  • Use the command prompt to view contents of the disc and volume name.
  • Use an alternative application to Windows Explorer such as FreeCommander or Xenon File Manager.

I’ve anyone has a solution that works 100% and allows the use of Windows Explorer please feel free to post your solution under comments.

2009-2-12

PHP - Upgrading v5.2.5 to v5.2.8

Filed under: — Adam @ 1:05 pm

Background Knowledge


The following is the process I took to upgrade a web server with PHP v5.2.5 to PHP v5.2.8 running on OpenBSD. PEAR is already installed on this system and up to date. I wasn’t sure if I should exclude PEAR at install or not so therefore did not tell the configurator to exclude PEAR at install.

Installation Process


  1. Download the latest stable PHP release from command prompt # wget http://ca.php.net/get/php-5.2.8.tar.gz/from/a/mirror
  2. # tar -zxvf php-5.2.8.tar.gz
  3. ./configure –with-mysql=/usr/local –with-mssql=/usr/local –with-apxs –with-zlib-dir=/usr/lib –with-config-file-path=/var/www/conf –with-iconv=/usr/local/bin/iconv –enable-exif –enable-mbstring –enable-calendar
  4. # make
  5. # make test
  6. # make install
  7. # make clean

As far as I could tell in the PHP 5 ChangeLog since at least PHP v5.2.5 there has not be any changes made to the php.ini configuration file. Therefore I chose to leave the PHP configuration file (php.ini) that was being used with PHP v5.2.5 for PHP v5.2.8.

Issues


  1. At configure I received the following message “checking for a sed that does not truncate output… (cached) /usr/bin/sed
    expr: syntax error ./configure[2322]: test: 0: unexpected operator/operand expr: syntax error ./configure[2337]: test: 0: unexpected operator/operand”

I’m not sure what to make of this error message. I tried to search on Google but was not successful finding any answers. I tested my PHP installation and all appears to be okay. If anyone knows what exactly this error means and how to resolve it please let me know.

2009-2-6

The Website is Down: Sales Guy vs. Web Dude

Filed under: — Adam @ 1:15 am

This video has been going around for some time now, but I think its worth the post for those that have yet to see it.

Video Source: The Web Site is Down

2009-2-5

Credit Card Signature Backfires

Filed under: — Adam @ 11:26 pm

I ran across this great experiment Kingpin tried testing how far one could go not signing your signature properly when making credit card purchases. He’s definitely proven a point and made a hilarious experience. A must read I must say.

Source: Drunk Republic: When Your Credit Card Signature Fun Backfires

2009-1-26

How To - Resolve Adobe PDF Printer is Not Bound to Adobe PDF Port

Filed under: — Adam @ 11:14 am

Background Knowledge


I have Windows Vista with Adobe Acrobat Professional v8.1.3 installed and I was trying to covert to Adobe PDF within Microsoft Publisher 2007.

Error Message


Acrobat PDFMaker reported the following error message dialog, “Adobe PDF Printer is not bound to Adobe PDF Port. Cannot proceed further. Kindly change the PDF Port to Adobe PDF Port in Adobe PDF Printer Settings”.

Adobe PDF Printer Port Error

Solution


  1. Go to Control Panel -> Printers.
  2. Right mouse click on “Adobe PDF” and left click on “Properties”.
  3. Left mouse click on “Ports” tab.
  4. Uncheck mark the current port that is presently check marked. Place a checkmark on either “Desktop\*.pdf” or “Documents\*.pdf”. Ensure the description is “Adobe PDF Port”.
  5. Left click on “Ok” button then close the printers window.

2009-1-12

How To - Resolve Unable to Retrieve MSN Address Book using Pidgin

Filed under: — Adam @ 9:31 am

Background Knowledge


Today (2008-01-12) I loaded Pidgin and discovered that I was no longer able to connect to MSN. It appears either Microsoft is blocking the connection or a new version has been release. What the cause of the matter is I have not been able to verify with certainty at this time.

UPDATE: Pidgin v2.5.4 has been released that temporarily fixes the problem.

Error Message


“Unable to Retrieve MSN Address Book using Pidgin”. See screen shot of the error message below.

Pidgin MSN Error

Solution


  1. Close Pidgin application.
  2. Download and install “msn-pecan“.
  3. Run Pidgin application.
  4. In Pidgin “Show Buddy List” and go to the menu “Accounts” -> “Manage Accounts”.
  5. Modify your MSN account, ensure the protocol shows “MSN”.
  6. Change “Protocol” to “WLM” and then click “Save”.
  7. Login to your MSN account.

Source: MSN Network Service Status
Source: Pidgin : Unable to retrieve MSN address list
Source: msn-pecan

2009-1-7

SeaTools for DOS v1.0PH - Overtemp–253

Filed under: — Adam @ 6:47 am

I was running a hard drive diagnostic using SeaTools for DOS v1.09PH on two exactly the same Maxtor hard drives, see details of the drives below. When I attempted to run a quick scan and then a long scan it received a warning “Overtemp–253″. After doing some research I have come to the conclusion that with certainty that this doesn’t mean the hard drive is running at 253 degrees Fahrenheit. My two drives are well ventilated and do not even feel warm to the touch. In fact this message apparently means according to Seagate that the hard drive does not support SeaTools reading temperatures.

  • Brand: Maxtor
  • Model: 6Y060L0
  • FW: YAR41BW0

Source: Incorrect temperature values for a Maxtor disk

Next Page »

Take back your mailbox - CAUCE.org

Powered By Wordpress PHP: Hypertext Preprocessor MySQL Powered Download Juice, the cross-platform podcast receiver
Proud To Be Canadian Get Firefox Valid XHTML Valid CSS
<NO>OOXML Logo


19 queries. 0.611 seconds.
Copyright © 2004 - 2005 by Adam Douglas