> -Original Message-
> From: Marc Guay [mailto:marc.g...@gmail.com]
> Sent: Wednesday, November 17, 2010 8:59 AM
> To: PHP General
> Subject: Re: [PHP] Updating a GET variable
>
> > Nathan previously mention what if instead of a language specific
> > request,
> Nathan previously mention what if instead of a language specific request,
> you have request for multiple languages.
I get it now, multiple _simultaneous_ languages.
Cheers,
Marc
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
> -Original Message-
> From: Marc Guay [mailto:marc.g...@gmail.com]
> Sent: Wednesday, November 17, 2010 6:30 AM
> To: PHP General
> Subject: Re: [PHP] Updating a GET variable
>
> > A bit late in the thread. However, IMO, I don't think session is
> > n
> A bit late in the thread. However, IMO, I don't think session is necessary,
> unless you intend to save it for later use, during that same visit from the
> user. If it's just a 1 time request, you can just use (example)
> $_GET['lang']=en,de,fr,...
> Then just split up individual languages, pro
> -Original Message-
> From: Nathan Rixham [mailto:nrix...@gmail.com]
> Sent: Thursday, November 11, 2010 8:18 AM
> To: Marc Guay
> Cc: Tamara Temple; PHP General
> Subject: Re: [PHP] Updating a GET variable
>
> Marc Guay wrote:
> >> So all you need to do
Marc Guay wrote:
So all you need to do, is take a look at $_SERVER['HTTP_ACCEPT_LANGUAGE'] to
get a users language preferences.
Hi Nathan,
Yep, I'm using this var to set the default but I think it's nice to
allow the user to override it. Maybe someone using their computer is
more comfortable
> So all you need to do, is take a look at $_SERVER['HTTP_ACCEPT_LANGUAGE'] to
> get a users language preferences.
Hi Nathan,
Yep, I'm using this var to set the default but I think it's nice to
allow the user to override it. Maybe someone using their computer is
more comfortable in a different l
Tamara Temple wrote:
On Nov 10, 2010, at 8:58 AM, Marc Guay wrote:
foreach($_GET as $k => $v) $qs[$k] = URLDecode($v);
$qs['lang'] = 'en';
echo 'Flip';
Hi Tamara,
Thanks for the tips. Do you see any advantage of this method over
using a small POST form besides the styling problems I'll run
On Nov 10, 2010, at 8:58 AM, Marc Guay wrote:
foreach($_GET as $k => $v) $qs[$k] = URLDecode($v);
$qs['lang'] = 'en';
echo 'Flip';
Hi Tamara,
Thanks for the tips. Do you see any advantage of this method over
using a small POST form besides the styling problems I'll run into
trying to make t
> foreach($_GET as $k => $v) $qs[$k] = URLDecode($v);
> $qs['lang'] = 'en';
> echo 'Flip';
Hi Tamara,
Thanks for the tips. Do you see any advantage of this method over
using a small POST form besides the styling problems I'll run into
trying to make the submit button look like an achor?
Marc
-
> Session_start();
> $_SESSION['language'] = "en";
> You can set the session variable to the current get or maintain the original
> passed.
I think you may have misunderstood. The problem is holding onto the
existing GET variables in the URL while manipulating or adding one of
them... and doing
Begin forwarded message:
From: Tamara Temple
Date: November 10, 2010 12:05:32 AM CST
To: PHP General
Subject: Re: [PHP] Updating a GET variable
On Nov 9, 2010, at 2:47 PM, Marc Guay wrote:
What's wrong with just putting the url parameters in the link that
you know
you need, one b
On Nov 9, 2010, at 2:47 PM, Marc Guay wrote:
What's wrong with just putting the url parameters in the link that
you know
you need, one by one?
I have a footer that I include on every page and would like it to
adapt to whatever situation it finds itself in. Is your suggestion,
to do the fol
:48 PM
To: a...@ashleysheridan.co.uk
Cc: php-general
Subject: Re: [PHP] Updating a GET variable
> What's wrong with just putting the url parameters in the link that you
know
> you need, one by one?
I have a footer that I include on every page and would like it to
adapt to whatever situation
My working solution was to put it in a form with a hidden input with
the correct name and value.
But I'm still wondering what your advice is regarding best practice.
Marc
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
> What's wrong with just putting the url parameters in the link that you know
> you need, one by one?
I have a footer that I include on every page and would like it to
adapt to whatever situation it finds itself in. Is your suggestion,
to do the following for the existing example:
echo "Flip";
one? If you have many, build a little function for it to reduce
code repetition. Also, don't just output the values sent to the server, as
that's an attack waiting to happen.
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: "Marc Guay"
Date: Tu
Hi folks,
I'm sure this is an easy one that's standing right in front of me but
I'm too blind to see. I have a page with an URL like this:
index.php?name=value&this=that. I have a link on the bottom of the
page which allows the user to switch languages. I need to hang onto
the existing $name and
18 matches
Mail list logo