Jump to content
Winno

[Module] Catálogo Virtual

Recommended Posts

Boas,

Acabei de criar um módulo de catálogo Virtual (à la iPhone) utilizando uma ferramenta gratuita chamada cooliris (http://developer.cooliris.com/).
EDIT: para ver os valores possíveis das configurações cooliris ir a http://developer.cooliris.com/?p=embed/flash
No meu caso como as fotos tinham fundo branco optei por usar o mesmo fundo. Nem todas as variáveis estão contempladas, mais uma coisa para a ToDo list.

A ideia era navegar em todos os produtos do catálogo pelo método de arrastar com o rato, ver imagem ampliada, etc.
Este catálogo abre numa janela ThickBox (sobre o site).

Para isso foi necessário «modificar» o template de cabeçalho para incluir o javascript e a folha de estilos (ler o readme.txt)
algumas configurações, tais como tamanho da janela, etc. estão nos ficheiros (isto vai para a minha ToDo list da próxima versão)

Esta é a minha primeira contribuição, e ainda numa versão embrionária.
Neste momento, o módulo vai buscar todos os produtos por ordem do mais novo para o mais antigo. No futuro arranjar forma de mostrar por categorias, etc...

Foi desenvolvida para a versão 1.2.4 mas acho que não há problemas de compatibilidade.
Se encontrarem alguns bugs ou melhorias, por favor deixem os vossos comentários.

Poderão ver a versão on-line deste módulo em

http://livraria.vidaeconomica.pt

EDIT: correcção no ficheiro catalogoxml.php, no caso do prefixo da BD não ser ps_

UPDATED: English instructions

Winno

catalogovirtual.zip

Share this post


Link to post
Share on other sites

Very interesting module ! thanks

But I have no picture displayed ! (PS 1.2.5)

I did readme.txt

17543_Z1Qb570QCJPrIeXRjbBD_t

Share this post


Link to post
Share on other sites
Very interesting module ! thanks

But I have no picture displayed ! (PS 1.2.5)

I did readme.txt


There's a correction in catalogoxml.php in case your DB prefix is not ps_

Winno

Share this post


Link to post
Share on other sites

Hi,

Correction to readme.txt:

<link href="{$content_dir}css/thickbox.css" rel="stylesheet" type="text/css" media="screen" />
instead of
<link href="/css/thickbox.css" rel="stylesheet" type="text/css" media="screen" />
in header.tpl

Ok, the file catalogoxml.php is created «correctly», it's problem with the image path:

/frantic/boutique/img/p/10-52-detail.jpg
and
/frantic/boutique/img/p/10-52-thickbox.jpg

do not exist in this path.

Can you confirm me the right image path?

Winno

Share this post


Link to post
Share on other sites

Hi,

I think o got the last problem: you don't have images called «detail» (Admin ->preferences->image)

So check the names you have (home, medium, etc...) and change in

catalgoxml.php line 33

echo $value["id_product"]."-".$id_imagem[0]["id_image"]."-detail.jpg";



the word detail by home or medium or any other you created

sry, i used detail because that's one i created :) . To have a nice effect image "thickbox" and the other you choose ("home", "medium", "large", etc) should have same proportions.

Cheers,
Winno

Share this post


Link to post
Share on other sites

I sow your boutique and now everything looks ok, even the link in the home page to open the window.

As i said (in portuguese) this is my first module posted, and it has some bugs.

I'll try to correct them and post a new version.

Cheers,
Winno

Share this post


Link to post
Share on other sites

The quality of the thunbail is better when using -large or -thickbox instead -medium.

Share this post


Link to post
Share on other sites

Hi,

Updated version with english readme translation.

Cheers,
Winno

Share this post


Link to post
Share on other sites

hello when i try http://localhost/modules/catalogovirtual/showcatalogo.php ,the cooliris windows open with write on it "One last step" and inside

<?xml version="1.0"?>





i think it can't make ythe xml file.

In read me you say
* in showcatalogo.php
Definition of the variables of cooliris app.


can you explain what should it be done exactly ?

sorry for my bad english i'm french :D

Share this post


Link to post
Share on other sites

Salut,

Je n'ais pas tenté de lancer le module au niveau local, mais l'idée est de copier le fichier

crossdomain.xml

à http://localhost/crossdomain.xml

La configuration du Flash
showcatalogo.php

$numRows = 2; /* number of lines — 1 to 7 */
$showChrome = 'false'; /*false or true*/
$style = 'white'; /* black | dark | light | white */
$linkTarget = '_top'; /* opens link in the same window */
$showSearch = 'true'; /* true or false */
$showFullScreen = 'false'; /*true or false */

Winno

Share this post


Link to post
Share on other sites

thank you for the module you are a geinus!
can I view only one category like price-drop in the virtual mode?

Share this post


Link to post
Share on other sites

Hi Kennyh,

For that you have to change the query(SQL) in catalogoxml.php (line 9).

The price-drop query is a bit complicated, because of starting and ending dates.

Cheers,
Winno

Share this post


Link to post
Share on other sites

Super Module mais j'ai le même problème que toi jolvil, comment a tu réglé le problème
des images qui ne s'affichent pas?


I have same problem as jolivil, no pictures are displayed? Could you told me how to fix that please.


Thank you.

Share this post


Link to post
Share on other sites

In version 1.2.5 this nice module works correctly, but i do not get to see the pictures in the version 1.3.2. I've installed exactly the same module, the template is the same, the same directory (root directory) and name of the images is the same (-medium) and they are set up correctly in preferences. Can you help me?

Share this post


Link to post
Share on other sites

I haven't tried it in 1.3.2 yet, but it seems like an image path problem, if the catalog appears on colliries except the images.
Could you please try something?

On your website see the path of the images (right-click on one image and get properties, the medium ones and the big ones)

open the link http://yourwebsite/modules/catalogovirtual/catalogoxml.php
View source code and search the lines (the first ones, for instances)



forget the jpg names but take a look if the path is the same (specially /img/p/).

If the path don't match change the lines 30 and 38 of catalogoxml.php

Hope this helps

Share this post


Link to post
Share on other sites

Thanks for you reply:

The cooliris appears, but not the images.

I have all product images in "http://www.mywebsite.com/img/p/"
and following your instructions, by right-clicking on some product images, the urls are like "http://www.mywebsite.com/7-24-large/ipod-touch.jpg" instead of displaying them as "http://www.mywebsite.com/img/p/7-24-large.jpg"

In 1.3.1.1 it does not occur and you can see the virtual catalog and the images perfectly, also by right-clicking on a product image, the url is "http://www.mywebsite.com/img/p/7-24-large.jpg" but the problem is in 1.3.2.3 and the images are not seen in virtual catalog, at least in my case.

Opening the link "http://www.mywebsite.com/modules/catalogovirtual/catalogoxml.php" and right-clicking in a product link, the url is "http://www.mywebsite.com/modules/catalogovirtual/www.mywebsite.com/product.php?id_product=7" and obviously that's wrong.

Regarding the image sizes (medium, thickbox, etc.) I have them set correctly, and I think there is an image path problem. I am attaching the catalogoxml.php line code because I do not know how to edit it.

Share this post


Link to post
Share on other sites

Hola!

He instalado el módulo y he seguido todos los pasos del fichero "readme.txt", pero no consigo de ninguna manera hacer que el catálogo se abra en la misma ventana. Siempre se abre en una ventana en blanco.

¿Alguien sabría decirme cómo solucionarlo?

Gracias!

Share this post


Link to post
Share on other sites

Hola,

he entrado en tu web y se abre en la misma ventana en la que estás navegando. No se si te refieres a abrir el catálogo en otra ventana del navegador. Para eso tendrías que cambiar el link del catálogo, incluyendo target="_blank", que estará en el archivo tpl del módulo:


por:


No se si te refieres a esto, ya que es muy básico. Si no es así, dime a ver si puedo ayudarte...

Un saludo

Share this post


Link to post
Share on other sites

Hola!

He cambiado lo que comentas y ahora se abre en una nueva ventana.
Lo que a mi me gustaría es que apareciara como en http://livraria.vidaeconomica.pt/
en la misma ventana de la tienda, como si se estuviera viendo una foto, con la tienda al fondo.

Muchas gracias!

Un saludo!

Share this post


Link to post
Share on other sites

If images don't showup or you're stuck with the "last step... crossdomain.xml"-error after upgrading your prestashop from 1.3.x to 1.4.x, this might help:

 

Do a search and replace for:

 

server_host

replace with:

_SERVER['HTTP_HOST']

 

in the following files:

/modules/catalogovirtual/catalogoxml.php

/modules/catalogovirtual/showcatalogo.php

 

[only tested with prestashop 1.4.7.0]

Share this post


Link to post
Share on other sites

Anyone have a version of this that works on v1.4 or 1.5? thnaks

 

Baz

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.

×
×
  • Create New...

Important Information

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