You are here

PHP

Setup for running stored procedures and sql from php / ubuntu on sql server

Wiki Terms: 

1.)

sudo apt-get install php5-sybase

2.)

sudo /etc/init.d/apache2 restart

3.) Third you need to do this: (copied from the internet -- tested it and it works, it will allow you to run stored procs)

“Figured it out...

In researching the problem before posting I saw references to configuration changes needed to FreeTDS, but apparently I was implementing the change wrong, but that is the solution.

Run a query from php / ubuntu on sql server

(note to run stored procs on sql server from php/ubuntu there's another tech note I've posted)

http://jamesrossiter.wordpress.com/2011/03/08/connecting-to-microsoft-sq...

sudo apt-get install php5-sybase
sudo /etc/init.d/apache2 restart

now here is the php file that works:

Who says Drupal doesn't scale, Acquia provided 3 million pages an hour without problems

Wiki Terms: 

http://acquia.com/blog/acquia-hosting-customer-hits-700-pagessecond-or-w...

Here's a list of many famous Drupal sites: http://buytaert.net/tag/drupal-sites

list includes:

Nike
Yahoo
Intel
AT&T
Reuters
CNN
Mattel
Sony
MTV
NATO
Warner Brothers
NASA
Even the United States White House!

Install alternative version of php on a mac with mac ports

Wiki Terms: 

Note I've found all these directions on making it work even when installing port php52 it simply does not work. I'm still trying to get this to work. ack.

conditionally run code on page.tpl.php

Wiki Terms: 

I use the following code to conditionally show pieces of the page depending on which page the user is on:


$curr_uri = check_plain(request_uri());
//print $curr_uri;
<?php if ((!preg_match("/contact/i", $curr_uri))&&(!preg_match("/authentication-options/i", $curr_uri))&&(!preg_match("/node\/305/i", $curr_uri))) : ?>
conditional html code here
<?php or php code here to be conditionally shown?>
<?php endif; ?>

put a block of html or php code in an if clause in PHP

Wiki Terms: 

<?php if ($footer_message): ?>
            <?php print $footer_message; ?>
            hello, html can go here too
            very nice :) 
        <?php endif; ?>

Theme by Danetsoft and Danang Probo Sayekti inspired by Maksimer