Re: File extension for PHP's serialization format?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 27/10/06, Stut <stuttle@xxxxxxxxx> wrote:
Hamish Lawson wrote:
> I have a web application (not written in PHP) that can return data in
> various formats, including JSON and PHP's serialization format. At the
> moment my URL scheme looks like this:
>     staff/engineering?format=json
> but I'd like to switch to using a file extension to denote the format:
>     staff/engineering.json

Given that file extensions are purely for association purposes and no
application I am aware of knows what to do with PHP serialised data,
personally I would use .dat. Or, if I wanted it to be more descriptive,
something like .phpdata. But to be perfectly frank it doesn't matter.

I know of one website (Livejournal) that has /url.../data/rss or
/data/atom etc.  /data/php, /data/wddx or /data/json are pretty
obvious extensions to that.

That said, since all are them are designed for a script to consume,
and not a person, I'd call them entirely 'clean' and obvious enough
for the task, though ultimately, it's about having a pretty URL, as
the program that reads it won't care what the extension is, if any,
and people won't be typing it in regularly anyway.

Alister

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux