Archive for September, 2007

Interesting Tool…BrowserCamp

Thursday, September 27th, 2007

I recently found an interesting tool call BrowserCamp that allows users to obtain a free screen shot of what their web site would look like in the Safari 2.0.4 web browser. It also offers paid memberships that allow users to login in via VNC to take control of a Mac OS X machine to use it for testing web sites with. Pretty cool little tool really! They even offer a referral program to allow one to obtain free time by referring other paid members. (And no the link here is not a referral link, but it should be!).

Here’s a screenshot of this site:

Screenshot from BrowserCamp

XHTML, PHP, Validation and Browsers

Thursday, September 27th, 2007

Recently for a school project I was working on, I had to develop an XTHML 1.1 Strict validated page and a validated CSS to style the page. This was not a problem in and of itself, however there were several problems that I encountered while trying to serve the pages to different browsers and to the W3C’s validator.

What this post will attempt to do is cover several items that I found necessary to accomplish a page that displayed properly in Internet Explorer 7, Firefox 2, Netscape 9, SeaMonkey, Opera and Safari for Windows. I have not fully tested the resulting pages on the Linux or Mac platforms yet, so I will attempt to do that when time permits. I did however use BrowserCamp to get a screen shot of what it looks like in Safari 2.0.4 and there were some CSS issues (I assume anyway).

(more…)

Inserting code blocks in to a WordPress post…..

Wednesday, September 26th, 2007

I have been working on writing the pages for some PHP and MySQL tutorials and was having a horrible time with the visual editor of WP destorying the code blocks and associated layout. But that is behind me now, and I will post a sample snippet of code here to show what it will look like on the future posts that contain code blocks.

To quickly explain what I have done though:

I installed an older version of coffee2code’s Preserve Code Formatting as well as installing the Quickcode plugin (from NetNerds.com). I followed their tutorial to get it setup and I have to say that I am indeed happy with test posts thus far. Hopefully you will find it good to use as well. I also should note that the entire procedure took me less than 10 minutes to download, upzip, install and configure.

Sample code:

[quickcode:Show/Hide: Meta Tags pulled from a MySQL database]

function generateKeywords($page)
{
include_once ‘mysql_dataconnector.php’;
$connection = dataConnection(‘coxMetaInfo’, ‘headers’) or die(“Fatal Error on line 45 of site_functions.php –> Cannot create dataConnection”);
$this->keywordQuery = “SELECT meta_keywords FROM headers WHERE headers.page_name = ‘”.$page.”‘”;
$keywordsResult = mysql_query($this->keywordQuery, $connection) or print (“Fatal Error on line 47: no keywords found”);
$keywords = mysql_fetch_assoc($keywordsResult);
mysql_free_result($keywordsResult);
return $keywords;
}

function generateDescription($page)
{
include_once ‘mysql_dataconnector.php’;
$connection = dataConnection(‘coxMetaInfo’, ‘headers’) or die(“Fatal Error on line 56 of site_functions.php –> Cannot create dataConnection”);
$this->descriptionQuery = “SELECT meta_description FROM headers WHERE headers.page_name = ‘”.$page.”‘”;
$descriptionResult = mysql_query($this->descriptionQuery, $connection) or print (“Fatal Error on line 47: no keywords found”);
$description = mysql_fetch_assoc($descriptionResult);
mysql_free_result($descriptionResult);
return $description;

}

[/quickcode]

The nice thing is it will show a link that can show/hide the code block at will similar to what is on this post, and you can specify the title of that link.

I am going to note here that in testing you have to do several things to get the quickcode to work.  If you are using the default WordPress visual editor, you will need to stop and use the standard editor (changed under user profile). You cannot use the normal <quickcode></quickcode> tags as they will be stripped out.  What I do is use the general editor and it works fine. Small price to pay for a coding oriented blog writer I guess. I am sure there may be a better method out there, but for now this was a good fix that solved the problem I was having.

Simple Faded Images in Fireworks

Monday, September 24th, 2007

(originally posted on the Band Of Gonzos Web Forum)

Okay the fade image is a simple fade – there are more advanced ways to do this, and I will try to get a tutorial to get the more advanced way to do it (invovles selecting with wand tool, creating feathers etc).

Step One:
Place background image in new layer by selecting File->Insert
(more…)

Upgraded……

Wednesday, September 12th, 2007

I just upgraded to WordPress 2.2.3 – if you notice anything strange or unusual leave a comment about it and I will look into it.


View in: Mobile | Standard