View Single Post

  #7 (permalink)  
Old 11-23-2005
Ian Davies
 
Posts: n/a
Default Re: Parse error with php/java script

Hello

The script here is modified from a previous script where I have not
atempted to use java to update a second dropdownmenu/listbox (havent decided
which to use yet) from the item selected in the first. In the previous
script I use the exact same sqls which work fine.
Go here to see these SQLs working in the dropdown lists
http://www.iddsoftware.co.uk/Questio...ionsBrowse.php

Ian


"Justin Koivisto" <justin@koivi.com> wrote in message
news:XeidnVQDys8rNh7enZ2dnUVZ_tGdnZ2d@onvoy.com...
> Ian Davies wrote:
> > Thanks
> > That helped
> > But now get a syntax error on line 69
> > which is
> >
> > echo "subselect.options[".$ctr."].value =
> > \"".$Row2['TopicID']."\";\n";
> >
> > my debugger is saying
> >
> > if( mainselect.options[mainselect.selectedIndex].value == "12" ) {
> > Warning: mysql_fetch_array(): supplied argument is not a valid MySQL

result
> > resource in e:\domains\i\mysite\user\htdocs\myfolder\Questions .php on

line
> > 67
> > } }
> >
> > It would seem that there is a problem with
> >
> > mainselect.options[mainselect.selectedIndex].value

>
> Or there's something wrong with the query. You blindly start a while
> loop without first checking to see if the query has succeeded. In this
> case, if $Result isn't a valid result resource, the query failed for
> some reason... to help debug, use mysql_error() to see what the problem

is.
>
> --
> Justin Koivisto, ZCE - justin@koivi.com
> http://koivi.com



Reply With Quote