Jump to content

Retrieve current ID from module


jonsecu

Recommended Posts

Hi... I am using Prestashop 1.5.3. I am developing a module and I requiere to retrieve de current language ID to pass it to the Mail::Send method. This is the piece of relevant code, which is located on the main root of the module folder. So far I am passing manually a 4 to the Send method, I want to replace this int by a method/class/function or whatever that may retrieve the current language ID.

 

Any ideas please? Thank you very much.

$data = array(
     '{name}' => $inputName,
     '{link}' => _PS_BASE_URL_.__PS_BASE_URI__ . "index.php?fc=module&module=presentforme&controller=default&id_regalo=" . $insertedID,
     '{imgUrl}' => getProdImgUrl($productID),
     '{prodUrl}' => "http://www.prestashop.com",
     '{prodName}' => "Titulo",
     '{prodDesc}' => "Descripción"
  );

  Mail::Send(
      4, 
      'html_template_title',
      'A subject',
      $data, 
      $inputEmail,
      $inputName,
      '[email protected]', 
      'Example', 
      null, 
      null, 
      dirname(__FILE__).'/mails/', false, 
      false
      );
Link to comment
Share on other sites

  • 2 weeks later...

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...