PrestaShop Forum

The best place in the world to ask questions about PrestaShop and get advice from our passionate community!

PrestaShop Forum

Jump to content

[Solved] Help: How to open a ThickBox from a CSS page in 1.1?

6 replies to this topic
#1
disarci

    PrestaShop Fanatic

  • Moderators
  • 2041 posts
Please,
I need to open a thickbox with images from a page create by css.
No problem in code, I can integrate in cms.php or cms.tpl,
but I can't call the thickbox.

Tks

PS I followed this post but don't work for me:
http://www.prestasho...iewthread/6133/

#2
vinoalvino

    PrestaShop Addict

  • Members
  • PipPipPip
  • 841 posts
in .php file:


$css_files = array(__PS_BASE_URI__.'css/thickbox.css' => 'all');
$js_files = array(__PS_BASE_URI__.'js/jquery/thickbox-modified.js');

/** BEFORE INCLUDE HEADER!!!! **/
include(dirname(__FILE__).'/header.php');


in .tpl file:


{include file=$tpl_dir./thickbox.tpl}


Calling cms.php:

{l s='(read)'}

Al mondo ci sono 11 tipi di persone: quelli che capiscono/non capiscono il codice binario e quelli che trovano tutti i moduli su prestamodules :P
-- Realizzo moduli e personalizzazioni per prestashop --

#3
Wallstyle.se

    PrestaShop Newbie

  • Members
  • Pip
  • 7 posts
I don't get it to work, what can I possibly do wrong?

#4
vinoalvino

    PrestaShop Addict

  • Members
  • PipPipPip
  • 841 posts
Is the file in the root dir?
Al mondo ci sono 11 tipi di persone: quelli che capiscono/non capiscono il codice binario e quelli che trovano tutti i moduli su prestamodules :P
-- Realizzo moduli e personalizzazioni per prestashop --

#5
Wallstyle.se

    PrestaShop Newbie

  • Members
  • Pip
  • 7 posts
The reason that I want to have the thickbox in cms is because I want a picture with thickbox popup when you click a text link. I do not know how I can do it correct.

#6
disarci

    PrestaShop Fanatic

  • Moderators
  • 2041 posts
Ok,
it's different:

you have to put (like Vino said)
in .php file:

$css_files = array(__PS_BASE_URI__.'css/thickbox.css' => 'all');
$js_files = array(__PS_BASE_URI__.'js/jquery/thickbox-modified.js');

/** BEFORE INCLUDE HEADER!!!! **/
include(dirname(__FILE__).'/header.php');
in .tpl file:

{include file=$tpl_dir./thickbox.tpl}

But you can't do it from the CMS page (html) because it will be filtered, you have to enter directly in sql:

example:

Plant 1


Plant 1 Plant 1 Plant 1


#7
Wallstyle.se

    PrestaShop Newbie

  • Members
  • Pip
  • 7 posts
Thank you all very much :D It's working great!