MiniVend Akopia Services

[Date Prev][Date Next][Thread Prev][Thread Next][Minivend by date ][Minivend by thread ]

RE: Beyond Remembering mv_searchspec



******    message to minivend-users from "Thompson-Jordan" <Thompson-Jordan@mindspring.com>     ******

I understand how to use either standard Minivend or Perl to assign the
values of vars like mv_search_field into my variables (see below). But if
the values are null, there is no use in saving them. It makes sense that
Minivend clears them. But, is there a way to access these mv_ vars after a
search.

As Frank correctly points out, [more-list] generates these searches. The URL
generated by [more-list] looks like:

www.mysite.com/cgi-bin/vlink/scan/MM=29b28b7c7f0d4372b53eba:50:99:50:?ABxz5m
y3;;42

It looks like the search information is stuffed in the first parameter of
the mv_max_matches parameter (which might explain why some people have had
problems using mv_max_matches). However most of my pages don't have more
items than will fit on a page, hence no more-list. Any ideas on how to get
to this information?

Christopher Thompson

> -----Original Message-----
> From: owner-minivend-users@minivend.com
> [mailto:owner-minivend-users@minivend.com]On Behalf Of Frank Miedreich
> Sent: Wednesday, February 03, 1999 6:01 AM
> To: minivend-users@minivend.com
> Subject: Re: Beyond Remembering mv_searchspec
>
>
> ******    message to minivend-users from Frank Miedreich
> <miedreich@acm.org>     ******
>
> >******    message to minivend-users from "Thompson-Jordan"
> ><Thompson-Jordan@mindspring.com>     ******
> >
> >In a previous thread it was discussed how to assign mv_searchspec into
> >variables using Perl. That works for mv_searchspec, but the other search
> >variables do not seem to keep their values (e.g. mv_coordinate,
> >mv_search_field) on the results page. For example, if I put the
> following on
> >a results page:
> >
> >co=[value mv_coordinate]=
> >sf=[value mv_search_field]=
> >se=[value mv_searchspec]=
> >
> >I get:
> >
> >co==
> >sf==
> >se=mysearch=
> >
> >How do I access all these search variables that went into generating the
> >page? My goal is to have a results page be able to resubmit
> itself. I will
> >then change parts of the page's appearance with other variables.
> I am using
> >MV 3.11
> >
>
> Hi,
>
> the perl solution should work with any variable set on any form.
>
> after you set mv_check to search values, you can do:
>
> [set search values]
> [perl arg=values interpolate=1]
>         $Safe{'values'}{'se'} = '[value mv_searchspec]';
>         $Safe{'values'}{'sf'} = '[value mv_search_field]';
>         $Safe{'values'}{'co'} = '[value mv_coordinate]';
>         return '';
> [/perl]
> [/set]
>
> no need to do this in perl though, you should be able to do:
> [set search values]
> [value name="se" set="[value mv_searchspec]"]
> [value name="sf" set="[value mv_search_field]"]
> [value name="co" set="[value mv_coordinate]"]
> [/set]
>
>
> you can split stacked vars with:
>
> [set search values]
> [perl arg=values interpolate=1]
> # first for searchspec
>         my($msg1)='[value mv_searchspec]';
>         my(@items)=split (/\0/, $msg);
>         $Safe{'values'}{'se_1'} = $items[0];
>         $Safe{'values'}{'se_2'} = $items[1];
> # and now for searchfield
> 	$msg='[value mv_search_field]'
> 	@items=split (/\0/, $msg);
>         $Safe{'values'}{'sf_1'} = $items[0];
>         $Safe{'values'}{'sf_2'} = $items[1];
>         return '';
> [/perl]
> [/set]
>
>
> I just would not overdo it. If you really want to be able for the search
> page to resubmit everything, check the urls generated by more list.
> minivend remembers the search anyway, so you might not need to do that.
>
> BTW: The variables don't remember their values for a good reason.
> Otherwise
> the next search might not work, e.g. if a previous search was a
> range_look,
> and the current search for a string, you would get unexpected results if
> the range_look would still be active.
>
> Happy minivending.
>
> Frank
>
>
> --
> Frank Miedreich
> Max-Planck-Institut fuer psychologische Forschung
>
>
> -
> To unsubscribe from the list, DO NOT REPLY to this message.  Instead, send
> email with 'UNSUBSCRIBE minivend-users' in the body to
> Majordomo@minivend.com.
> Archive of past messages: http://www.minivend.com/minivend/minivend-list
>

-
To unsubscribe from the list, DO NOT REPLY to this message.  Instead, send
email with 'UNSUBSCRIBE minivend-users' in the body to Majordomo@minivend.com.
Archive of past messages: http://www.minivend.com/minivend/minivend-list


Search for: Match: Format: Sort by: