You are here: Re: Parse error with php/java script « PHP SQL « IT news, forums, messages
Re: Parse error with php/java script

Posted by Ian Davies on 11/23/05 01:09

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

Ian



"Justin Koivisto" <justin@koivi.com> wrote in message
news:uPidnaxdQ-f-Ch7eRVn-ow@onvoy.com...
> Ian Davies wrote:
> >
> > Parse error: parse error, unexpected T_VAR in
> > e:\domains\i\iddsoftware.co.uk\user\htdocs\QuestionDB\Questions.php on
line
> > 42
> >
> <snip>
>
> > function Fill_Sub()
> > {
> >
> > <?PHP
>
> This is in the wrong spot...
>
> > var mainselect = document.FormName.MainCategory;
> > var subselect = document.FormName.SubCategory;
> >
> > if( mainselect.options[mainselect.selectedIndex].value != 0 ) {
> >
> > subselect.length = 0;
> > }
>
> This is where the "<?php" should be...
>
> > $Query = "SELECT SubjectNo, SubjectDesc, StatusID FROM Subjects
WHERE
> > StatusID = 1 ORDER BY SubjectDesc ASC";
> > $Result = mysql_query($Query, $conn );
>
> <snip>
>
> --
> Justin Koivisto, ZCE - justin@koivi.com
> http://koivi.com

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация