<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>5475</bug_id>
          
          <creation_ts>2005-10-24 04:07:53 -0700</creation_ts>
          <short_desc>Relative URLs from Flash do not work if they start with a ? (variable string)</short_desc>
          <delta_ts>2006-03-13 05:35:45 -0800</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>Plug-ins</component>
          <version>417.x</version>
          <rep_platform>Mac</rep_platform>
          <op_sys>OS X 10.4</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>DUPLICATE</resolution>
          <dup_id>7656</dup_id>
          
          <bug_file_loc>http://www.ryanair.com/site/EN/dests.php?flash=chk</bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>0</everconfirmed>
          <reporter name="Peter Gerard">peter</reporter>
          <assigned_to name="Tim Omernick">timo</assigned_to>
          <cc>ap</cc>
    
    <cc>bugs-webkit</cc>
    
    <cc>peter</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>22808</commentid>
    <comment_count>0</comment_count>
    <who name="Peter Gerard">peter</who>
    <bug_when>2005-10-24 04:07:53 -0700</bug_when>
    <thetext>I have reported this bug using the &quot;Report bugs to Apple&quot; feature in Safari on every version of Safari 
since Jaguar. The bug exists in all versions of Safari, including the latest 1.3 and 2.0 on Panther and 
Tiger.

If a Flash file requests an address (using getURL or a similar function) and the address is a relative one 
like &apos;?flash=yes&apos; then Safari incorrectly appends &apos;?flash=yes&apos; to the existing URL instead of replacing the 
variable string in the existing URL. This happens whenever the address requested by Flash begins with 
a &apos;?&apos;.

For example, on the popular Ryanair website when a user tries to view the destination map:
http://www.ryanair.com/site/EN/dests.php?flash=chk
the embedded Flash file then redirects to &apos;?flash=yes&apos; but Safari sends the browser to:
http://www.ryanair.com/site/EN/dests.php?flash=chk?flash=yes
instead of the correct page:
http://www.ryanair.com/site/EN/dests.php?flash=yes

This bug also affects loadVars and any other attempt to request an external URL in Flash.  On one of my 
own websites I found that I could work around the problem by doing a browser check and a redirect so 
that the repeated variable string would not cause problems. Look at:
http://www.myedinburgh.org/?area=map 
which redirects to: 
http://www.myedinburgh.org/?area=map&amp;map_flash_saf_init=1
so it will work on Safari.
View Safari&apos;s Activity window to see how this solves the problems. The call to a variables file at:
http://www.myedinburgh.org/?area=map&amp;map_flash_saf_init=1?
area=map&amp;section=flashdata&amp;getdata=init
now works because the value for &apos;area&apos; is &apos;map&apos; instead of &apos;map?&apos; as it would have been without the 
addition of &amp;map_flash_saf_init=1. The variable &apos;map_flash_saf_init&apos; is not actually needed (it&apos;s only 
there to fix the Safari bug) so the extra &apos;?area=map&apos; stuck on the end doesn&apos;t mess anything up.

On other sites I have had to recode Flash files to make them work with Safari because this redirection 
workaround was not applicable.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>31748</commentid>
    <comment_count>1</comment_count>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2006-02-07 12:41:41 -0800</bug_when>
    <thetext>I have tried to reproduce the problem on ryanair.com, but it appears to behave correctly. Could you please provide a step-by-step description of the steps necessary to reproduce the problem?

I am using Flash Player 8.0 r22.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>32398</commentid>
    <comment_count>2</comment_count>
    <who name="Joost de Valk (AlthA)">joost</who>
    <bug_when>2006-02-13 16:10:06 -0800</bug_when>
    <thetext>Can&apos;t reproduce either, closing bug as worksforme. Reporter, if this still doesn&apos;t work, please reopen and tell us what you do.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>35529</commentid>
    <comment_count>3</comment_count>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2006-03-08 08:22:43 -0800</bug_when>
    <thetext>Ok, bug 7656 has a reproducible test case for this issue (and, subsequently, a proposed fix).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>36094</commentid>
    <comment_count>4</comment_count>
    <who name="Peter Gerard">peter</who>
    <bug_when>2006-03-13 02:29:23 -0800</bug_when>
    <thetext>I can confirm that the bug is still reproduceible (as of OS 10.4.5 - Safari 2.0.3 (417.8)). Ryanair may have developed a work-around in the time since I posted the bug. However, you can reproduce it by following these steps:

Visit:
http://www.myedinburgh.org/?area=map&amp;map_flash_saf_init=1

View the Activity Window.
Notice that the Flash movie has loaded variables from the following address:
?area=map&amp;section=flashdata&amp;getdata=directory

However, this shows in the Activity window as:
http://www.myedinburgh.org/?area=map&amp;map_flash_saf_init=1?area=map&amp;section=flashdata&amp;getdata=directory

This is incorrect. The correct behavior would be for Safari to load:
http://www.myedinburgh.org/?area=map&amp;section=flashdata&amp;getdata=directory

Instead Safari has appended the relative address to the entire existing URL, which causes some variables to not work.

You will not notice any problems on the page because I have added a Safari-specific workaround in the PHP that allows this incorrect URL to still work. However, the bug still persists and probably affects other websites.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>36101</commentid>
    <comment_count>5</comment_count>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2006-03-13 05:35:45 -0800</bug_when>
    <thetext>Thank you for providing these updated steps to reproduce! I can now see the problem with Safari 2.0.3 (10.4.5).

As expected, this appears to be fixed in the latest nightlies, with bug 7656 being resolved. Nightly builds of WebKit are available from &lt;http://nightly.webkit.org&gt;.

*** This bug has been marked as a duplicate of 7656 ***</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>