Hi all
Having trouble getting the printer friendly feature to work.
Here is the parse file for the printer friendly version:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title><MySource_PRINT id_name="global" var="site_name" /> - <MySource_PRINT
id_name="global" var="asset_name" /></title>
</head>
<body>WTF THIS ISNT WORKING
<img src="http://matrix.nsw.uca.org.au/__data/assets/image/5533/header-bg.gif">
<BR><BR>
<h3><MySource_PRINT id_name="global" var="site_name" /> - <MySource_PRINT
id_name="global" var="asset_name" /></h3>
<MySource_AREA id_name="body" design_area="body" />
</body>
</html>
And here is the design parse file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title><MySource_PRINT var="site_name" /> - <MySource_PRINT var="asset_short_name" /></title>
<link rel="stylesheet" type="text/css" href="mysource_files/style.css" />
<div id="headercontainer">
<div id="topnavbar">
<ul><li><a href="#">about</a> </li> <li><a href="#">advertise</a> </li> <li><a href="#">contacts</a> </li> <li><a href="#">sitemap</a> </li>
</ul></div>
<div id="header">
<div id="header-bg-repeat">
<div id="header-bg">
</div>
<div id="navbar">
<ul>
<MySource_AREA id_name="site_nav" design_area="menu_normal">
<MySource_SET name="level" value="top" />
<MySource_ASSET>
<li><a href="<MySource_PRINT var='asset_link' />"class="nav" title="<MySource_PRINT var="asset_short_name" />"><MySource_PRINT var="asset_short_name" /></a> </li>
</MySource_ASSET>
</MySource_AREA>
</ul></div>
<div id="container">
<div id="topad"><MySource_AREA id_name="top_ads" design_area="nest_content" /></div>
<div id="breadcrumb">
<MySource_AREA id_name="page_lineage" design_area="asset_lineage">
<MySource_SET name="levels_to_print" value="0" />
<MySource_SET name="prefix_with_home_link" value="true" />
<MySource_SET name="suffix_with_current_link" value="true" />
<MySource_SET name="prefix_with_divider" value="false" />
<MySource_SET name="suffix_with_divider" value="false" />
<MySource_SET name="show_hidden_links" value="false" />
<MySource_ASSET>
<a href="<MySource_PRINT var='asset_link' />">
<MySource_PRINT var='asset_short_name' /></a>
</MySource_ASSET>
<MySource_DIVIDER>
>
</MySource_DIVIDER>
</MySource_AREA>
</div>
<div id="leftcolumn"><MySource_AREA id_name="left_column" design_area="nest_content" /></div>
<div id="rightcolumn">
<div align="right" id="printer"><a href="<MySource_PRINT id_name="global" var="asset_link" start_query_string="true" append_query_string="true" />SQ_DESIGN_NAME=transit_printer_friendly" target="_blank">Printer Friendly Version</a></div>
<MySource_AREA id_name="right_column" design_area="nest_content" /></div>
<div id="maincontent"><MySource_AREA id_name="body" design_area="body" /></div>
</div>
<div id="botad"> <MySource_AREA id_name="bottom_ads" design_area="nest_content" /> </div>
<div id="footer">This is an initiative produced collaboratively by the <a href="http://nat.uca.org.au" target="_blank">National Assembly</a> and the <a href="http://wa.uca.org.au/" target="_blank">Synod of Western Australia</div>
<div id="privacy"><a href="terms.htm">Terms of use</a>| The Transit Lounge © 2007 | </font></span></font><span class="footertext"><a href="privacy.htm">Privacy Policy</a>
</div>
</div>
</body>
</html>
It seems to do nothing… what am I doing wrong? Please let me know if more information needed.
Also - I am wondering if we can it to open the print options box directly (you know, so you click on the printer friendly and your printer options comes up immediately, instead of having it go to a page that is 'printer friendly').
Thanks
Hey yatp,
What specifically isn't working?
Is your printer friendly design diplaying when you click on a link?
Is your header image in your printer friendly design appearing?
[quote]Hey yatp,
What specifically isn’t working?
Is your printer friendly design diplaying when you click on a link?
Is your header image in your printer friendly design appearing?
[right][post=“14289”]<{POST_SNAPBACK}>[/post][/right][/quote]
My bad. Well - as far as I can see - it does nothing.
It takes about a second and takes me to a page that looks exactly the same as if I hadn’t clicked the printer friendly version.
I am expecting a header banner and just the body text. I have a feeling it’s not linking properly or something.
[quote]My bad. Well - as far as I can see - it does nothing.
It takes about a second and takes me to a page that looks exactly the same as if I hadn’t clicked the printer friendly version.
I am expecting a header banner and just the body text. I have a feeling it’s not linking properly or something.
[right][post=“14290”]<{POST_SNAPBACK}>[/post][/right][/quote]
Here is an actual link to the page in question:
http://matrix.nsw.uca.org.au/yat/articles2/domestic/former_miss_world_engaged
Have you applied a user defined design in the setting screen of that page?
[quote]Have you applied a user defined design in the setting screen of that page?
[right][post=“14295”]<{POST_SNAPBACK}>[/post][/right][/quote]
They have a ‘system defined design’ assigned, the first one. They have a design applied to the root folder.
It is organised like this:
Articles > Domestic (There are a few article categories) > Article Name
Sounds like you need to configure the settings screen for your user defined design.
How to:
On the settings screen of the article or higher up in the tree (eg the site asset) select the setting screen.
As it appears that you have created this printer friendly design specifically for your article I recommend you use the settings screen of your article.
In the ‘Designs’ section of the settings screen use the form titled ‘Create New User Defined Design’. For the ‘Design Code’ feild type ‘transit_printer_friendly’. Then for the ‘New ?’ field use the chooser to select your printer friendly design from your asset map.
The link should then apply your design.
http://matrix.nsw.uca.org.au/yat/articles2/domestic/former_miss_world_engaged?SQ_DESIGN_NAME=transit_printer_friendly
because matrix now understands what you mean by ‘transit_printer_friendly’
[quote]Sounds like you need to configure the settings screen for your user defined design.
How to:
On the settings screen of the article or higher up in the tree (eg the site asset) select the setting screen.
As it appears that you have created this printer friendly design specifically for your article I recommend you use the settings screen of your article.
In the ‘Designs’ section of the settings screen use the form titled ‘Create New User Defined Design’. For the ‘Design Code’ feild type ‘transit_printer_friendly’. Then for the ‘New ?’ field use the chooser to select your printer friendly design from your asset map.
The link should then apply your design.
http://matrix.nsw.uca.org.au/yat/articles2/domestic/former_miss_world_engaged?SQ_DESIGN_NAME=transit_printer_friendly
because matrix now understands what you mean by ‘transit_printer_friendly’
[right][post=“14298”]<{POST_SNAPBACK}>[/post][/right][/quote]
Yeah that was it!
Very nice. HI 5
[quote]Yeah that was it!
Very nice. HI 5
[right][post=“14303”]<{POST_SNAPBACK}>[/post][/right][/quote]
There is one more thing. Is there a way to get the print option to come up immediately when you click on the printer friendly, instead of it taking you to a page that is ‘printer friendly’ and having to print it manually?
Is there a tag one can include?
[quote]There is one more thing. Is there a way to get the print option to come up immediately when you click on the printer friendly, instead of it taking you to a page that is ‘printer friendly’ and having to print it manually?
Is there a tag one can include?
[right][post=“14304”]<{POST_SNAPBACK}>[/post][/right][/quote]
There isn’t a tag, but you can do it by adding JavaScript to your Printer Friendly design. However, I don’t know exactly what that JavaScript is.
I’m sure someone does and will post here soon.
Yeah, javascript is the way to trigger a print of the page. In your printer friendly page you would put something like this in the head of your html page:
[html]<script type="text/javascript">
//<!–
// Initiate printing as soon as the page has loaded
window.onload = function() {
try {
window.print();
} catch(e) {
alert('this browser does not support the javascript print function. Please select file -> print manually');
}// End try
}// End window.onload
//–>
</script>[/html]
[quote]There isn’t a tag, but you can do it by adding JavaScript to your Printer Friendly design. However, I don’t know exactly what that JavaScript is.
I’m sure someone does and will post here soon.
[right][post=“14307”]<{POST_SNAPBACK}>[/post][/right][/quote]
Thanks.
Please post hear soon! B)
[quote]Thanks.
Please post hear soon! B)
[right][post=“14309”]<{POST_SNAPBACK}>[/post][/right][/quote]
That’s ninja! :ph34r: Ta.