Jump to content

Fatal error: Call to undefined method Media::addJsDef() in /var/www/modules/blocksearch/blocksearch.


Recommended Posts

Hello ,

after i update some module which is prestashop offerd in admin panel i get problem with shop

at first it shows only withe page and after turned on debug i got this error

Fatal error: Call to undefined method Media::addJsDef() in /var/www/modules/blocksearch/blocksearch.php on line 77

 

any advise ?

Edited by shahriar (see edit history)

Share this post


Link to post
Share on other sites

If You use module or template designed for prestashop 1.6 in 1.5 prestashop store You will get many errors like this:

 

Uncaught exception 'SmartyCompilerException' with message 'Syntax Error in template ...  on line ... unknown tag addJsDef or addJsDefL

 

From what I see Prestashop 1.5 does not have this functions.

 

Best regards

Barto

  • Like 1

Share this post


Link to post
Share on other sites

new modules, designed for 1.6 version in some cases will not work in old ps versions.

i know that this sounds weirdy, but unfortunately, it's hard to avoid that.

moreover, here on forum you can find several topics (for example related to product comments addon) related to the same problem.

before update is always worth to check module compability.

Share this post


Link to post
Share on other sites

same error here. Blank homepage.

 

Fatal error: Call to undefined method Media::addJsDef() in /var/www/modules/blocksearch/blocksearch.php on line 77

 

i was not lucky to replace the media file. It doesnt work for me. Any suggestions ?

Share this post


Link to post
Share on other sites

same error here. Blank homepage.

 

Fatal error: Call to undefined method Media::addJsDef() in /var/www/modules/blocksearch/blocksearch.php on line 77

 

i was not lucky to replace the media file. It doesnt work for me. Any suggestions ?

 

PrestaShop could do much better about their native free  modules checking that the ps version actually works...that being said..

 

I am attaching a native blocksearch module from a 1.5.6.1 installation.

 

uninstall the updated blocksearch then delete it and install this one

 

blocksearch.zip

Share this post


Link to post
Share on other sites

Sadly I am also affected by this and luckily I took a backup before installing the numerous updates.   I also asked about the Addons site providing access to a changelog so one can know the change and determine if they need it for their site or not.

Share this post


Link to post
Share on other sites

  • 4 months later...

I am on 1.6.0.2, and I received the same error.    

 

I FTP'd the version from the 1.6.0.2 zip file in /modules/blocksearch to my server, and it's working now.  

 

I guess clicking Update from Modules - Modules in the back office upgrades the module to the latest version and not the most compatible???? Really strange since 1.6.0.2 is the stable release at this time.

Share this post


Link to post
Share on other sites

I am on 1.6.0.2, and I received the same error.    

 

I FTP'd the version from the 1.6.0.2 zip file in /modules/blocksearch to my server, and it's working now.  

 

I guess clicking Update from Modules - Modules in the back office upgrades the module to the latest version and not the most compatible???? Really strange since 1.6.0.2 is the stable release at this time.

 

if at all possible,  upgrade to 1.6.0.9

Share this post


Link to post
Share on other sites

Thanks Patron.  This is good timing; I'll try that later this week.  

 

Can you give any pointers on when to download the latest revision?  I have worked with PS long enough to learn (the hard way) to customize as little as possible.  That being said, can you give some pointers when to upgrade to a new version?  What download page is the best for being the authority on the latest release?  

Thanks again for the help!

Teo

Share this post


Link to post
Share on other sites

Thanks Patron.  This is good timing; I'll try that later this week.  

 

Can you give any pointers on when to download the latest revision?  I have worked with PS long enough to learn (the hard way) to customize as little as possible.  That being said, can you give some pointers when to upgrade to a new version?  What download page is the best for being the authority on the latest release?  

Thanks again for the help!

Teo

 

when upgrading always follow the guide

http://doc.prestashop.com/display/PS16/Updating+PrestaShop

 

most important is having test shop to try upgrade...

 

I think 1.6.0.9 fixed many previous issues with 1.6...

 

but vekia (moderator) suggests waiting for 1.6.1

 

that being said, there is no reason not to start testing upgrading using your test copy...

Share this post


Link to post
Share on other sites

El Patron - 

Thanks for the info!  The upgrade went super smooth.  I completely re-built the PS installation, and it was up and running, fully configured, within 30 minutes - record speed.

 

1.6.0.9 is sooooooooo much better.  Just simple things like the automatic child menu on-hover in BO, and the theme configurator/logos on one page.  Thanks for the heads up!

 

Here's the link I was asking about; it might help others: http://www.prestashop.com/en/developers-versions

~/www/yourdomain/public_html#: wget http://www.prestashop.com/download/old/prestashop_1.6.0.9.zip

Share this post


Link to post
Share on other sites

El Patron - 

Thanks for the info!  The upgrade went super smooth.  I completely re-built the PS installation, and it was up and running, fully configured, within 30 minutes - record speed.

 

1.6.0.9 is sooooooooo much better.  Just simple things like the automatic child menu on-hover in BO, and the theme configurator/logos on one page.  Thanks for the heads up!

 

 

1.6.0.9 is da bomb...

 

tip: keep javascript loaded bottom, search forum (post new topic if questions) fight any theme developer or module maker that does not support javascript bottom, don't use their stuff, scream and yell to have them fix it.  be a rebel for a better web. 

Share this post


Link to post
Share on other sites

 Share

×
×
  • Create New...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More