Friday, January 22, 2010

Removing suhosin from Ubuntu

http://www.ambitonline.com/nextrelease/archives/113-How-to-Ubuntu-PHP-Remove-Suhosin.html

and

http://ubuntuforums.org/archive/index.php/t-698306.html

I was looking at reasons to do this since apparently it's for protecting your mySQL and other sloppy php code, etc.

Then I found this little article listed above. Hope it helps

Ubuntu - Apache2 - cURL?

Recently, I installed a plugin where one of the features wouldnt work because it said that something called cURL wasn't installed on my server.

Hmmm...

If you use PHP, you may need to use cURL, which is one of the most popular extension. PHP CURL functions are available through the use of libcurl, a library created by Daniel Stenberg, and allow you to connect and communicate with web servers using many
different types of protocols.

Assume you have already setup LAMP. To install or setup cURL on your Linux machine like Ubuntu, run the following line of shell command in your terminal:
sudo apt-get install curl libcurl3 libcurl3-dev php5-curl

Now you have PHP cURL installed, the next thing you need to do is to restart apache2, run the following command in your terminal:
sudo /etc/init.d/apache2 restart

Thursday, January 21, 2010

how to test email via telnet

telnet xxx.xxx.xxx.xxx 25
HELO
MAIL FROM:you@hostname.com
RCPT TO:them@someplace_else.com
DATA Tells you to send data then CRLF period CRLF at end
You type your message then CRLF period CRLF (ie, type a period on a line by itself then hit ENTER) 250
QUIT Signoff message

Tuesday, January 19, 2010

Wordpress behind ISA


  1. On ISA, Create Access rule to allow internal networks access external networks

  2. On ISA, set your firewall rule. On the To tab, set the proxy setting to Requests appear to come from original client

  3. On the Web Server, set the default gateway to the ISA server IP address.

  4. Vwalah! - now you can do things like have clog ratings from each unique ip address, etc AND still download and install themes and plugins from the Wordpress dashboard.


Enjoy :)

Monday, January 18, 2010

Hearty Coconut Curry Butternut Squash Soup

Ingredients
1 butternut squash, halved and seeded
2 large onions, peeled and quartered
1 medium head garlic
6 cups vegetable broth
1 bay leaf
1 teaspoon brown sugar
1 teaspoon yellow curry powder
Optional spices - Tumeric, cumin and corriander (maybe a teaspoon of each to taste)
1/2 teaspoon dried oregano
1/2 teaspoon ground cinnamon
1/4 teaspoon ground nutmeg (optional - we aren't a big fan)
Salt and pepper to taste (I like pepper :) )
1 cup plain yogurt
1 can coconut milk
1 package of tofu (16 oz) - drain and cube into bite size pieces
1/4 cup chopped fresh parsley (optional)
Fresh lemon juice for when serving (optional - but it's nice and bright with it :) )

Directions

  1. Preheat oven to 350 degrees F (175 degrees C). Line a baking sheet with parchment paper or aluminum foil.

  2. Place squash halves and onion onto the prepared baking sheet. Wrap garlic in foil and set with other vegetables.

  3. Roast in the center of the oven for 45 to 60 minutes, until the squash is tender. Remove from oven and set aside until cool enough to handle.

  4. Squeeze garlic cloves out of their skin like paste into a food processor. Scrape the flesh from the squash and place into the food processor along with the roasted onion. Save about a third of the squash meat and chop into cubes or chunks to stir in last. Puree until smooth. Add vegetable broth if necessary.

  5. Transfer the pureed mixture to a stockpot and stir in vegetable broth. Season with the bay leaf, brown sugar, curry powder, other optional spices, oregano, cinnamon, nutmeg and salt and pepper to taste.

  6. Add tofu and remainder of squash meat and then, bring to a boil and simmer gently for 10 minutes.

  7. Remove bay leaf and serve hot. Garnish with a dolup of yogurt and fresh parsley if desired.

Saturday, January 16, 2010

Pie Registration and strange php error

in order to fix the error - edit the php.ini
set the following
short_open_tag = On

Don't forget to restart your web services. (IIS, Apache, whatever...)

Tuesday, January 5, 2010

How to auto delete files older than 5 days

Here's how to auto delete files older than 5 days. Open Notepad, enter the following:
Forfiles -p C:\backup -s -m *.* -d -5 -c "cmd /c del @path"

Save as something like: RecycleBinCleaner.cmd

Then create a service account in AD or a local user account with admin rights on the local IIS box and setup a Windows  Schuduled task to run it every night using that account.

 Bedeep, bedeep, bedeep... that's all folks! :)