Use PEAR Library Spreadsheet_Excel_Writer?

Aug 20, 2010

I need to save some data in .xls file. I am trying to use PEAR library Spreadsheet_Excel_Writer. It is work. But now i am working with hosting without PEAR. Of cause, it is very terrible. Spreadsheet_Excel_Writer has a lot of dependencies. I need a module or code, which i can include in my scripts.

ADVERTISEMENT

Pear Spreadsheet_Excel_Writer Question

Aug 10, 2007

I am using the Spreadsheet_Excel_Writer module from Pear to generate
Excel spreadsheets from my application. Currently I am finding that
when I create a new excel spreadsheet I get a message when opening the
file saying:

File error: Data may have been lost.

Not sure what this is caused by or how to rectify it. I am trying to
open the excel file with excel 2007.

View 2 Replies View Related

Pear Error - Spreadsheet_Excel_Writer

Sep 27, 2005

I am trying to use the Spreadsheet module, but keep getting an error.

Warning: main(OLE/PPS/Root.php): failed to open stream: No such file or directory in /usr/local/www/vhosts/pmiwebconnect.com/htdocs/Spreadsheet/Excel/Writer/Workbook.php on line 39

Fatal error: main(): Failed opening required 'OLE/PPS/Root.php' (include_path='.:/usr/local/share/pear') in /usr/local/www/vhosts/pmiwebconnect.com/htdocs/Spreadsheet/Excel/Writer/Workbook.php on line 39

I uploaded all the files that came with it and did not see any Root.php files. Any ideas on this error message?

Here is a list of the packages installed:

%pear list
Installed packages:
===================
Package Version State
Archive_Tar 1.1 stable
Console_Getopt 1.2 stable
HTML_Template_IT 1.1 stable
Net_UserAgent_Detect 2.0.1 stable
PEAR 1.3.5 stable
XML_RPC 1.3.1 stable

View 2 Replies View Related

PEAR Spreadsheet_Excel_Writer Sending An Empty File?

Oct 13, 2008

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();
[code]....

View 6 Replies View Related

Writing An Excel File Using The PEAR Spreadsheet_Excel_Writer Package

Jun 30, 2005

I have a script that is writing an Excel file using the PEAR Spreadsheet_Excel_Writer package. Problem is the total file should have around 10,000 entries, but it only saves up to 5,990.

and the script itself doesn't give me any errors. The error shows up when I try to open up the Excel file and it says its corrupt although i can visualize the results.

The script runs for around 200 seconds, and I have set Apache's timeout to 500 and max_execution_time / max_input_time to 500 as well. Is there something I'm missing out on here?

View 3 Replies View Related

Email - Error In Mail_Queue Pear Library / IsError() Should Be Compatible With That Of PEAR::isError()?

Sep 10, 2010

I'm getting the following error when trying to use the PHP Mail_Queue PEAR library:

Declaration of Mail_Queue::isError() should be compatible with that of PEAR::isError()

PHP 5.2.3, Mail Queue Version 1.2.3

Searching on Google hasn't turned up anything.

View 1 Replies View Related

Spreadsheet_Excel_Writer Path - Error "Class 'Spreadsheet_Excel_Writer' Not Found"

Mar 18, 2010

I have tried the following program for writing the contents into Spreadsheet. I downloaded the Spreadsheet_Excel_Writer package also.

[code...........]

But while running this php program I got the following Fatal error. Fatal error: Class 'Spreadsheet_Excel_Writer' not found in /xhome/rekha/public_html/PHP_FORUM/PHP/open_office/spread.php on line 4 Call Stack.........

View 2 Replies View Related

Pear DB Library With A Practical Use??

Dec 24, 2009

I am a noob to PHP whats Pear DB library with a practical use?

View 3 Replies View Related

Make PDF Using Pear Library?

Feb 9, 2011

I wanted to make PDF using pear library of php.Check the link for File_PDF package at pear ttp:pear.php.net/package/File_PDFThe package does not have good documentation( none at all) and i cant find function implemented by it. Have anyone tried it? or know where i can find 1-2 examples based on it

View 2 Replies View Related

