How can I pass objects in a web page?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Brian Bull

    #1

    How can I pass objects in a web page?

    I have written something that creates about 5000 unique objects. I
    want to have a link on a page that when clicked will take the user to
    a page that will "describe" the contents of the object. The problem
    seems to be passing the object from one static page to another via a
    link. Is this possible?
  • drs

    #2
    Re: How can I pass objects in a web page?

    "Cliff Wells" <clifford.wells @comcast.net> wrote in message
    news:mailman.36 06.1095716168.5 135.python-list@python.org ...[color=blue]
    > On Mon, 2004-09-20 at 13:59 -0700, Brian Bull wrote:[/color]

    * * *
    [color=blue][color=green]
    > > passing the object from one static page to another via a
    > > link. Is this possible?[/color]
    >
    > The web, being stateless, usually requires that you "rebuild the world"
    > with every mouse click.[/color]

    Depending upon what the objects are like, python provides the pickle module
    which allows for doing this without setting up a database. Simply have the
    first page embed a pickled object in a hidden input html tag that is sent
    back to the server for the object inspection screen. Not secure of course,
    and conceivably very slow for large objects*, but pretty easy to do.

    -d

    * for large objects, dump them to a file on the server and return some
    unique id instead of the whole object.


    Comment

    Working...