使用php创建10行10列的电子表格

时间:2013-03-06 10:10:56

标签: php zend-gdata

我成功创建了一个包含大量行和列的电子表格 但我只想要10行10列

require_once('Zend/Loader.php');
Zend_Loader::loadClass('Zend_Gdata');
Zend_Loader::loadClass('Zend_Gdata_ClientLogin');
Zend_Loader::loadClass('Zend_Gdata_Docs');

// Authentication
$client = Zend_Gdata_ClientLogin::getHttpClient('you@there.com', 'sunshine-',        Zend_Gdata_Docs::AUTH_SERVICE_NAME);

// Get interface to Documents List API
$docs = new Zend_Gdata_Docs($client);

// Create new document
$data = new Zend_Gdata_Docs_DocumentListEntry();
$data->setCategory(
  array(new Zend_Gdata_App_Extension_Category(
          "http://schemas.google.com/docs/2007#spreadsheet",
          "http://schemas.google.com/g/2005#kind"
)));
$data->setTitle(new Zend_Gdata_App_Extension_Title("My brand new spreadsheet", null));

// Add document to your list
$doc = $docs->insertDocument($data, Zend_Gdata_Docs::DOCUMENTS_LIST_FEED_URI);

// Display document ID
print($doc->getId());

0 个答案:

没有答案