Standard PHP Library, PEAR, And Templates

Nov 27, 2005

Is the standard php library exclusively for PHP5 or is there one for PHP4?
How do I start using it? Is there a require or include directive needed in
order to make use of it?

Same question for PEAR. Is there a PEAR for PHP4 or only for PHP5? How do I
start using its facilities? Is there a require or include directive?

Lastly, I'd like to start using templates. From what I've read, they
simplify code so I don't have to play quoting games like:

echo "foo="blah"" . $foo['bar'] . 'blah' . "bar$foo="blah"";

which is a real drag. I can usually simplify lines like above, but they
never completely simplify to my satisfaction. Googling revealed a bunch of
template libraries. Is there a generally accepted standard one?

View 2 Replies View Related

Install XML_RPC2 Package From PEAR Library?

Mar 6, 2011

I'm trying to install XML_RPC2 package from PEAR library, but whenever I type a proper command (pear install XML_RPC2) I'm getting an error:

pear/XML_RPC2 requires PHP extension "curl" No valid packages found install faild

Strangely enough command

$ pear package-dependencies xml_rpc2

returns information "this package does not have any dependencies" (works fine in any other case).

I've also tried with older versions of XML_RPC2 - same thing. It's the first packege I have problem with.
I'm sure curl is enabled and it's work(tested). Beside that I have installed all others components listed on dependencies list(PHP 5.3, PEAR 1.9.2, Cache_Lite 1.7.9). I'm working on standard WAMP installtion on Windows XP.

View 2 Replies View Related

Custom Library With Pear Local Installation?

Jun 3, 2010

i wish to be able to deploy a PHP web application along with a local installation of PEAR. To be more specific, i am trying to find a way to do a 'per-application' or local installation of PEAR if this is possible.For example:The application 'MyApplication' is located in: /var/www/applications/myapplicationThe php library is located in: /var/www/applications/myapplication/librarI looking for a way to do a per-application installation of PEAR since not all applications are managed by me (and i want to control which PEAR packages are installed and when).I found some tutorials for a local PEAR installation (on a shared host) but i don't know if my scenario fits the one for a local PEAR installation.

View 1 Replies View Related

Php5 - Send Email Through It Without Using Any Additional PEAR Package Or Library?

Mar 11, 2011

I want to send email through PHP without installing or configuring any PHP mail server.what are the ways to achieve this.

View 2 Replies View Related

Firefox4/5 Not Running JS Attached To An AJAX Response Using HTML_AJAX Pear Library?

Jun 26, 2011

