Print Product Tab Content Option

Hi

What would it cost to be able to print the content of a product tab, a mod / addon for that purpose. Just a specific tab, it does not need to be from the store front, from within the admin page of product might just do it for me as well.

Well, I do not think that such functionality needs third party modifications, you could just add a javascript snippet targeting the div of one tab (specify css-class). Look:

http://stackoverflow.com/questions/2255291/print-the-contents-of-a-div

Feel free to ask any more questions.

Well, I do not think that such functionality needs third party modifications, you could just add a javascript snippet targeting the div of one tab (specify css-class). Look:

http://stackoverflow.com/questions/2255291/print-the-contents-of-a-div

Feel free to ask any more questions.

The div I want to be able to print is

aanbevolen gebruik
meng 25 gram met 200ml koud water (geen melk!) en neem dit 2 uur voor of na de training in, danwel op een ander dagdeel. Voor een optimale smaakbeleving, 100g bevroren fruit (ananas, bessen, banaan, mango of perzik) toevoegen.
Dit kan ook een heerlijk dessert zijn na een maaltijd door 1 potie met 150ml melk (of water) met een elektrische garde gedurende 5 minuten op matig tot hoge snelheid op te kloppen tot een bavarois-achtige vla, die ook ingevroren kan worden.

bevat per dosering (25g)/100g
calorieën : 81kcal /324 kcal
eiwit 19,0g / 76,2g
- waarvan als BCAA 3,9g / 15,6g
koolhydraten 0,3g/1,3g
- waarvan als suiker <0,01g / 0,04g
vet 0,2g/0,7g
- waarvan als verzadigd vetzuur 0,07g / 0,3g
voedingsvezel 0,4g / 1,4g
natrium <0,01g / 0,01g
vitamine C 15mg/ 60mg - 25%/100% ADH
vitamine B3 (niacine) 4,5mg/ 18mg - 25%/100% ADH
vitamine E 2,5mg/ 10mg - 25%/100% ADH
vitamine B5 1,5mg/ 6mg - 25%/100% ADH
vitamine B6 0,5mg/ 2mg - 25%/100% ADH
vitamine B2 (riboflavine) 0,4mg/1,6mg - 25%/100% ADH
vitamine B1 (thiamine) 0,35mg/1,4mg - 25%/100% ADH
foliumzuur 50mcg/200mcg - 25%/100% ADH
vitamine B12 (cyanoB12) 0,25mcg/1mcg - 25%/100% ADH

ADH = Aanbevolen Dagelijkse Hoeveelheid

ingrediënten
vanille: eiwit (94% kippeneiwitpoeder), smaakstof (vanille-aroma), emulgator (soja-lecithine), verdikkingsmiddel (carrageen), zoetstof (acesulfaam K, natriumcyclamaat, saccharine), vitaminemengsel (ascorbinezuur, DL-alfa-tocoferylacetaat, nicotinamide, calcium-D-pantothenaat, pyridoxinehydrochloride, thiamine-mononitraat, riboflavine, pteroylmonoglutaminezuur, d-biotine, cyanocobalamine)
chocolade: idem maar smaakstof (4% ontvette cacaopoeder en chocolade-aroma)

bewaarvoorschrift
droog en afgesloten bewaren bij kamertemperatuur (15-22°C). 
buiten bereik van jonge kinderen houden

bijwerkingen en contra-indicaties
geen bijwerkingen bekend

