iPad: PDF in UIWebView has sometimes a blank first page (why and how to solve?) - xcode

My app for the iPad shows PDF-files by using a UIWebView. But sometimes when I click on several pdfs in a row, the first page of a pdf is blank suddenly. When I reopen the same pdf a second time, the first page is normal again. This happens from time to time and is not just linked to a specific pdf file.
Any ideas or did you had similar issues? Solutions? :/
Thanks in advance!!

Without seeing neither code, nor the PDFS, I would bet for a memory related issue, since you say this happens when showing several PDFs in a row. Indeed, UIWebView is highly optimized as to memory usage and keeps in memory only relevant parts of the page, so it could be that somehow your first page is unloaded.
You can check if this is the case by adding some NSLog traces to didReceiveMemoryWarning in your app delegate. If you see the trace logged just before the blank page issue appears, then this would be a hint that it might be a memory problem.
If my hypothesis is right, then a fix would be forcing the web page to refresh its content. Or you might try a workaround just to make this particular use case (quickly moving through multiple PDFs documents in a row) work. In both cases, I would need more detail to suggest any possible implementation.

Related

Product images are getting overlapped after clearing the cache and refreshing

I have a single problem on my Shopify store website. Well, basically the title says it all - the product images are getting overlapped after clearing the cache and refreshing. But, load just fine after a second refresh. I know this is a broad question, but I digged into the problem and was unable to find a single thing wrong with the CSS. I just want to know, how is clearing the cache related to how the images will load? You think there is something wrong with the CSS, or JS, or even HTML? Any ideas? I am very desperate, any leads will be greatly appreciated. I don't even know where to look, I am just really stuck at this point. I can provide every detail that will make it easier to look for the issue. I just don't know what to provide for now.
How they should be
How they appear

Cannot open a link in new tab

I am trying to fix this problem, can anyone suggest me what is occurring this ?
http://ls3b.ch/
This website is build in wordpress, there are some links here which opens in the same page but opening in the new tab will return only these contents, http://ls3b.ch/work/mr16-gu5-3/
Before I answer the question, I noticed that your hierarchy is a bit out, if your using custom post types, you will probably need to do some rewrites to fix that up so your SEO isn't effected too much.
As for your problem about the links, I clicked on every link I could find and couldn't get to the page you linked to as being the problem. It might just be stored in your cache and needing to be cleared.

Website with a very slow load time on every page

http://www.puppykisses.org/
i made a WordPress page for a client, and for some reason it is taking over a minute to load the page. The only thing that I could think of being the problem is the amount of photos that he inserted into the slider up top on the home page. It looks like all those pictures need to load before anything else pops up. But then I click on Contact or any other page that has no real images to speak of, and the problem is still there. Just wondering if anyone can point me in the right direction to fix this. thanks!
Like #David said, its the initial request (the source for the page) that is giving you the issues. This means it is unlikely an issue with hosting, and most likely an issue with your code. I would go through any plugins you have installed and disable them one-by-one, and slowly start commenting out your own custom dynamic code bit by bit, till you see what is taking so incredibly long. Then rewrite/excise that code from the site.
Start With the Basics
Keep the number of WordPress plugins you use to a minimum
Get a Proper Hosting Provider
Remove Unnecessary Code From WordPress Header -> http://goo.gl/yfRcF
Use firebug and click Network tab to check loading speed for each files
Check Suggestion how to improve website speed -> http://goo.gl/FtiX3
Install WP Super Cache plugin -> http://wordpress.org/extend/plugins/wp-super-cache/
*If you use gallery try to use image thumbnail rather than load whole images size

Moving from Flash to HTML5/CSS/ etc

Some years ago I decided I could bypass all the browser inconsistencies by producing sites entirely in Flash. Doesn't look such a good decision now so I'm re-writing my semi-CMS framework in php, javascript/jQuery and HTML. One aspect of my Flash sites which I am very pleased with is the ability to load all pages or states in the background so the user rarely requests a page that isn't already loaded. When that does happen I can display a progress bar. In AJAX I can't display progress but I also found a significant difference I hadn't anticipated. In Flash I load the .swf for page 1 completely, before starting to load page 2. That means everything including images etc. In AJAX I can't see a way to do that. I can check that the HTML file itself has completed loading, but not that all its images have loaded before loading the next HTML file. Is it possible?
If you're looking for an HTML5 solution rather than just an AJAX solution you might want to investigate the Application Cache. There is a progress event which you could hook into, though it possibly doesn't get into the level of detail you need. As far as I'm aware, resources will start downloading in the order they're listed in the manifest file.

Firefox wont load this page but other browsers will, why?

This is driving me crazy. This website and its pages work perfectly in IE, and Chrome but in Firefox 5.0 it frequently won't load the belts and bags page and the only way to get it to load is clear my cache/history.
http://www.urlgone.com/0ad9a6/
If you click around four times on the Bags link, then the belts link, then the Bags, then the accessories link it usually won't load. Another testing process is when you click Belts or Bags twice each then hit refresh it gets stuck and never loads or eventually after a long wait does. It seems to do this on either Belts or Bags but its
not always the same page that has problems.
Can anyone give me a clue what the problem is?
I figured the problem out. Its more specific to my individual situation i guess. I thought maybe my problem was the word press include header file but I was wrong. It appears to be permalinks. I changed my perma links to default and it worked. Next I did a restart with Firefox in Safe Mode using pretty permalinks (not default) and it worked fine. So ultimately the problem in Firefox is an add-ons in combination with the permalink somehow. I found the culprit add-on is HTML Validator 0.9.0.6. I'm not sure why this is the problem but appears it is.

Resources