Search for Text Inside of PHP Files with Vista

6

By : Josh Stauffer

Problem

Windows ignores text inside of PHP files because it doesn’t recognize them. This makes it very difficult to search for specific words or phrases inside of PHP files.

Solution

  1. Perform a search on the Start Menu for “indexing”. In the results, click on “Indexing Options”.
  2. With “Indexing Options” open, click on the “Advanced” button.
  3. Click on the “File Types” tab and scroll down the list until you see php in the Extension column.
  4. Click on php to select it, then select the radio button below that reads “Index Properties and File Contents”.
  5. Click OK. Click Close.
  6. Restart your computer.

Search within PHP files

Now when you perform a search for a word, you will be able to click “Search in File Contents” and it will search all the text inside of the PHP files and return results for your query. That’s all there is to it.

Send test emails with WampServer

32

By : Josh Stauffer

What you’ll need:

  • WampServer downloaded and installed (I am using version 1.7.3)
  • Fake Sendmail
  • GoDaddy email account (I tried Gmail and Yahoo email accounts but couldn’t get them working.)

SendmailGo ahead and install WampServer. I just installed mine to the root of the c: drive so it makes for easy access (For example, “c:wamp”).

Next download Fake Sendmail. Fake Sendmail, aka sendmail.exe, is a simple windows console application that emulates sendmail’s “-t” option to deliver emails. Extract the sendmail.zip file and move the folder here: “c:wampsendmail”.

We need the GoDaddy email account because sendmail.exe requires an smtp server to perform the actual delivery of the messages. Now let’s configure some settings in the sendmail.ini file located here: “c:wampsendmail”.

  • line 14 | smtp_server=smtpout.secureserver.net
  • line 18 | smtp_port=80
  • line 38 | auth_username=youremail@goeshere.com
  • line 39 | auth_password=yourpasswordgoeshere

There are a few lines that need to be commented out/uncommented so I am providing a text version of the sendmail.ini file: sendmail.txt. Once your file looks similar to mine, save and close the sendmail.ini file.

Only one step left and that’s to make a change in the php.ini. Access the php.ini using this method below.

Sendmail Illustration 1

Search for sendmail_path and set it to “c:wampsendmailsendmail.exe –t”.

Sendmail Illustration 2

Save and close the php.ini file.

You must restart WampServer for the changes to the php.ini to take effect.

Having the ability to send test emails is great especially if you frequently work on scripts that require email generation. At least I think so (I’m smiling).

Browser Renderings

0

By : Josh Stauffer

Firefox RenderingWell, I upgraded to IE7 and boy am I NOT glad that I did. But I needed to see how a project I am working on looked in Internet Explorer 7. Come to find out that it looked great in Firefox and IE6 but not in IE7. So I upgraded to IE7 made some changes to the site and now it looks great in Firefox and IE7 but not in IE6. As you can imagine at this point I was about ready to kill Internet Explorer. Not sure how I would do that but I could wish anyway.

Moral of the story is if you need two versions of Internet Explorer installed on your machine, don’t use MultipleIEs. It is buggy and caused my internet connection to become intermittent. So if you have IE7 installed and want to see how your site renders in IE6, you can use IE NetRenderer. It allows you to check how a website is rendered by Internet Explorer 7, 6, or 5.5, as seen from a high speed datacenter located in Germany. Just type in a URL in the text field, select the Internet Explorer version, and there you have it.

This web rendering tool is ideally suited for web designers working on Apple iMac and Linux workstations. It allows you to verify web designs natively on all popular Internet Explorer versions, without the need to set aside several physical or virtual Microsoft Windows PCs just for that purpose.

Now that’s a great tool to remember!

Disable Image Toolbar in IE6

0

By : Josh Stauffer

Lightning

The image toolbar in IE6 is a tool that allows the user to save a picture, print a picture, email a picture, or open the “My Pictures” folder. This toolbar was meant to be a useful tool but it can often be an annoyance for the web designer. Here are a couple ways to disable this toolbar.

The first way is to add this line of code in the head section of your page:

<meta http-equiv="imagetoolbar" content="no">

The second way is specific to each img element. You can add the galleryimg attribute to any img element:

<img src="mypicture.gif" galleryimg="no" />