SitePoint Sponsor

User Tag List

Results 1 to 7 of 7
  1. #1
    SitePoint Zealot
    Join Date
    Jun 2004
    Location
    Belgium
    Posts
    133
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Question cross-browser problem with php

    When trying to perform a site action (written in PHP) there is something wrong when it involves update queries and is done by Firefox.
    In IE it always works perfect as it is intended.
    I have tried (almost) everything and don't know anymore...

    In my update log for mysql I get the following when approving an art in IE:
    # Time: 050320 15:18:34
    # User@Host: root[root] @ localhost [127.0.0.1]
    UPDATE site_articles SET `approved`=0 WHERE `id`=762;

    When I do exactly the same in Firefox:
    # Time: 050320 15:15:03
    # User@Host: root[root] @ localhost [127.0.0.1]
    UPDATE site_articles SET `approved`=0 WHERE `id`=762;
    # Time: 050320 15:15:04
    # User@Host: root[root] @ localhost [127.0.0.1]
    UPDATE site_articles SET `approved`=1 WHERE `id`=762;

    I have written out all kinds of stuff, and apparently after the update in FF all is perfectly updated, but when the script ends, the inverse query (as you see in the log) is executed. So when I look at the table again, nothing is changed.

    Does anyone have any clue on this??
    Last edited by Tomba; Mar 20, 2005 at 11:08.

  2. #2
    SitePoint Guru
    Join Date
    Nov 2004
    Location
    Parry Sound, ON
    Posts
    725
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    By "my admin" do you mean phpMyAdmin or something else?

  3. #3
    SitePoint Zealot
    Join Date
    Jun 2004
    Location
    Belgium
    Posts
    133
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    just something else

    it shouldn't really matter, I really don't understand how server side scripting can be depending on the browser type

  4. #4
    Mlle. Ledoyen silver trophy seanf's Avatar
    Join Date
    Jan 2001
    Location
    UK
    Posts
    7,168
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Moved to a more appropriate forum. See Where should I post my thread? for details

    Sean
    Harry Potter

    -- You lived inside my world so softly
    -- Protected only by the kindness of your nature

  5. #5
    SitePoint Guru
    Join Date
    Nov 2004
    Location
    Parry Sound, ON
    Posts
    725
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Why not? The browsers could handle all kinds of things differently, from how they handle empty action attributes to how they handle redirects to how they handle javascripts.

    Need to see some code.

  6. #6
    SitePoint Enthusiast
    Join Date
    Mar 2005
    Posts
    82
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    echo $query;

    copy -- paste the query on phpMyAdmin and check the result.

  7. #7
    SitePoint Enthusiast
    Join Date
    Mar 2005
    Posts
    82
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    cross-browser issue could be occur if involve javascript / css or something else (such as xml).


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •