I have a script that checks responses from HTTP servers using the PEAR HTTP classes. However, I've recently found that the script fails on FTP servers (and probably anything that's not HTTP or HTTPS). I tried Google, but didn't see any scripts or code that returned the server status code from servers other than HTTP servers.
How can I f...
DB_DataObject does not appear to be ActiveRecord because you do not necessarily store business logic in the "table" classes. It seems more like Table Data Gateway or Row Data Gateway, but I really cannot tell. What I need is good ORM layer that we can use with DataMapper and a DomainModel. Any ideas?
...
I'm trying to install Laconica, an open-source Microblogging application on my Windows development server using XAMPP as per the instructions provided.
The website cannot find PEAR, and throws the below errors:
Warning: require_once(PEAR.php) [function.require-once]: failed to open stream: No such file or directory in C:\xampplite\htdo...
We have an issue using the PEAR libraries on Windows from PHP.
Pear contains many classes, we are making use of a fair few, one of which is the Mail class found in Mail.php. We use PEAR on the path, rather than providing the full explicit path to individual PEAR files:
require_once('Mail.php');
Rather than:
require_once('/path/to/pe...
Hi,
When accessing a MySQL-database from PHP there seems to be several ways:
Sprinkle the code with raw SQL-statements
Use the VO-pattern from Java (e.g. DB_DataObjects from PEAR)
DIY and write a script that auto-generates one PHP class per database table
Apart from this I have also read about LINQ in .NET but have not s...
We recently debugged a strange bug. A solution was found, but the solution is not entirely satisfactory.
We use IntSmarty to localize our website, and store the localized strings in a database using our own wrapper. In its destructor, IntSmarty saves any new strings that it might have, resulting in a database call.
We use a Singleton ...
When building some of my PHP apps, a lot of the functionality could be coded using PEAR/PECL modules, however, the fact that some people using it may not have the access to install things, It poses a puzzler for me.
Should I forsake some users to use PEAR/PECL for functionality, where these will allow me to have a system coded up quicke...
I am looking for instructions on how to setup a PEAR channel for our project so that we can deploy it with the pear installer. I have Googled for a while and cannot find any straightforward information. I followed this tutorial for a while, but I am having a hell of a time getting this to work. Does anyone know how to do this? Is there a...
Has anyone used Pear: Spreadsheet_Excel_Writer?
The Formatting Tutorial lists a script similar to what I'm working with: (trimmed down)
<?php
require_once 'Spreadsheet/Excel/Writer.php';
$workbook = new Spreadsheet_Excel_Writer();
$worksheet =& $workbook->addWorksheet();
$worksheet->write(0, 0, "Quarterly Profits for Dotcom.Com");
$w...
Here's the code. Not much to it.
<?php
include("Spreadsheet/Excel/Writer.php");
$xls = new Spreadsheet_Excel_Writer();
$sheet = $xls->addWorksheet('At a Glance');
$colNames = array('Foo', 'Bar');
$sheet->writeRow(0, 0, $colNames, $colHeadingFormat);
for($i=1; $i<=10; $i++)
{
$row = array( "foo $i", "bar $i");
$sheet->wri...
I have been trying to get PEAR::mail to successfully deliver emails to hotmail users without being flagged as SPAM and ending up in the junk folder, i have no problems with yahoo/gmail only with hotmail.
google suggested that this is a common problem with hotmail and that possible causes can include
incorrect reverse DNS for main IP o...
I'm painfully new to PHP, and was trying to set up phpBB on my local site. I have a stock debian install of apache2 and php5. The phpBB installer ran fine, connected to the database and created all its tables with no problem. But when I tried to open the login page, I got a 0-byte response.
A little digging showed that it was never m...
I know this is usually done with cookies, but I am getting unpredictable results on different browsers and decided to look for a pear package that focuses on this. Just wondering if there's a package (HTTP_Client for example?) that anyone has had success using for this particular situation. Or actually, do people never or rarely have p...
I recently signed up to shared web hosting with godaddy using Linux and PHP 5. I want to work with multiple RSS feeds. I previously had this all functioning under Apache, however, the host supplied the PEAR installation. Now I have to do this myself and I am in unfamiliar territory.I installed PEAR PHP and managed to get rss.php in the...
Hi All,
PHP 5 and I want to install PEAR so I can use Spreadsheet_Excel_Writer
I dont see how to install it on my ISP nor my personal Macbook.
Thoughts for both?
Thanks!
...
I have several functions that I wrote and I use regularly on my servers, is there a way I can add them to the core so I don't have to include them from external files?
I am running PHP5
...
I have installed PEAR, Spreadsheet_Excel_Writer and OLE. The sample program is executed successfully but when I try to read the file it shows garbage values. I also tried $workbook->setVersion(8); and $worksheet->setInputEncoding('UTF-8');
I am using this tutorial and Google lot for this problem.
http://www.sitepoint.com/article/gettin...
I'm working with the Text_Diff PEAR package to diff to short text documents, where the Text_Diff object is created with a space-delimited list of the words in each document. I was hoping to store the diff in a database, and then apply it when the file is loaded again. Is there an easy way to apply this diff, or do I need to write a fun...
Hi,
I've not used PEAR before, and so I'm probably doing something dumb. I've installed the Math_Matrix library, but when I include it I just get an error. My entire code is this:
<?php
$path = '/home/PEAR/Math_Matrix-0.8.0';
set_include_path(get_include_path() . PATH_SEPARATOR . $path);
include_once 'Matrix.php';
?>
The error ...
Hi All
I'm looking into basic time functions (creating a UTC timestamp and converting into a local timezone). The first set of tutorials i encountered pointed toward PEAR as it's better at avoiding overspill errors in calculations. Now, mid-way through another, it appears that PEAR has issues with some of it's timezone functions running...