allergenen informatie
bevat kippenei en soja-lecithine
bevat geen bekende allergenen (tarwe, gluten, soja, lupine, pinda's , noten, selderij, mosterd, sesam, koemelk, ei, vis, schaal-, schelp- of weekdieren)

vegetariërs/veganisten
bevat ei
wel geschikt voor vegetariërs

Based upon the link you gave I am not sure which solution to pick and or how to implement them. Any tip is welcome.

You can put javascript to the HTML block with Smarty support on the Products layout page

The div I want to be able to print is

aanbevolen gebruik
meng 25 gram met 200ml koud water (geen melk!) en neem dit 2 uur voor of na de training in, danwel op een ander dagdeel. Voor een optimale smaakbeleving, 100g bevroren fruit (ananas, bessen, banaan, mango of perzik) toevoegen.
Dit kan ook een heerlijk dessert zijn na een maaltijd door 1 potie met 150ml melk (of water) met een elektrische garde gedurende 5 minuten op matig tot hoge snelheid op te kloppen tot een bavarois-achtige vla, die ook ingevroren kan worden.

bevat per dosering (25g)/100g
calorieën : 81kcal /324 kcal
eiwit 19,0g / 76,2g
- waarvan als BCAA 3,9g / 15,6g
koolhydraten 0,3g/1,3g
- waarvan als suiker <0,01g / 0,04g
vet 0,2g/0,7g
- waarvan als verzadigd vetzuur 0,07g / 0,3g
voedingsvezel 0,4g / 1,4g
natrium <0,01g / 0,01g
vitamine C 15mg/ 60mg - 25%/100% ADH
vitamine B3 (niacine) 4,5mg/ 18mg - 25%/100% ADH
vitamine E 2,5mg/ 10mg - 25%/100% ADH
vitamine B5 1,5mg/ 6mg - 25%/100% ADH
vitamine B6 0,5mg/ 2mg - 25%/100% ADH
vitamine B2 (riboflavine) 0,4mg/1,6mg - 25%/100% ADH
vitamine B1 (thiamine) 0,35mg/1,4mg - 25%/100% ADH
foliumzuur 50mcg/200mcg - 25%/100% ADH
vitamine B12 (cyanoB12) 0,25mcg/1mcg - 25%/100% ADH

ADH = Aanbevolen Dagelijkse Hoeveelheid

ingrediënten
vanille: eiwit (94% kippeneiwitpoeder), smaakstof (vanille-aroma), emulgator (soja-lecithine), verdikkingsmiddel (carrageen), zoetstof (acesulfaam K, natriumcyclamaat, saccharine), vitaminemengsel (ascorbinezuur, DL-alfa-tocoferylacetaat, nicotinamide, calcium-D-pantothenaat, pyridoxinehydrochloride, thiamine-mononitraat, riboflavine, pteroylmonoglutaminezuur, d-biotine, cyanocobalamine)
chocolade: idem maar smaakstof (4% ontvette cacaopoeder en chocolade-aroma)

bewaarvoorschrift
droog en afgesloten bewaren bij kamertemperatuur (15-22°C). 
buiten bereik van jonge kinderen houden

bijwerkingen en contra-indicaties
geen bijwerkingen bekend

allergenen informatie
bevat kippenei en soja-lecithine
bevat geen bekende allergenen (tarwe, gluten, soja, lupine, pinda's , noten, selderij, mosterd, sesam, koemelk, ei, vis, schaal-, schelp- of weekdieren)

vegetariërs/veganisten
bevat ei
wel geschikt voor vegetariërs

Based upon the link you gave I am not sure which solution to pick and or how to implement them. Any tip is welcome.

So you just go to the template editor, and add this to the end of the product template that you are using (or create a new post.tpl file):


But do mind to change this: "function printdiv(printdivname)" to "function printdiv(content-extra_tab_1)", basically the css class from your preferred block.

So you just go to the template editor, and add this to the end of the product template that you are using (or create a new post.tpl file):


But do mind to change this: "function printdiv(printdivname)" to "function printdiv(content-extra_tab_1)", basically the css class from your preferred block.

Try

Print

Try

Print

Oh, forgot to name the button.... D:

Maybe all this somehow can be used for tweak and send invoice editor?

Guys many thanks this is exactly what I was looking for.

Now up to me to style the printed document with CSS so that it looks also nice on paper when you print it.

Any idea how cope with the styling, adding some CSS style element so that the text does align in the center of the page.

Guys many thanks this is exactly what I was looking for.

Now up to me to style the printed document with CSS so that it looks also nice on paper when you print it.

Any idea how cope with the styling, adding some CSS style element so that the text does align in the center of the page.

Well, you could use this"

@media print {
   (your tab's class) {
       text-align: center;
   }
}

Well, you could use this"

@media print {
   (your tab's class) {
       text-align: center;
   }
}

What goes in between (your tab's class)

I must be missing something here.

What goes in between (your tab's class)

I must be missing something here.

@media print {
   .content-extra_tab_1 {
       text-align: center;
   }
   // Or this
   #content-extra_tab_1 {
       text-align: center;
   }

}