×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Contact US

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Not able to write less than (<) in defined field

Not able to write less than (<) in defined field

Not able to write less than (<) in defined field

(OP)
DEFINE TABLE TEST
 TAGA/A100 = '<option>';
 TAGB/A100 = 'option>';
END
TABLE FILE TEST
 PRINT TAGA
       TAGB
END
-RUN

The results for TAGA is blank and for TAGB is option>

Seems like when focus sees '<' it just ignore the rest of the string entirely. Anyone knows how to include the '<' sign in the defined field? I'm on WebFocus 761. Thanks.

RE: Not able to write less than (<) in defined field

USE THIS CODE AN REPLACE THE FIELDS WITH TAGA AND TAGB IF DOES FIELDS ARE ALPHANUMERIC DON'T USE D_PRID DEFINE FIELD


DEFINE FILE SCO_PROCESSES
D_PRID/A10 = TRIM('B',FTOA(PROCESSES_ID,'(F10)',D_PRID),10,' ',1,'A10');
D_DESC/A100 = '<option value="'||D_PRID||'">'||PRO_CODE||'</option>';
END

TABLE FILE SCO_PROCESSES
PRINT
D_DESC
BY PRO_CODE NOPRINT
ON TABLE HOLD AS HTMP0001 FORMAT ALPHA
END


-HTMLFORM BEGIN
<html>
<body>
 <select name="INT_PROC">
   <option selected value="FOC_NONE">TODOS</option>
    !IBI.FIL.HTMP0001;
 </select>
</body>
</html>

RE: Not able to write less than (<) in defined field

This is NOT a WebFOCUS issue, but a BROWSER issue.

In WebFOCUS, when you don't specify an output format, the default is HTML. In this case, the '<option>' is interpreted by the BROWSER as a browser control, not data (right click on the output and select 'view source' and you can see it IS in the output), and the browser, since there's no data left, displays blanks. People use this technique to put 'custom' HTML controls into their output.

If you WANT all data to be URL encoded, so the browser will NOT think it's browser control, then issue the following first:

SET HTMLENCODE=ON

And ALL data will be encoded so it shows in the browser.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close