Support Forum

Advanced Search
Forum Scope


Match



Forum Options



Minimum search word length is 3 characters - maximum search word length is 84 characters
general-topic
print a post
Avatar
AM
Member
Free Members
sp_UserOfflineSmall Offline
Jun 6, 2012 - 12:56 pm

Hi,

Is there some setting that will print only a post and not all the icons and profile pic etc. on the left of the post?

 

Thanks 🙂

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Jun 6, 2012 - 8:26 pm

afraid not... the current print post capability prints the stuff on left and right...  you could highlight the text and print the selected area, but understand thats a bit more work...

if you really want to change it, I could give you a code change for this, but afraid currently it would be a core code change...

Avatar
AM
Member
Free Members
sp_UserOfflineSmall Offline
Jun 7, 2012 - 12:09 am

Hi, 

Yes. Can you please give me the code change.

 

Thanks

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Jun 7, 2012 - 12:31 am

edit simple-press/forum/content/sp-topic-view-functions.php...  find routine sp_PostIndexPrint()... and then this line of code:

    $out.= "onclick='jQuery(document).ready(function() { jQuery(\"#post".$spThisPost->post_id."\").jqprint({debug:true}); return false; });'>";

and change it to

    $out.= "onclick='jQuery(document).ready(function() { jQuery(\"#spPostIndexContent".$spThisPost->post_id."\").jqprint({debug:true}); return false; });'>";

which should do it... but I have not actually tested it...

Avatar
AM
Member
Free Members
sp_UserOfflineSmall Offline
Jun 10, 2012 - 12:57 pm

Hey there,

Thanks for the code snippet. It did work - but I opted for a CSS-based solution which does not rely on changing the core code. This way the fix sticks through upgrades.

Let me know if you want details about how I solved it and I'll post a write-up.

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Jun 10, 2012 - 3:07 pm

Now that you mention it, fairly straight forward to do with css (or a print css file) now that you mention it... nice thought!

we are actually discussing whether we want to change the core functionality to only print the content too...

Forum Timezone: Europe/Stockholm
Most Users Ever Online: 1170
Currently Online:
Guest(s) 1
Currently Browsing this Page:
1 Guest(s)
Top Posters:
Mr Papa: 19448
Ike: 2086
Brandon: 864
kvr28: 804
jim: 650
FidoSysop: 577
Conrad_Farlow: 531
fiddlerman: 358
Stefano Prete: 325
Member Stats:
Guest Posters: 620
Members: 17365
Moderators: 0
Admins: 4
Forum Stats:
Groups: 7
Forums: 17
Topics: 10128
Posts: 79626