Belgin Fish
Belgin Fish

Reputation: 19847

Best Way To Encode and Decode Text PHP

I'm looking for a method in which I can decode and encode text to be passed in a url.

Not base64

Any others?

Upvotes: 5

Views: 5073

Answers (2)

fbrereto
fbrereto

Reputation: 35935

You could try:

(and their respective decode routines) or a handful of other options. Without a little more knowledge as to the use case you are trying to solve, though, answers will be lethargic or vague.

Upvotes: 2

Nick Presta
Nick Presta

Reputation: 28695

PHP has two functions: urlencode() and urldecode(). Perhaps they are of use to you.

What exactly do you mean decode/encode text to be passed in a URL? If you're looking for a way to pass 'secret' data, using GET parameters is not the right way to do it.

Upvotes: 1

Related Questions