Skip to:

Okay – £10 to whoever can think of a solution

  • rossagrant


    This is a total mystery to me guys and if you’re anything like me, when something is niggling – you need to beat it out of principle!

    I have a production site and a staging site both on the same server more or less mirroring each other in setup.

    They run the same theme, the same plugins and as far as I know are set up the same.

    I put a ticket on TRAC earlier this week as the activity stream ajax sorting dropdowns on staging weren’t working on my iPhone – they work just fine on desktop.

    I’d tried deactivating every plugin except for BP and at the same time using BP-Default.

    The dropdowns still didn’t work, so I thought it must be a bug in BP.

    I’ve since ported the theme I’ve been working on from staging to production and updated BP to the latest version (which staging has been running) and expected the dropdowns to still not work.

    To my surprise they work just fine on iPhone on my production site now.

    Now I need to figure out what the heck could possibly be happening so that they work on one site and not on the other even though they run the same theme, the same plugins, and are setup the same.

    It’s just incredibly bizarre.

    Things I have tried so far:

    – Deactivating all plugins except BP.
    – Switching to BP-Default.
    – Copying the BP plugin folder from production to staging to ensure all files are the same.
    – Checked as many obvious settings as possible to ensure they are set the same on both sites.

    Does anyone have ANY ideas of what else I could check that would be affecting these sorters???

    It’s so weird!!!

Viewing 15 replies - 1 through 15 (of 15 total)

  • rossagrant


    It’s not just the dropdowns that don’t work by the way – ajax just in general doesn’t.

    The ‘Load More’ button at the bottom of the activity stream does nothing on iPhone either and the sorters in the Members Directory don;t work either.



    Hi @rossagrant,

    can you make a test with the trunk version ?

    Many details have been modified around the load more area.
    Are you aware that bp-default is no more included in BuddyPress ? (yes, probably 😉 )
    The future of the bp-default theme
    I’m affraid that compatibility issues have not the priority for the moment, bp-default is a few step away to be added to the theme repo and BP itself is in a cleaning stage from this theme.

    FYI, see also these tickets

    Both sites are on the same server with the same settings. But do they use the same DB ?
    Have you tried to activate/deactivite the load more option in BP’s settings ? Maybe mobile devices don’t support a 5 mn latency ? Or some weird cookie issue ?

    James Golovich


    Some weird cross domain AJAX problem?



    @danbp Thanks for a comprehensive answer Dan!

    The sites run on the same server, but they don’t share the same database.

    I’ve been into mySQL and each DB has the same tables set up – nothing looks odd or anything.

    In terms of turning the option for BP’s activity button on and off – do you mean the auto-refresh option?

    I’ve tried that to no effect.

    With regards to BP-Default – I’ll certainly help test this – but for my issue, the fact the theme works on one install and not the other, would suggest that the theme isn’t an issue.

    I’m going to keep looking through each site’s settings and see what the score is with any differences.

    It’s such a mystery – and even more of a mystery that only iPhone/ iPads are affected on just one of the installs!

    Thanks again for your help so far!

    Ross 🙂



    i don’t use iphone so i cannot help for this.
    But if you use two different DB, it could be possible that they have not the same version # or the same table type (myisam vs. innodb for ex.). Such details can explain why you get some behaviour issue with apparently the same settings…
    Are you on a VPS, dedicated or on a shared host ? Because 2 sites on the same host are not obligatory on the same server.

    That said, it’s not an allergy against iphones who can be generated by this trouble. 😉
    Have you js errors somewhere (check this in a desktop PC) or an unupdated browser in your mobile ?
    Have you tried with an android or a smartphone ?



    Hi Dan, I’m on a dedicated sever so the sites are hosted in the exact same environment.

    I’ll take a look JS errors now!



    @danbp I’m getting no JS errors at all. Still totally bonkers.



    @danbp Hey Dan,

    Took me til 2AM this morning to work this out but got there in the end – whether it was to do with my WP setup or something that wp-admin/ajax.php is doing though I’m not sure.

    I eventually found out how to debug on my iPhone and I when using any ajax on my staging site, I was given this kind of error:

    ‘XMLHttpRequest cannot load

    Origin is not allowed by Access-Control-Allow-Origin.’

    So it was to do with a mix of www. and non www. prefixes.

    To allow this kind of cross site scripting securely you can add this to your htaccess file:

    Header set Access-Control-Allow-Origin

    And everything works just fine.

    Any ideas if this would be caused by my initial WP install – even though from what I can tell it’s set to www.

    My live site doesn’t have any issues – so maybe it just was my staging site’s setup.

    Anyway, wanted to let you have a look incase anyone else has this issue in the future.

    Ross 🙂

    Ah hah, interesting. @rossagrant:

    If you go to wp-admin > Settings > General, what are the values for the “WordPress Address (URL)” and “Site Address (URL)” fields?

    It looks like your site is making its “load more” request to, but the site is intended to be accessible at Is that correct?

    Do you have any plugins or unusual server config that are redirecting from www to no-www?



    @djpaul Hey Paul – not spoken to you in ages – hope you’re well mate!

    Right I’ve just had a look in WP settings and indeed the URL’s were set to www.

    I have a very blurry recollection that I very well might have added those http://www.’s years back after my staging site was created by Boris.

    Deleting the www. from both URL fields AND THEN REMOVING that Htaccess fix above still keep ajax working which is great!

    It’s something I have never ever looked into before, but what would be hardcoded into my install to cause this mix up where it is expecting no www. but getting one.

    Obviously I know where the www. came from – it was in those 2 general settings field, but where in the install was WP picking up that it was expecting no www. – and why would that only affect iPhone.

    I’m just trying to figure out where that no www. stuff that WP was expecting is kept.

    It’s bloody confusing for a simpleton like myself! Haha!

    What ultimately determines what WP expects to see? The ajax was expecting a no www.

    Thanks in advance.

    Hard to know without poking about the server.



    @djpaul Ahh okay, cheers Paul.

    Well I’ve ran the Go live URL WP plugin to change all references in the DB from www. to no www. (there were only a few) and it’s all good.

    I guess the site was originally set up as no www. and I ended up editing the WP settings in the general panel to have www. – screwed it up.

    We’re all good now though!

    Glad to hear it 🙂



    I have the same issue.
    Would like to find out the solution 😀

    @chester99 the solution to this distinct & particular issue for the OP is mentioned.

    Please start a new thread detailing your particular circumstances, setup, issues etc.

    closing this thread as it was resolved.

Viewing 15 replies - 1 through 15 (of 15 total)
  • The topic ‘Okay – £10 to whoever can think of a solution’ is closed to new replies.
Skip to toolbar