Closed orangedrink closed 11 years ago
Lots of people are using these design properties, so any problems are likely to be browser cache or setup issues. You do have to have the advanced site property for the new reader enabled, of course.
It's also important to test any overrides on staging as it has browser caching turned off. The live site requires refreshing (and sometimes a cache flush) for many changes to propagate -- one reason the live layouts are considerably faster.
You should target any new reader deployment at the Reader Beta. It's already in production on several sites, and is where all reader new work is being directed. It will become the standard reader at some point this fall.
I don't know what you want to accomplish with page size, but the global page layout is determined by a lot of elements, CSS styles, and javascripts; bug fixes and adjustments have required structural changes in the past, even when attempting to support the same rendering. You can try to change this, but it will probably be painful, and we will attempt to ensure that bug fixes or feature improvements will not break changes this area.
If there's a bug or usability issue in the global layout or sizing please let us know so we can fix it -- one reason for the reader is that we saw that a standardized solution offered a better way to get user experience optimizations in place for all our customers. Within that goal of a standardized reading platform, we are gradually opening up the reader to more customization, but we can't have an evolving standard and maintain compatibility with arbitrary style changes that people might make to the presentation.
With all that said, here are some ....
We do not attempt to guarantee that layout-affecting CSS will not have to change, except for the options explicitly supported by documented design parameters or affecting contents of the header and help regions, at their current sizes. Classes with t-
prefixes can be safely adjusted as to rendering (color, background, etc).
If you do try adjusting the page layout outside the header or the content of the help bar, you need to proceed with caution. You should not attempt to adjust the layout div.t-content element or any of it's contents. That part of the reader includes link overlays, will support annotations soon, and has been very tricky to get right.
We have switched to using design parameters to select site-markup variations. This has a lot of deployment advantages (ability to use staging to test new versions, etc.). There will be limit on the lifetime of old reader version support, so for sites whose CSS you will not want to revisit, it's best to avoid any risky customizations.
The t-reader
id on the reader body tag makes override CSS much easier as rules starting with #t-reader
gain CSS priority over rules that do not have it. We use this to make jquery overrides a (little) safer. The same capability is now supported in regular tizra pages with the id my
. Tizra CSS will never use #my
in system generated CSS, so you can use #my
in CSS rules to implement overrides.
You may well have to change the CSS at some point, but it is possible to change the size of the header area, and to change the button icons in the toolbar. The JQuery mobile HTML classes and markup have changed a lot between versions, and are slated to change radically again in the next version (already in alpha). We strongly recommend leaving these as-is, or making minimal adjustments; if you do, expect that those stylesheets will have to change.
Trying to adjust the layout of the search buttons, etc. is likely to be a thankless task that is sure to recur in the future.
If you change z-index values anywhere on the page, you will likely break things, including particularly the fallback support for IE 7-9.
You do have to have the advanced site property for the new reader enabled, of course.
I don't see this option in advanced site properties for this site (http://aarp54390.tizrapublisher.com/) If I were able to just disable the mobile reader that would solve my problem too.
The mobile versions are pretty much not customizable, actually. (Sorry for giving all the information on the other reader when that's not relevant).
We can enable the site setting for the new reader, but it does not seem like that will help.
There is an exit button on the mobile reader that will go to the default page display. Without a description of exactly what you want to accomplish, I can't really fix the problem, or suggest an action. I can think of some possible solutions, but I need to be sure that I'm solving the right problem.
For the AARP site we are using an iframe (as you recommended) to show the contents of the tizra site alongside the header and footer pulled from AARP via server side includes. http://aarp.omnibooksonline.com
To make this seamless we are using javascript to pass the height of the body from the tizra site to the parent iframe and then resizing the iframe appropriately. This works pretty well unless the tizra site inside the iframe is using the mobile reader. In which case the bottom of the page is being cut off. I'm guessing that this is due to a float:left being applied to div#viewer but I'm having trouble introducing any code to this page in order to troubleshoot.
I'm pretty sure if I set a height that my javascript can calculate this will solve the problem. Disabling the mobile reader would work too but using the useBetaReader property doesn't seem to have any affect.
You're right that the beta properties don't affect things. Sorry about wasting your time on that.
There's no real way to find the size of content within an iFrame (unless they are served from the same domain).
You should be able to turn off the mobile version by setting a session cookie
param-expanded
to the value false
Maybe that will help to ensure that there is only one page size to measure.
That would be the easiest solution but it doesn't seem to be working:
I can't tell from that screenshot if you reloaded the iframe after setting that cookie. You have to have the cookie set before the browser parses the iFrame (or you set its source).
It took me a while, since I don't want to edit your page code, but I was able to execute
document.cookie="param-expanded=false"
within the right rendering context (the tizrapublisher site), and once that was done, the reader stayed out of the mobile mode. As long as the script is executed by the agilepublisher domain before the user navigates to a reader page, they should be OK. You need to make sure it's on the agilepublisher page, and it may work differently on staging and live.
At least on some of the pages, I was not able to get to your setCookie function, but the raw javascript worked ok... It's actually hard to set the cookies manually in Chrome because they don't give you a nice function for it.
Once you confirm that you've got this working automatically on your site, I'll close this.
Thanks a lot for helping me work through this. Maybe a video will show what's going wrong here.
Hmmm.... That's exactly what I was doing, but I did not get the mobile version, but your customized pages.
I'm going to try some changes on staging to remove some more variables.
Oops.. didn't see this and published to live..
Let me know what you find out. Thanks again for the help.
OK, I'd managed to mess up somehow in the testing. You're going to actually have to set the preference to say that you don't want the mobile, and redirect to the home page...
The URL will look like this:
http://aarp54390.tizrapublisher.com/site/preferences?operationId=edit&saveCookie=true&fieldName=expanded&fieldValue=false&redirectTarget=/
That's certainly kind of horrible, but it actually works. Sorry for leading you down the primrose path -- this stuff is obscure enough that I just got it wrong a couple of times...
Closing, will re-open if there are problems.
That's not too horrible. Most importantly it's working. Thanks David.
https://github.com/Tizra/Tizra-Customer-Tracker/wiki/Customizing-New-Reader
I'm looking at the wiki but adding the properties described there doesn't work. Is there anything I can do to set a height to the page when the new reader is being used?