Jump to content

benjoewilson

Members
  • Posts

    5
  • Joined

  • Last visited

    Never

Contact Methods

  • Website URL
    http://

Profile Information

  • Gender
    Not Telling
  • Location
    London

benjoewilson's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. I have a form that I posts a number of variables to a third party. When the button is clicked I want the form to be posted and my database to be updated to say that the user has clicked to go on to the third party without the user to have to do another click. I believe I may be able to do this with a redirect but can't find code that works. I don't really want to use Javascript but open to ideas on all fronts.
  2. I have installed php and IIS on my laptop but am pretty clueless on any set up further than that. All works fine except when I view images they are jumbled. The same happens in IE, mozilla and Netscape. If I enter the address as below it comes out disjointed and jumbled. [a href=\"http://localhost/pictures/activities/test.jpg\" target=\"_blank\"]http://localhost/pictures/activities/test.jpg[/a] If I enter the address file:///C:/Inetpub/wwwroot/pictures/activities/test.jpg It comes out fine. It also comes out fine when I upload it online which is based on an apache server. This is happening for the majority of my jpeg images, I have tried switching an image to GIF and it still happens. Any ideas appreciated.
  3. Thanks for that it is working exactly as I want in both Netscape and Firefox but I can't get it to recognise the variable in Explorer. I have narrowed the problem down to the below example. [code] <head> <script type="text/javascript"> <!-- function selecteduser() { idx = document.userselection.selection.selectedIndex; var selection = document.userselection.selection.options[idx].value; oImg = document.getElementById("imgplace"); oImg.innerHTML='Selection = ' + selection; } --> </script> </head> <form name="userselection">     <select name="selection" onChange="selecteduser()">     <option> 1     <option> 2     <option> 3     </select> <div id="imgplace"></div> </form> [/code]
  4. Hi bit of a noobie with javascript and hoping this is pretty basic, My aim is to have users select from a drop down box. When the selection is made an image with a href is put into the page with the href incorporating the selection from the drop down. so far I have named the form and selection box as below <form action="addnewmemberconfirm.php" method="post" name="userselection"> <select name="usernameselected" onChange="selecteduser()"> .....list of optons closed form ect and tried the javascript below. <script type="text/javascript"> <!-- function selecteduser( ) { var username = 'testvariable'; var usernameselected = document.userselection.usernameselected.value ; alert ("user is " + username + usernameselected) document.write ( '<a href="userdetails.php?username=' + usernameselected + '<img src="pic.jpg"></a>'); } // --> </script> The alert is just for testing and comes up fine but with an empty usernameselected. I hoped the setting of the variable usernameselected would work but doesn't and I don't know how to get java to write the html exactly where the script is written. apologies for quite how clueless I am, any help much appreciated.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.