Letractively / magento-w2p

Automatically exported from code.google.com/p/magento-w2p
0 stars 0 forks source link

Page size NaN #647

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
See http://code.google.com/p/magento-w2p/issues/detail?id=513#c29

Older templates have no page size and the table shows NaN.
Make a check if the value is there and do not show the table at all if no 
values provided. It's OK to check just one of the values. 

Original issue reported on code.google.com by ad...@zetaprints.com on 7 Sep 2011 at 11:58

GoogleCodeExporter commented 8 years ago
How come Jpeg has inches?
It should be pixels.

Original comment by ad...@zetaprints.com on 21 Sep 2011 at 1:38

Attachments:

GoogleCodeExporter commented 8 years ago
Then we don't need to have an unit parameter. Pixels will be used for images 
and inches are for PDFs.

Original comment by Anatoly....@gmail.com on 21 Sep 2011 at 4:36

GoogleCodeExporter commented 8 years ago
PDF can be IN or CM, images are always in PX

Original comment by ad...@zetaprints.com on 21 Sep 2011 at 6:10

GoogleCodeExporter commented 8 years ago
Ok, I see.

Original comment by Anatoly....@gmail.com on 21 Sep 2011 at 7:25

GoogleCodeExporter commented 8 years ago
There's no info about images size in PX in template details.

Original comment by Anatoly....@gmail.com on 23 Sep 2011 at 8:46

GoogleCodeExporter commented 8 years ago
I think you can go by the page size in * 300dpi for jpg and in * 96dpi for 
gif/png.
Put it on hold. I'll add it to xml on Sun.

Original comment by ad...@zetaprints.com on 23 Sep 2011 at 10:15

GoogleCodeExporter commented 8 years ago
Added new attributes to PAGE element

WidthPxJpg="150" HeightPxJpg="150" WidthPxGifPng="150" HeightPxGifPng="150"
Use them for jpg/gif/png files.
Gif and png always have the same size.

Example from 
http://realestate.zetaprints.com/?page=template-xml;TemplateID=2405E3C9-3711-469
7-848E-747BB62739D5

<TemplateDetails TemplateID="2405E3C9-3711-4697-848E-747BB62739D5" 
CorporateID="C2A4F04E-401A-4D98-9B0A-220523DB803E" Comments="" 
GenerateGifPng="1" GenerateJpg="1" Download="only" 
AccessURL="http://realestate.zetaprints.com/Badges/BAdge-I.htm" 
ProductReference="" VersionLatest="20110707000000" Outdated="1">
−
<Pages>
−
<Page Name="Page 1" 
PreviewImage="preview/54b90995-7e46-4e9d-a16b-ea2635fb80fe-0.png" 
ThumbImage="thumb/54b90995-7e46-4e9d-a16b-ea2635fb80fe-0.png" WidthPx="150" 
HeightPx="150" WidthPxJpg="150" HeightPxJpg="150" WidthPxGifPng="150" 
HeightPxGifPng="150" WidthCm="1.27" HeightCm="1.27" WidthIn="0.5" 
HeightIn="0.5" Page2BoxX="0" Page2BoxY="0.999" Page2BoxW="0.0012" 
Page2BoxH="0.001">

Original comment by ad...@zetaprints.com on 25 Sep 2011 at 5:45

GoogleCodeExporter commented 8 years ago
Diff: http://code.google.com/p/magento-w2p/source/detail?r=1800

Original comment by Anatoly....@gmail.com on 25 Sep 2011 at 6:15

GoogleCodeExporter commented 8 years ago
Please, test with 1.9.2.0alpha2 release.

Original comment by Anatoly....@gmail.com on 25 Sep 2011 at 6:05

GoogleCodeExporter commented 8 years ago
Tested on /mageimage/
web_to_print_store_incl_theme   1.9.2.0alpha2 (alpha)

1. Old templates still show NaN values:
http://d1.zetaprints.com/mageimage/index.php/sample-stationery/subcategory-01/bu
siness-card.html

2. Page size settings get overwritten on extension upgrade. I had it activated 
on mageimage, updated to alpha2, my changes were removed from view.phtml file. 
Can we avoid this or should I add it to the help post?

