@@ 952-961 (lines=10) @@ | ||
949 | * |
|
950 | * @param string $stringValue |
|
951 | */ |
|
952 | private function writeStringRecord($stringValue) |
|
953 | { |
|
954 | $record = 0x0207; // Record identifier |
|
955 | $data = StringHelper::UTF8toBIFF8UnicodeLong($stringValue); |
|
956 | ||
957 | $length = strlen($data); |
|
958 | $header = pack('vv', $record, $length); |
|
959 | ||
960 | $this->append($header . $data); |
|
961 | } |
|
962 | ||
963 | /** |
|
964 | * Write a hyperlink. |
|
@@ 1868-1887 (lines=20) @@ | ||
1865 | /** |
|
1866 | * Store the header caption BIFF record. |
|
1867 | */ |
|
1868 | private function writeHeader() |
|
1869 | { |
|
1870 | $record = 0x0014; // Record identifier |
|
1871 | ||
1872 | /* removing for now |
|
1873 | // need to fix character count (multibyte!) |
|
1874 | if (strlen($this->phpSheet->getHeaderFooter()->getOddHeader()) <= 255) { |
|
1875 | $str = $this->phpSheet->getHeaderFooter()->getOddHeader(); // header string |
|
1876 | } else { |
|
1877 | $str = ''; |
|
1878 | } |
|
1879 | */ |
|
1880 | ||
1881 | $recordData = StringHelper::UTF8toBIFF8UnicodeLong($this->phpSheet->getHeaderFooter()->getOddHeader()); |
|
1882 | $length = strlen($recordData); |
|
1883 | ||
1884 | $header = pack('vv', $record, $length); |
|
1885 | ||
1886 | $this->append($header . $recordData); |
|
1887 | } |
|
1888 | ||
1889 | /** |
|
1890 | * Store the footer caption BIFF record. |
|
@@ 1892-1911 (lines=20) @@ | ||
1889 | /** |
|
1890 | * Store the footer caption BIFF record. |
|
1891 | */ |
|
1892 | private function writeFooter() |
|
1893 | { |
|
1894 | $record = 0x0015; // Record identifier |
|
1895 | ||
1896 | /* removing for now |
|
1897 | // need to fix character count (multibyte!) |
|
1898 | if (strlen($this->phpSheet->getHeaderFooter()->getOddFooter()) <= 255) { |
|
1899 | $str = $this->phpSheet->getHeaderFooter()->getOddFooter(); |
|
1900 | } else { |
|
1901 | $str = ''; |
|
1902 | } |
|
1903 | */ |
|
1904 | ||
1905 | $recordData = StringHelper::UTF8toBIFF8UnicodeLong($this->phpSheet->getHeaderFooter()->getOddFooter()); |
|
1906 | $length = strlen($recordData); |
|
1907 | ||
1908 | $header = pack('vv', $record, $length); |
|
1909 | ||
1910 | $this->append($header . $recordData); |
|
1911 | } |
|
1912 | ||
1913 | /** |
|
1914 | * Store the horizontal centering HCENTER BIFF record. |