Forum


Replies: 9   Views: 6829
Cannot run examples
Topic closed:
Please note this is an old forum thread. Information in this post may be out-to-date and/or erroneous.
Every phpdocx version includes new features and improvements. Previously unsupported features may have been added to newer releases, or past issues may have been corrected.
We encourage you to download the current phpdocx version and check the Documentation available.

Posted by Count Belisarius  · 19-11-2012 - 11:24

Hi,

I've just installed the free version as I need to trial this to make sure it will work for us so I can justify the purchase.

I've installed it on our Windows Server 2008 based setup (using FastCGI in IIS) and when I run any of the samples I get:

[code]Strict Standards: Declaration of CreateStyle::generateB() should be compatible with CreateElement::generateB($strVal = 'single') in C:\inetpub\wwwroot\asc\phpdocx\classes\CreateStyle.inc on line 2643

Strict Standards: Declaration of CreateStyle::generateRFONTS() should be compatible with CreateElement::generateRFONTS($font) in C:\inetpub\wwwroot\asc\phpdocx\classes\CreateStyle.inc on line 2643

Strict Standards: Declaration of CreateTheme1::generateLN() should be compatible with CreateElement::generateLN($w = '12700') in C:\inetpub\wwwroot\asc\phpdocx\classes\CreateTheme1.inc on line 1270

Strict Standards: Declaration of CreateTheme1::generateSCHEMECLR() should be compatible with CreateElement::generateSCHEMECLR($val = 'tx1') in C:\inetpub\wwwroot\asc\phpdocx\classes\CreateTheme1.inc on line 1270

Strict Standards: Declaration of CreateTheme1::generatePRSTDASH() should be compatible with CreateElement::generatePRSTDASH($val = 'sysDash') in C:\inetpub\wwwroot\asc\phpdocx\classes\CreateTheme1.inc on line 1270[/code]

We're using PHP 5.4.7.

I'll admit to being quite new to PHP so any pointers would be appreciated.

Cheers

Andy

Posted by Count Belisarius  · 11-04-2013 - 12:13

Ok Thanks.

I'm pushing for a purchase of Pro+ to allow to evaluate and test fully.

Should it be (relatively) straightforward to create an HTML document with all it's relevant formatting and tables and hidden DIVs etc. and then have a DOCX button that basically dumps the entire page (using the print css) to a DOCX file?

Andy

Posted by admin  · 11-04-2013 - 12:13

Hello,

Yes, it shouldn't be difficult to do that button using any programming language.

Regards.

Posted by admin  · 11-04-2013 - 12:13

Hello,

Strict Standard usually isn't error but a kind of notice. Do you get any DOCX file?, please note that in most examples the document is generated in filesystem and not show a dialog to download the file.

Regards.

Posted by Count Belisarius  · 11-04-2013 - 12:13

Ahhhh... :)

You are right. The document was created in the filesystem. Must try RTFM :)

I had tried turning off the reporting but couldn't get rid of the message. Probably missing something in the php.ini....

We currently have a web app that generates HTML reports which we were just printing to PDF. We now need to send the output to .docx and looking at phpdocx it seems we can use the existing HTML generating code and feed it into your libraries? Obviously not that straightforward but in principle?

Is there an example somewhere to get a document opening automatically in Word? We would like to be able to generate the HTML report for review then click a button to launch the output in Word. The bulk of the data is in tables.

Would appreciate a couple of pointers please as if this will work we will be looking at a Corp licence.

Thanks for your quick response.

Andy

Posted by admin  · 11-04-2013 - 12:13

Hello,

Yes, you can embed HTML, as altChunk tag, only compatible in MS Office, or transforming it to WordML, compatible with any program that reads DOCX files.

About opening in Word, you can use createDocxAndDownload method to download the document and if Word is the default app to open DOCX file it should be opened.

Regards.

Posted by Count Belisarius  · 11-04-2013 - 12:13

Is createDocxAndDownload part of the free version? I get a function undefined?

Posted by Count Belisarius  · 11-04-2013 - 12:13

Just looked at the version info and the html is not part of the free version...

I don't think I can move forward on this without being able to test that as there is not much chance of OK'ing even small expenditure unless I can demo that it may do the job...

Do you have any sort of trial options?

I'm currently dealing with this through my personal email etc. but I can move to my 'official' if needed? :)

Andy

Posted by admin  · 11-04-2013 - 12:13

Hello,

There's no trial, but three demos availables on:

http://www.phpdocx.com/demo

Regards.