Jump to content

load one module variable to another


Recommended Posts

Hi 

 

   

 

i have  module, product discount countdown which makes separate block which loads discount price products and shows timer

 

 

module is using following code to display countdown timer

  <div id="defaultCountdownc{$countdown.id_product}"></div>

i wana load it in featured deals section can i use it?

Link to comment
Share on other sites

It depends.

You must edit this 'featured deals' module's core php file. In the hook function where you want to display the timer, you must include the php file of the countdown module. Instantiate it, then run all the functions and assign the same variable.

 

OR

 

if you launch both modules, you can try running Module::getInstanceByName(''countdownmodulename') instead of having to include the other one. But again, the required steps change depending on the module's configuration.

 

Not easy at all ;)

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...