@kprocauthorAug 24.2006 — #Thank you for the info, I gave it a try and did not work.
I have a calendar that offers each day of the week as link. I want to offer a calendar icon for the user to click which will popup the calendar and when the user clicks a date it files a forms text field with the date.
I'm thinking that I would have to make the begining url a variable as I only want to have to create one calendar and At the end of the webpage address I was set a variable like
@NogDogAug 24.2006 — #Probably the most dependable way would be something like: [code=php] $thisPageUrl = 'http://www.mydomain.com'.array_shift(explode('?', $_SERVER['PHP_SELF'])); [/code] If you want to include any query string as well, then get rid of the array_shift/explode stuff, but be aware that users could manually add anything to the query string, so you'll need to screen it for anything you don't want to be output (htmlspecialchars(), perhaps?).
@kprocauthorAug 24.2006 — #I have it working so that the url show the page were I I want the value to go. I ran into a snag.
A window with a calendar is opened via a pop-up from an icon next to the field were I want the information to go. The prblem is when I click the date I need it to send the value to the form field.
@bokehAug 24.2006 — #Probably the most dependable way would be something like: [code=php] $thisPageUrl = 'http://www.mydomain.com'.array_shift(explode('?', $_SERVER['PHP_SELF'])); [/code] If you want to include any query string as well, then get rid of the array_shift/explode stuff, but be aware that users could manually add anything to the query string, so you'll need to screen it for anything you don't want to be output (htmlspecialchars(), perhaps?).[/QUOTE][I]$_SERVER['PHP_SELF'][/I] shouldn't contain the query string if one were to exist.
@kprocauthorAug 24.2006 — #The calendar is a seperate page which is opened via javascript. the dates are hyperlinks which when licked I want the value written to the form
So if user clicks
24
the value 08-24-2006 which is stored in id would be entered into a form on the active page. just like if I click a smile it sends the code to my post equals ?