I don't think your example is a valid url - it should actually be:

example.com/?foo=bar#myanchor

though I see how setting up links like that would be useful in some flash
apps.

I'm not really sure what would be the best way to handle that - obviously
nobody cares so far that we leave the ? and # included in the return value,
or we'd have seen more complaints/requests about it :) so maybe we should
just leave it how it is?





On Tue, Jan 13, 2009 at 4:08 PM, Aran Rhee <[email protected]> wrote:

>  Fine by me (I think – 90% sure).
>
>
>
>
>
> I was just wondering if we wanted some special handling for the anchor tag.
>
>
>
>
> #mydeeplink could some through to the swf as: anchor="mydeeplink" by
> checking if the 1st char of the querysting is a "#" and then replacing
> with a "anchor=".
>
>
>
>
>
> A user could also write their own js function to do this, but NOT if we
> remove the # from the querystring automatically. If we change the address
> of:
>
>
>
> some.html#mydeeplink?var1=foo&var2=bar
>
>
>
> To the  value of "mydeeplink&var1=foo&var2=bar" from a call to
> getQueryParamValue() then there is no chance to manipulate the querystring
> anchor unless we somehow knew all of the anchor names we were using in the
> page / app (unlikely / messy).
>
>
>
>
>
> Thoughts?
>
>
>
> Aran
>
>
>
>
>
>
>
>
>
>
>
> *From:* [email protected] [mailto:[email protected]] *On
> Behalf Of *Geoff Stearns
> *Sent:* Wednesday, 14 January 2009 10:31 AM
> *To:* [email protected]
>
> *Subject:* Re: New Query String / FlashVars method -- gathers *all* query
> string pairs with single method
>
>
>
> Ok lets chop them off.
>
> As for non-name/value pairs, I'm not sure how those could be more properly
> handled - If you were using a server side script to gather them, they would
> show as existing, but not having a value, so I think leaving them set, but
> with an undefined value is the proper thing to do, and let the user sort it
> out in their swf/javascript.
>
>
>  On Tue, Jan 13, 2009 at 3:15 PM, Aran Rhee <[email protected]> wrote:
>
>
> Parsing ? and #:
>
> The swf does not parse out the ? or #, as can be seen in the test page:
>
>
> http://www.misterhee.com/tests/params/params.flashvars.test2.html?var1=test&;
> abc=123<http://www.misterhee.com/tests/params/params.flashvars.test2.html?var1=test&abc=123>
>
>
> http://www.misterhee.com/tests/params/params.flashvars.test2.html#adef-name-
> A
>
>
> I am unsure what you guys want to do about the anchor link. Do we really
> even want that coming through? As an anchor does not have an associated
> value (rather the anchor name IS the value), I am unsure as to the
> usefulness of having it available. Basically you will have an undefined var
> called whatever your anchor was named...
>
>
> Combining data:
>
> As Bobby rightly says, you can combine the flashvars in the params object
> and variables in the flashvars object AND variables from the swf
> querystring
> without overwriting!
>
>
> http://www.misterhee.com/tests/params/params.flashvars.test3.html?var1=test&;
> abc=123<http://www.misterhee.com/tests/params/params.flashvars.test3.html?var1=test&abc=123>
>
>
> Cheers,
>
> Aran
>
> -----Original Message-----
> From: [email protected] [mailto:[email protected]] On
>
> Behalf Of Bobby
> Sent: Wednesday, 14 January 2009 7:56 AM
> To: SWFObject
> Subject: Re: New Query String / FlashVars method -- gathers *all* query
> string pairs with single method
>
>   I think we should get rid of the ? and # anyway.
>
> Although unusual, the flashvars object and the params flashvars
> notation can be mixed and matched, this is the code we currently have
> in place:
>
>                                        var par = {};
>                                        if (parObj && typeof parObj
> === OBJECT) {
>                                                for (var j in parObj)
> {
>                                                        par[j] = parObj
> [j];
>                                                }
>                                        }
>                                        if (flashvarsObj && typeof
> flashvarsObj === OBJECT) {
>                                                for (var k in
> flashvarsObj) {
>                                                        if (typeof
> par.flashvars != UNDEF) {
>
> par.flashvars += "&" + k + "=" + flashvarsObj[k];
>                                                        }
>                                                        else {
>
> par.flashvars = k + "=" + flashvarsObj[k];
>                                                        }
>                                                }
>                                        }
>
>
>
>
>
>
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"SWFObject" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/swfobject?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to