Im at a loss, for something so simple i dont know if my brain decided to not help me or what.
Its really simple, i have some checkboxes, a textfield and a button in a template. User writes something in the box, checks a few boxes, and triggers a macro with the values sent to the macro's parameters. (Yes you guessed it, its a custom search function).
So, how? How can i fire the macro with a button? And how do i put the values from the checkboxes and textbox in its parameters?
Is it easier to dump it all in the xslt and have it handle everything?
There's probably many ways to solve this issue, but one would be to 'create' a standard html form with submit button within your xslt form, then just post to another page and deal with the form here, or if you want it on the same page just check to see if you have any request.form values and deal with it accordingly.
Pretty much the same as you would with straight html.
Thanks for your time for such a simple question, my brain hasnt started functioning. Ive made a form that submits a GET to a new page that has the macro, which takes the values from the values appended to the url from the get. Only problem is, for some reason it wont, it only sends he value of the submit button, or just nothing at all. Odd indeed.
Man, i must be tired if i cant figure this one out.
I have no idea why it does that. Even if the macro in the receiving page doesnt work (though it looks like it does), the values should still be appended regardless. It doesnt really make any sense.
Yeah, just did that, and realized something incredibly stupid. Remember i said my brain wasnt functioning? Well, it decided to boot up and i saw a complete ultimate rookie mistake.
i gave all the fields "id" instead of "name". Man, what was a i thinking? Needles to say, it works now. So thank you for your time, i appreciate you for helping me with such a silly thing.
Simple and stupid question
Im at a loss, for something so simple i dont know if my brain decided to not help me or what.
Its really simple, i have some checkboxes, a textfield and a button in a template. User writes something in the box, checks a few boxes, and triggers a macro with the values sent to the macro's parameters. (Yes you guessed it, its a custom search function).
So, how? How can i fire the macro with a button? And how do i put the values from the checkboxes and textbox in its parameters?
Is it easier to dump it all in the xslt and have it handle everything?
Hey Frederik,
There's probably many ways to solve this issue, but one would be to 'create' a standard html form with submit button within your xslt form, then just post to another page and deal with the form here, or if you want it on the same page just check to see if you have any request.form values and deal with it accordingly.
Pretty much the same as you would with straight html.
Rich
Thanks for your time for such a simple question, my brain hasnt started functioning. Ive made a form that submits a GET to a new page that has the macro, which takes the values from the values appended to the url from the get. Only problem is, for some reason it wont, it only sends he value of the submit button, or just nothing at all. Odd indeed.
Man, i must be tired if i cant figure this one out.
Hey,
There's nothing wrong with your form as far as I can see.
Have you tried just putting it directly in a template (rather than xslt) just to test?
Rich
What you see there is in a template. When i press submit it puts the submit buttons value in the ur like so:
I have no idea why it does that. Even if the macro in the receiving page doesnt work (though it looks like it does), the values should still be appended regardless. It doesnt really make any sense.
What does the following get you?
<form name="input" action="/studie/legater/soegeresultat.aspx" method="get">Test: <input type="text" name="test" />
<input type="submit" value="Submit" />
</form> Rich
Gives me this url, very odd:
Hey,
I would add your pieces of code in bit by bit and see when it causes a problem
Rich
Yeah, just did that, and realized something incredibly stupid. Remember i said my brain wasnt functioning? Well, it decided to boot up and i saw a complete ultimate rookie mistake.
i gave all the fields "id" instead of "name". Man, what was a i thinking? Needles to say, it works now. So thank you for your time, i appreciate you for helping me with such a silly thing.
Hey,
Glad I could help, we all have these days, sometimes you just need to talk it through :)
Rich
is working on a reply...