I am using the HTML_AJAX package in PEAR (admittedly an old library, but it has worked fine for me for a couple of years and I don't want to leave my infrastructure). The problem I am having is that with the introduction of Firefox 4, and now also Firefox 5, JavaScript that is included in responses using HTML_AJAX.replace(div_target, request_page) [API is to replace div_target with the response from request_page] has stopped working.

It works fine on Chrome, IE9, Android, iPhone, etc. but not FF4/5. Is this some sort of new feature, security mechanism, or just a plain old bug? If it's a bug, is it a bug with HTML_AJAX (i.e. you can do it with jQuery?) or is this something FF needs to fix?

Example.This page exists:

<script type="text/javascript" language="JavaScript">
function do_replace(){
HTML_AJAX.replace("something", "index.php?key=value"); // index.php will have html mixed with JS and paste it to the div "something".
}
</script>

[Code]...

I tried finding the answer to this by searching but couldn't find anything conclusive.

View 2 Replies View Related

Spreadsheet_Excel_Writer Question

Nov 18, 2005

I am using Spreadsheet_Excel_Writer and it works great for creating Excel files on the fly. However, I am having trouble trying to get some data to be saved correctly.

We have UPCs, like 050000235001, and the leading zero gets removed. I know in Excel you can format the cell to a text type, but how do I do that when creating the spread sheet?

There is setNumFormat() but that only formats number types, like percentages, dates, times, etc.

View 3 Replies View Related

Spreadsheet_Excel_Writer Fatal Error

Jan 21, 2007

I am switching hosts and copying the files over without change. I get the following error when trying to create a spreadsheet:

Fatal error: Call to a member function on a non-object in
/home/pmiweb/www/www/download_stores.php on line 68

Here is the code from the page: ....

View 3 Replies View Related

Spreadsheet_Excel_Writer Data Output Is Damaged?

Apr 20, 2010

I use Spreadsheet_Excel_Writer to generate .xls file and it works fine until I have to deal with a large amount of data. On certain stage it just writes some nonsense chars and quits filling certain columns. However some columns are field up to the end (generally numeric data) I'm not quite sure how the xls document is formed: row by row, or col by col... Also it is obviously not an error in a string, because when i cut out some data, the error appears a little bit further. I think there is no need in all of my code here are some essentials

$filename = 'file.xls';
$workbook = & new Spreadsheet_Excel_Writer();
$workbook->setVersion(8);

[code]....

View 2 Replies View Related

Output More Than 255 Characters In An Excel Cell Using Spreadsheet_Excel_Writer()?

May 11, 2009

I am trying to output a few paragraphs of text in an Excel spreadsheet, but right now the text is truncated to display only 255 characters. The code is pretty straightforward:

$xls =& new Spreadsheet_Excel_Writer();
$sheet =& $xls->addWorksheet($name);
foreach ($rec as $field) {
$rec = ($rec['data'] ? $rec['data'] : $rec);
$sheet->write($row, $col++, $field);
}

Is there anything I can do to get all of the text, not just the 255 chars?

View 1 Replies View Related

Spreadsheet_Excel_Writer Making Rows Width Longer?

Jan 4, 2010

How can i make rows a bid longer? if i output the excel all prints fine, only if the title is a bit long, then the Title is not readable.

View 1 Replies View Related

Adjust Width Of Cells So They Do Not Cut Words In Spreadsheet_Excel_Writer?

Dec 22, 2010

I am trying to create an Excel sheet using the Spreadsheet_Excel_Writer that comes with Pear. The sheet is created, and all is OK, Except, My words are being cut and the cells does not adjust their width to accommodate complete words. I try to open it with Office 2007. What values do I have to put into the Spreadsheet_Excel_Writer_Format object for that?

View 1 Replies View Related

PEAR Sendmail - Fatal Error: 'PEAR.php' Is Not A Valid Path

Dec 10, 2009

Code: [Select] require '/usr/share/php/Mail.php';
$recipients = 'dennismonsewicz@gmail.com';
$headers['From'] = 'me@me.com';
$headers['To'] = 'dennismonsewicz@gmail.com';
$headers['Subject'] = 'Test message';
$body = 'Test message';
[Code]...

If I do not include the file using an absolute path I get the following error message: Code: [Select]Fatal Error: 'PEAR.php' is not a valid path But if I include the file with the absolute path I then get a blank page....

View 3 Replies View Related

PEAR Newbie Trying To User PEAR DB And Falling At The First Hurdle

Dec 3, 2007

I've just installed PEAR on my local machine and all is well, updated
the include_path to point to my PEAR dir. So, when I just try to make
a simple connection like so the script just seems to stop but no error
messsages. I do get error messages normally (ie. when I can a method
from an object that doesnt actually exist) as I have set...

View 11 Replies View Related

Exactly Does Doctrine Need PEAR Installer And Pear Package?

Feb 9, 2010

I'm trying to install this ORM library, but I see it requires PEAR Installer and Pear Package,where are they used?

View 1 Replies View Related

Advantages To Upgrading To PEAR::MDB2 From PEAR::DB?

Mar 18, 2011

We have a very large legacy codebase and I was wondering if there's any REAL advantage to upgrading to MDB2.

View 1 Replies View Related

Installing Pear With Wamp - Could Not Open Input File: "PEARgo-pear.phar"

May 26, 2010

I'm having problems installing pear on my local machine that has Wamp installed. Full setup as follows

Windows XP Pro
Wamp Server Version 2.0
php 5.3.0

I'm reading all over the net that pear has install issues with php 5.3. if i open a dos window and type C:wampinphpphp5.3.0go-pear.bat. I get an error saying: Could not open input file: PEARgo-pear.phar I've tried the workaround that is stated as getting round this problem php -d phar.require_hash=0 go-pear.phar but this doesn't work as I get this error Could not open input file: go-pear.phar

I have tried the non-pharred version from [URL] and run it in the command window using the command below and also from a browser window by pointing to go-pear.php php -q go-pear.php I get lots of "PHP Deprecated: Function ereg() is deprecated in" errors and the install doesn't go correctly.

View 1 Replies View Related

PEAR Installation Without Go-pear.bat On Windows?

Nov 23, 2010

I have installed PHP 5.3.3 on my machine without pear. But now i want to install on my machine without removing the existing configuration. In there any way to manually update PEAR without go-pear.bat on windows ?

View 1 Replies View Related

Use Zfdatagrid Library In Application / Tack Overflow Thread Zend Framework 1.10 Custom Class Inside Library Folder Not Found?

Nov 5, 2010

I am seeking to learn how to implement a grid in an application I am working on and I figured I will use zfdatagrid as it seems to take care of some of the features I need. However there is not much by way of tutorial on the net. Probably because its easy to figure out, but thing is I need help to understand how use it. I will appreaciate any link that can help or if one will be kind to give me some pointers here.

I now get the following error:

Fatal error: Class 'Bvb_Grid' not
found in
D:wwwlabzfdatagridapplicationcontrollersIndexController.php

and below is my indexAction
public function indexAction()
{
//Zend_Config
$config = new Zend_Config_Ini(getcwd().'..applicationgridsgrid.ini', 'production');
var_dump($config);
//Grid Initialization
$grid = Bvb_Grid::factory('Bvb_Grid_Deploy_Table', $config, 'id');
//Setting grid source
$grid->setSource(new Bvb_Grid_Source_Zend_Table(new Bugs()));
//CRUD Configuration
$form = new Bvb_Grid_Form();
$form->setAdd(true)->setEdit(true)->setDelete(true);
$grid->setForm($form);
//Pass it to the view
$this->view->pages = $grid;
$this->render('index');
}

The Bvb library is located in the Library folder.

Well silly me I found the solution to the problem in another Stack Overflow thread Zend Framework 1.10 custom Class inside library folder not found

I thought of deleting the question then I thought this may save someone following this thread a google.

View 1 Replies View Related

Invalid Library (maybe Not A PHP Library) 'libmysql.dll' PHP5

Jul 17, 2005

WinXP Pro, Apache 1.3.27, trying to add PHP 5.0.4 with MySQL support to
the mix. Everything works fine until I add 'extension=libmysql.dll' to
php.ini, and then starting Apache gives me the same error popup two or
three times, all with the same message:

PHP Startup: Invalid library (maybe not a PHP library) 'libmysql.dll'

I've tried all manner of variations of extension_dir, and copied
libmysql.dll from the php5 distro into c:windowssystem32, all to no
avail. PHP seems to work otherwise, but there's no MySQL support.

View 6 Replies View Related

PEAR Channel - Easier Alternatives Than Setting Up My Own PEAR Channel?

Sep 20, 2010

So I guess a PEAR channel is like a server that lets you distribute your own PEAR packages? I was under the impression PEAR was sort of dead, until I started looking at Symfony (is it dead? I haven't used it in the past so maybe someone with more experience in PHP can comment on its state and whether it makes sense to invest any time in it)

Anyway my question. Why do I need to set up my own PEAR channel? There's a page here maintained by the PEAR project http://pear.php.net/channels/ but it looks like it may be just a list of PEAR channels as opposed to a public PEAR channel. Are there easier alternatives than setting up my own PEAR channel?

View 3 Replies View Related

Graph Library For IPhone And Android / Find A Single Graph Library That Works On Both These Devices Using The Mobile Framework?

Mar 1, 2011

I have been using JQuery Mobile Framework to develop a mobile version of my website accessible from iPhone and Android devices. I am unable to find a single graph library that works on both these devices using the mobile framework.

View 2 Replies View Related

Pear Shaped PEAR

Oct 27, 2007

I read about PEAR in here a few days ago and thought I would give it a try
but I have got myself in a mess with the installation. I have found some
guides but they seem to move swiftly on from installation and get down to
using it.

I am using PHP 5.2.3 which came with NuSPhere PhED and is installed under...

View 1 Replies View Related

GD Library And The FreeType Library

Jul 6, 2001

To use ImageTTFText() it says on php.net that you have to have the following...
This function requires both the GD library and the FreeType library.

can someone just confirm for me quickly, this is something that needs to be installed on the server? before i hassle my host as to why it says nowhere on their site if its installed or not.

View 5 Replies View Related

To PEAR Or NOT To Pear?

Nov 12, 2003

This is just a discussion type post, I'm interesed to know your opinion and experiance with Pear Libraries, I have used some Pear libraries a while back, but not enough to form an opinion wheather it is worth it or not. Some of the question I have is scalability and performance specs, and if I ever have to switch hosts do I need to make sure they have the same version or are they usualy backward compatible... so to Pear or Not to Pear that is the question?

View 1 Replies View Related

PEAR DB Help

Dec 17, 2006

I am currently running Windows XP Pro with PHP 5.2 and MySQL 5.0 installed. My remote server is a UNIX system with PHP 5.1 installed and MySQL 5.0 installed. Here is the code I'm trying to run:

// Load up the PEAR DB class //
$this->mysql = DB::connect(sprintf("%s://%s:%s@%s/%s", TYPE, USERNAME, PASSWORD, HOST, DATABASE));
echo "hello";

On my computer it works perfectly fine, returns a db_mysql class and no errors. On my server it does nothing. I put echo "hello" there as a test, and when I run the script I don't even see "hello" get printed to the screen, for some reason it's just screwing the entire script up. I checked the USERNAME, PASSWORD, etc. values against the ones I have in CPANEL and they match. Does anyone know what might be causing this problem?

View 5 Replies View Related

What Is PEAR? What's It Do?

Jun 3, 2002

What is PEAR? What's it do? What's it useful for?

View 2 Replies View Related

OOP And Pear::DB

Jul 17, 2005

I am currently working on a PHP application which I am using as a
personal learning environment for getting a better working
understanding about how to tackle application development in an OOP/MVC
pattern fashion.

I am using PEAR::DB to create database connection objects, and my major
question concerns where these objects should be created.

For example: Let's say I have a login application that that has a
controller-like script that looks something like this:

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// login.php
<?php
require_once('User.class.php');

$user = new $User;
$user->getAdminRights();
?>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

....and a model-like User class that looks something like this: (The
important note is that I may need to load data multiple times from a
database.)

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// User.class.php
<?php

class User
{
public $user_name;
public $user_id;
public $admin_rights = array();
protected $db_connection;

function __construct()
{
if (!this->db_connection){
require_once();
$this->db_connection = DB::connect(DB_DSN);
}

$sql = "SELECT USERNAME, USER_ID FROM SOME_TABLE...";
$result = $this->dbh->getAll($sql, array($this->request_id);
$this->user_name = $result['USERNAME'];
$this->user_id = $result['USER_ID'];
}

function getAdminRights()
{
$sql = "SELECT * FROM SOME_TABLE WHERE ADMIN_ID = ?";
$this->admin_rights = $this->dbh->getAll($sql,
array($this->user_id);
}

}
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

View 3 Replies View Related

Pear

May 17, 2006

kann somebody tell me what i do wrong?

i write this little script:
<?php
include_once "DB.php";
// Example:

echo "Hi";
?>

then, i have the first page von "go-pear"

View 4 Replies View Related

PEAR: Is It Really Necessary?

Jul 28, 2006

I've been using PHP for a while now but I haven't actually used PEAR. I
have just read half a chapter in a book, it sounds alright but haven't
actually used it. I was just wondering, is it really necessary to use
PEAR? I usually get things done using PHP/MySQL. I don't know if I'm
really missing out on something by not using PEAR. How highly is it
recommended? On most job ads, i don't even see them mentioning PEAR.
They mostly just say PHP/MySQL.. Why is that? Don't people like PEAR
much?

View 5 Replies View Related

To Pear DB Or Not To Pear DB?

Feb 2, 2004

i'm developing a small web app for a non-profit i'm affiliated with and i'm not sure if i want to use the pear DB abstraction layer or not. i've got a simple page currently developed w/o it, so all my database calls are using MySQL specific functions.
i know that using the pear DB is good if, say, we end up changing databases down the road, but i highly doubt we will.

i mean, MySQL isn't going anywhere, right? anyhow, i just simply don't like pear DB. maybe the fact that it took me a friggin hour to install it has something to do w/ that. also, i'm re-writing the simplest of code using DB functions and i'm having a hell of a time, probably b/c i have nothing but a cheesy pear manual to go by.

View 6 Replies View Related

A DB.php PEAR

Feb 15, 2004

I am preparing a few PHP scripts conversion to registerglobals=Off And presently testing a new login script that requires PEAR I tested it on my local RH and it works fine in both configurations (with registerglobals On or Off) But on a production server that I do not manage it does not work.

And does not display anything (Blank screen)In order to narrow down the problems I used
<? Error_reporting (E_ALL) ;?> Which shows that my “require” for DB.PHP class does not find it. How can I find if PEAR is made available? And if it is. Is the directory that contains the PEAR files included in my include_path in my php.ini. And if so do I have to provide a path?

View 1 Replies View Related

PEAR: Yes Or No

Mar 9, 2005

Some PEAR packages seam really cool but I worry about my code starting to be too *dependant* on PEAR if I start using it. You know, the way it handles errors, etc. What are your thoughts? Recommendations?

View 1 Replies View Related

Using PEAR

Sep 19, 2007

im not getting into using pear but i have a problem, im not sure how it works exactly i have read the website but i contacted my shared server host they say:

Please note that the path to pear package on the server is:

/usr/local/lib/php/

but not sure how to incorporate that in scripts do i need to include a certain file?

View 2 Replies View Related

PHP 5 And PEAR

Jul 17, 2005

I've been using PHP for a while now - and have recently been trying to set up PHP, MySQL and Apache on Windows (for a client). It seems like all the PEAR stuff under PHP 5 doesn't work out of the box. It took me a while to track down the go-pear.bat file in the root - what with all the other garbage in there. Shouldn't this file get at least a mention in:

install.txt and /PEAR/go-pear.php

The installation instructions in /PEAR/go-pear.php for Windows seem rather out of date - and sent me off in totally the wrong direction :-

(
--
__________
|im |yler http://timtyler.org/ tim@tt1lock.org Remove lock to reply.

View 13 Replies View Related

What Is PEAR?

Aug 9, 2004

What is the use of PEAR? How can I get it working with localhost IIS

I am using PHP Version 4.3.2
Server API CGI/FastCGI
I've a PEAR directory in c:/php4/includes/pear
whenever I enable it in php.ini, I get errors in my php applications e.g.,

Fatal error: main(): Failed opening required 'mainfile.php' (include_path='C:php4includespear') in C:Inetpubwwwroot
ukehtmlincludescounter.php on line 25

other examples of error:

Fatal error: main(): Failed opening required 'PEAR.php' (include_path='.;../phpwebsitelibpear') in C:InetpubwwwrootphpwebsitelibpearHTMLTemplateIT.php on line 22

Warning: main(): Failed opening '/path/to/xoops/directory/include/common.php' for inclusion (include_path='.;c:php4pear') in C:Inetpubwwwrootxoopshtmlmainfile.php on line 60

View 1 Replies View Related

PEAR DB

Jul 17, 2005

is when no row is found:

$what = $db->getOne("SELECT field FROM table WHERE 1=2");
if($what=="") echo "emptystring";
if($what==false) echo "false";
if($what==NULL) echo "null";
echo $what;
echoes "emptystringfalsenull".
$id = $db->getOne("SELECT id FROM table WHERE condition='fulfilled');
// this one?
if($id=="") do_something();
// or this one?
if($id==false) do_something();
// or that one?
if($id != NULL) do_something();

else do_something_else($id).

View 3 Replies View Related

ADVERTISEMENT