uthando-cms / uthando-dompdf

BSD 3-Clause "New" or "Revised" License
1 stars 0 forks source link

undefined method ViewManager::getResolver() #1

Open JorgeBorda opened 7 years ago

JorgeBorda commented 7 years ago

hello, I just install your module.... and givme this error......

Fatal error: Call to undefined method Zend\Mvc\View\Http\ViewManager::getResolver() in C:\xampp\htdocs\XXXXXXXXXXXX\vendor\uthando-cms\uthando-dompdf\src\UthandoDomPdf\Mvc\Service\ViewPdfRendererFactory.php on line 44

bad install ?? , thanks for your help...

shaunfreeman commented 7 years ago

How did you install the module?

JorgeBorda commented 7 years ago

1) I went....cd my/project/directory

2) I add in the composer.json file with following contents:

{ "require": { "uthando-cms/uthando-dompdf": "2.*" } }

3) i have instaled PHP Composer

4) I run composer update

5) open my/project/directory/config/application.config.php and add the following key to your modules:

'cd my/project/directory

create a composer.json file with following contents:

{ "require": { "uthando-cms/uthando-dompdf": "2.*" } } install PHP Composer via curl -s http://getcomposer.org/installer | php (on windows, download http://getcomposer.org/installer and execute it with PHP)

run php composer.phar install

open my/project/directory/config/application.config.php and add the following key to your modules:

'UthandoDomPdf',',

6) then create inside module the directory "UthandoDomPdf"

7 Copy all infomation (module, src, test and view) in the directory..

8) and refresh the main window...

JorgeBorda commented 7 years ago

Hello....

I am new in Zf2, it is my first module that I install in my application, I have little experience .... ... I installed this module and it gives me the following error ...

Fatal error: Call to undefined method Zend\Mvc\View\Http\ViewManager::getResolver() in C:\xampp\htdocs\combustibles\vendor\uthando-cms\uthando-dompdf\src\UthandoDomPdf\Mvc\Service\ViewPdfRendererFactory.php on line 44

I think I have followed all the steps of installing the module ... that I may be missing ????

Thanks....

shaunfreeman commented 7 years ago

Check in your vendor/zendframework folder that 'zend-view' folder is there. If not add

"require": {
    "zendframework/zend-mvc": "2.*",
    "zendframework/zend-view": "2.*",
    "zendframework/zend-http": "2.*",
    "uthando-cms/uthando-dompdf": "2.*"
}

to your composer.json and then composer.phar update

shaunfreeman commented 7 years ago

also have a look at https://github.com/uthando-cms/uthando/blob/master/composer.json to see how I set up an zend MVC project.