Professional Web Applications Themes

Form Auto Submission - PHP Development

"John Rock" <johnrock88msn.com> wrote in message > FORM ACTION="search.asp" METHOD="post" NAME="search"> > <B>Search String</B><BR> > <INPUT NAME="SearchString"><BR> > <INPUT TYPE="submit" NAME="GoSearch" VALUE="Search"> </P> > </FORM> > > > Simple enough. I need to populate the SearchString and send it over to the > ASP > script. Any way to do this? On your site you should have a form that submits $value. When receiving the input of the form, you create a link like this: $link = "http://www.externalWebsite.com/search.asp?GoSearch=Search&SearchString=$value"; Then you use fopen to open the other site. However, if the code on the other end excludes GET requests and only ...

  1. #1

    Default Re: Form Auto Submission

    "John Rock" <johnrock88msn.com> wrote in message
    > FORM ACTION="search.asp" METHOD="post" NAME="search">
    > <B>Search String</B><BR>
    > <INPUT NAME="SearchString"><BR>
    > <INPUT TYPE="submit" NAME="GoSearch" VALUE="Search"> </P>
    > </FORM>
    >
    >
    > Simple enough. I need to populate the SearchString and send it over to the
    > ASP
    > script. Any way to do this?
    On your site you should have a form that submits $value. When
    receiving the input of the form, you create a link like this:

    $link = "http://www.externalWebsite.com/search.asp?GoSearch=Search&SearchString=$value";

    Then you use fopen to open the other site. However, if the code on the
    other end excludes GET requests and only allows POST requests, you may
    have some trouble.
    lawrence Guest

  2. #2

    Default Re: Form Auto Submission

    "John Rock" <johnrock88msn.com> wrote in message
    > FORM ACTION="search.asp" METHOD="post" NAME="search">
    > <B>Search String</B><BR>
    > <INPUT NAME="SearchString"><BR>
    > <INPUT TYPE="submit" NAME="GoSearch" VALUE="Search"> </P>
    > </FORM>
    >
    >
    > Simple enough. I need to populate the SearchString and send it over to the
    > ASP
    > script. Any way to do this?
    On your site you should have a form that submits $value. When
    receiving the input of the form, you create a link like this:

    $link = "http://www.externalWebsite.com/search.asp?GoSearch=Search&SearchString=$value";

    Then you use fopen to open the other site. However, if the code on the
    other end excludes GET requests and only allows POST requests, you may
    have some trouble.
    lawrence Guest

  3. #3

    Default Re: Form Auto Submission

    Make sure that you have the Absolute URI for the ACTION parameter

    Example:
    <FORM ACTION="http://altavista.com/web/results/search.asp" METHOD="post"
    NAME="search">
    <B>Search String</B><BR>
    <INPUT NAME="SearchString"><BR>
    <INPUT TYPE="submit" NAME="GoSearch" VALUE="Search"> </P>
    </FORM>

    Make sure that the textfield name is the same as the variable that the
    search engine looks at for the Search Paramters
    IE. If it is looking for $Search, change SearchString to Search



    John Rock wrote:
    > I am new to PHP and would like to know if this is doable.
    >
    > External website has a search feature I will like to access and p the
    > results. The site uses the following html code for the form.
    >
    > FORM ACTION="search.asp" METHOD="post" NAME="search">
    > <B>Search String</B><BR>
    > <INPUT NAME="SearchString"><BR>
    > <INPUT TYPE="submit" NAME="GoSearch" VALUE="Search"> </P>
    > </FORM>
    >
    >
    > Simple enough. I need to populate the SearchString and send it over to the
    > ASP
    > script. Any way to do this?
    >
    > Thanks for any help,
    >
    > John
    >
    >
    Billy Guest

  4. #4

    Default Re: Form Auto Submission

    Make sure that you have the Absolute URI for the ACTION parameter

    Example:
    <FORM ACTION="http://altavista.com/web/results/search.asp" METHOD="post"
    NAME="search">
    <B>Search String</B><BR>
    <INPUT NAME="SearchString"><BR>
    <INPUT TYPE="submit" NAME="GoSearch" VALUE="Search"> </P>
    </FORM>

    Make sure that the textfield name is the same as the variable that the
    search engine looks at for the Search Paramters
    IE. If it is looking for $Search, change SearchString to Search



    John Rock wrote:
    > I am new to PHP and would like to know if this is doable.
    >
    > External website has a search feature I will like to access and p the
    > results. The site uses the following html code for the form.
    >
    > FORM ACTION="search.asp" METHOD="post" NAME="search">
    > <B>Search String</B><BR>
    > <INPUT NAME="SearchString"><BR>
    > <INPUT TYPE="submit" NAME="GoSearch" VALUE="Search"> </P>
    > </FORM>
    >
    >
    > Simple enough. I need to populate the SearchString and send it over to the
    > ASP
    > script. Any way to do this?
    >
    > Thanks for any help,
    >
    > John
    >
    >
    Billy Guest

Similar Threads

  1. Submission Form?
    By withhisstripes in forum Macromedia Dynamic HTML
    Replies: 3
    Last Post: August 22nd, 07:12 PM
  2. Submission Form
    By withhisstripes in forum Macromedia Dynamic HTML
    Replies: 1
    Last Post: July 19th, 07:17 PM
  3. Auto Submission of Dbase data
    By The_FedEx_Guy in forum Dreamweaver AppDev
    Replies: 0
    Last Post: April 22nd, 11:05 AM
  4. Form submission fills form values with garbage
    By ratlhead in forum PHP Development
    Replies: 5
    Last Post: September 27th, 05:20 AM
  5. The woes of a PHP form submission
    By Martin the Mac Addict in forum PHP Development
    Replies: 2
    Last Post: September 5th, 02:50 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139