Jump to content

Print Product Information


Guest

Recommended Posts

Guest degsey69

Is there a mod to add a print button to all product description pages, so it only prints whats inside the product desription box and not the whole page???????

Thats a good idea, anybody done it yet ;)

Link to comment
Share on other sites

  • 10 months later...

I see that this thread died a pretty quick death almost a year ago (maybe the original author found what he or she was looking for?)...but I have looked for over an hour and haven't found what I am looking for...so, I am going to try another plea for help...

Does anyone know what needs to be done to create a printer friendly page that only prints the {PAGE_CONTENT} element?

I have a link on my viewProd.tpl page, so I was going to create a separate page that uses a passed variable to create the printer friendly page from there...and I know just enough to be dangerous (to myself and my store). So, I am begging for help for the sake of my store :sourcerer:...

Thanks in advance for any help!

Bergii

Link to comment
Share on other sites

  • 2 weeks later...

As an update in case anyone else would like to know...

Chargin requested this mod through cubecart.org (thank you) and the response that was given is...

DRUMROLL PLEASE......

"This can be done using CSS so that you can use the browser's own print function." - Robsta

So, thank you one and all, this thread can finally be laid to rest.

Bergii

Link to comment
Share on other sites

Hi Bergii, I havent even read the .org thread, my notification emails from there never work... Ill go over and take a look soon.

but dont lay this thread to rest just yet hehe

Id like to see how this is done exactly using CSS, ie what code do we add and where?

Link to comment
Share on other sites

Hey Chagrin,

I did use the CSS like Robsta had suggested. I don't know why I didn't think of it before :)...

Here is what I did...

1. Create a new file called print.css (I actually copied layout.css and renamed it) and put it in the styleSheets directory.

2. In the styleTemplates/global/index.tpl file, within the <head> tag add the following code:

<link href="http://www.yourURL.com/sales/skins/YourSkin/styleSheets/print.css" type="text/css" rel="stylesheet" media="print">

3. In the print.css file, find any element you don't want to print (I found that the only elements I needed to keep the same were: body, #pageSurround, .colMid, and .boxContent) and delete all the attributes within the curly brackets and add the attribute:

display:none;

Leave the elements you need to print just as they are.

That was it. It took some time for me to figure this all out because I have a heavily modded store, but it work likes a charm now.

I hope this works for you too!

Bergii

Link to comment
Share on other sites

  • 2 months later...

Hey Chagrin,

I did use the CSS like Robsta had suggested. I don't know why I didn't think of it before ;)...

Here is what I did...

1. Create a new file called print.css (I actually copied layout.css and renamed it) and put it in the styleSheets directory.

2. In the styleTemplates/global/index.tpl file, within the <head> tag add the following code:

<link href="http://www.yourURL.com/sales/skins/YourSkin/styleSheets/print.css" type="text/css" rel="stylesheet" media="print">

3. In the print.css file, find any element you don't want to print (I found that the only elements I needed to keep the same were: body, #pageSurround, .colMid, and .boxContent) and delete all the attributes within the curly brackets and add the attribute:

display:none;

Leave the elements you need to print just as they are.

That was it. It took some time for me to figure this all out because I have a heavily modded store, but it work likes a charm now.

I hope this works for you too!

Bergii

Unfortenately. This does not work for me.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...