Original comment by agur...@gmail.com on 26 Sep 2011 at 3:31

GoogleCodeExporter commented 8 years ago
Anatoly, can you check we is in the XML?
Do we give you NaN in there or is it produced at your end?

Original comment by ad...@zetaprints.com on 27 Sep 2011 at 12:46

GoogleCodeExporter commented 8 years ago
Diff: http://code.google.com/p/magento-w2p/source/detail?r=1802

Original comment by Anatoly....@gmail.com on 27 Sep 2011 at 5:02

GoogleCodeExporter commented 8 years ago
Please, test it with 1.9.2.0alpha3 release

Original comment by Anatoly....@gmail.com on 27 Sep 2011 at 6:00

GoogleCodeExporter commented 8 years ago
Please, test with 1.9.2.0alpha3 release

Original comment by Anatoly....@gmail.com on 27 Sep 2011 at 6:01

GoogleCodeExporter commented 8 years ago
Tested on /mageimage/
web_to_print_store_incl_theme   1.9.2.0alpha3 (alpha)

The page size table only shows on templates that have the size info (newly 
uploaded templates). The old ones show no table. I tried reprocessing an old 
template, refreshed the Magento product page and the table appeared. Works fine.

Question:
Does the view.phtml file get overwritten on extension upgrade? I need to know 
if it does so that I include it in the help post. I can't really tell from 
testing since /mageimage/ Download Manager is buggy and I need to uninstall the 
extension and then install the newer version of it. It gets overwritten this 
way, not sure if this is the case with a regular upgrade.

Original comment by agur...@gmail.com on 28 Sep 2011 at 12:14

GoogleCodeExporter commented 8 years ago
zptheme doesn't include it. It's an optional block.

Original comment by Anatoly....@gmail.com on 29 Sep 2011 at 6:48

GoogleCodeExporter commented 8 years ago
But it must include it or modify it in some way, it contains stuff like:
<?php $this->helper('webtoprint/personalization-form')->get_text_fields($this); 
?>
<?php 
$this->helper('webtoprint/personalization-form')->get_image_fields($this); ?>
which is ours, isn't it?

Original comment by agur...@gmail.com on 29 Sep 2011 at 8:40

GoogleCodeExporter commented 8 years ago
rewording the comment above: where the heck is this additional page size block 
documented?

Original comment by ad...@zetaprints.com on 29 Sep 2011 at 8:57

GoogleCodeExporter commented 8 years ago
See Optional section in 
http://code.google.com/p/magento-w2p/wiki/CustomThemeNative#Files_in_app/design/
frontend/default/%3Cyour_theme_name%3E/

Original comment by Anatoly....@gmail.com on 29 Sep 2011 at 11:23

GoogleCodeExporter commented 8 years ago

Original comment by Anatoly....@gmail.com on 30 Sep 2011 at 7:02

GoogleCodeExporter commented 8 years ago
Ok, let me put it this way.

Option 1:
The help post that I'll write includes the following note:
- Your page size tables will get deactivated after the next web-to-print 
extension upgrade. After Upgrading the extension, you'll need to repeat this 
process and edit the view.phtml file again as explained in order to show size 
tables of your w2p products.

Option 2:
The help post that I'll write does not include the above note.

Select the right answer :)

Original comment by agur...@gmail.com on 30 Sep 2011 at 8:30

GoogleCodeExporter commented 8 years ago
Atanas, I lost you. Better discuss it face to face.

Original comment by ad...@zetaprints.com on 30 Sep 2011 at 9:59

GoogleCodeExporter commented 8 years ago
Option 3: edit view.phtml file of your custom theme and page size tables will 
stay with you forever :-)

Original comment by Anatoly....@gmail.com on 30 Sep 2011 at 11:52

GoogleCodeExporter commented 8 years ago
Thx Anatoly!
that's what I needed to know.

Original comment by agur...@gmail.com on 30 Sep 2011 at 11:57

GoogleCodeExporter commented 8 years ago

Original comment by Anatoly....@gmail.com on 11 Oct 2011 at 5:54

GoogleCodeExporter commented 8 years ago
http://www.zetaprints.com/magentohelp/display-page-sizes/

Original comment by agur...@gmail.com on 22 Nov 2011 at 10:43