Solved

Does Facebook cache server-side files in Facebok apps?

Posted on 2012-03-13
5
596 Views
Last Modified: 2012-06-21
We've fixed a bug in the registration process in our our FB app and it's working fine and we can see that people can register.

But why do we still get SOME complaints from other users that they can’t register? Is this due to Facebook caching our old server-side files
0
Comment
Question by:melwong
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 6

Expert Comment

by:Mike D
ID: 37719190
Hi Mel,

yes, Facebook caches server side files: images, js and CSS files are often the culprits. One way to ensure the latest version is in their cache is to add a query string to the files you want updated, ie. change

...src=my_script.js...
to
...src=my_script.js?x=123...

This technique is called 'cache-busting' and is often necessary during development.  If you're using a scripting language you can add some random string (like time() in php) to the query like
<?
$cache_bust = time();
?>
...src=my_script.js?x=<?= $cache_buster ?>
This way you can easily switch it off when everything is ok.

Another thing to check is it might be a browser issue.
And last, did you set up everything for https?

Hope this helps

JD
0
 

Author Comment

by:melwong
ID: 37719321
actually I'm referring to server side files like PHP, or htaccess. Images, Css are client side
0
 
LVL 6

Expert Comment

by:Mike D
ID: 37721474
Images, css are client side
I think you're mixing something up there...
And if anyone can access your htaccess file from the web you have a real big security problem!

You have to supply more information if you seriously want a solution:
How does the registration process work?
What does it mean when a user says he can't register?
Any error message?
What type of browser is he using?
A link to your app would make sense...

JD
0
 

Author Comment

by:melwong
ID: 37722777
Sorry, I'm referring to PHP files.
0
 
LVL 6

Accepted Solution

by:
Mike D earned 150 total points
ID: 37723805
Then the answer is 'no', facebook does not cache your php files.

JD
0

Featured Post

Free learning courses: Active Directory Deep Dive

Get a firm grasp on your IT environment when you learn Active Directory best practices with Veeam! Watch all, or choose any amount, of this three-part webinar series to improve your skills. From the basics to virtualization and backup, we got you covered.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this article, you will learn how to create custom audiences using your own email lists. You can use this custom audience as your target audience for advertising on Facebook. This allows you to advertise to your existing audience. Once you've crea…
Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
The viewer will learn how to count occurrences of each item in an array.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.

749 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question