This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

creating web page in LPC2366

hi,

I am using LPC2366, written a code in scripting language....
In the web browser I want to display three selection BOXES, but when I try to open the web page with this code it does not open, However for two text boxes it works......... please suggest me the modification that has to be done in my code...

<----------------cdma.cgi------------------------>
# Here begin data setting which is formatted in HTTP_CGI.C module-->
t <TR><TD><IMG SRC=pabb.gif>Communication Mode</TD>
c b o <TD><select name="cm"><OPTION %s>Ethernet</OPTION><OPTION %s>Gprs</OPTION><OPTION %s>Cdma</OPTION></select></TD></TR>

XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

<---------------- HTTP.c----------------------->

switch(env[2]){

case 'o':

if ( SchedCfg.ucCommedium == 0 )

len = sprintf((S8 *)buf,(const S8 *)&env [4], "selected", "", "" );

else if ( SchedCfg.ucCommedium == 1 )

len = sprintf((S8 *)buf,(const S8 *)&env[4], "", "selected", "" );

else if ( SchedCfg.ucCommedium == 2 )

len = sprintf((S8 *)buf,(const S8 *)&env[4], "", "", "selected" ); break;

Parents
  • It would help to indicate to everyone that you're using the Keil RTL-TCPNET software, and you're clearly using the HTTP_demo.c application as the basis for your project. This is obvious to me because I've used it myself, but it won't be obvious to everyone.

    My first observation is that you are using rather long script lines. For example, the following line:

    c b o <TD><select name="cm"><OPTION %s>Ethernet</OPTION><OPTION %s>Gprs</OPTION><OPTION %s>Cdma</OPTION></select></TD></TR>
    

    This is 123 characters long. But the maximum script line length that you are allowed to have is 120 characters! See here (very last sentence at the bottom):

    www.keil.com/.../rlarm_tn_http_scriptlang.htm

    I am not sure if exceeding the script line length is the actual cause of your problem. I cannot remember if script lines that are too long are just truncated, or ignored altogether. But as a starting point, I suggest you break the script up into shorter lines and then we'll take it from there.

Reply
  • It would help to indicate to everyone that you're using the Keil RTL-TCPNET software, and you're clearly using the HTTP_demo.c application as the basis for your project. This is obvious to me because I've used it myself, but it won't be obvious to everyone.

    My first observation is that you are using rather long script lines. For example, the following line:

    c b o <TD><select name="cm"><OPTION %s>Ethernet</OPTION><OPTION %s>Gprs</OPTION><OPTION %s>Cdma</OPTION></select></TD></TR>
    

    This is 123 characters long. But the maximum script line length that you are allowed to have is 120 characters! See here (very last sentence at the bottom):

    www.keil.com/.../rlarm_tn_http_scriptlang.htm

    I am not sure if exceeding the script line length is the actual cause of your problem. I cannot remember if script lines that are too long are just truncated, or ignored altogether. But as a starting point, I suggest you break the script up into shorter lines and then we'll take it from there.

Children