Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

[REBOL] Re: Placing variable in FORM field

From: Al:Bri:xtra at: 12-Jul-2003 11:49

John wrote:
> I have the following variable defined and I would like to call it into the
FORM field value sited:
> b1: cgi/title > print [<input type="text" name="u_menu_title" size="20" value=b1>]
Have you considered using RSP? It's available from: http://www.shlik.org/rsp/ RSP allows one to insert some dynamic content into statically generated pages designed in a web page design program. Some people find this easier to understand. Have you considered using my ML dialect which is expressely for creating HTML pages? It's available from my site or directly from me. In ML, your example would translate to: b1: cgi/title ML compose/deep [ input/type/name/size/value "text" 'u_menu_title 20 (b1) ] ML is designed for HTML, XHTML, XML, WML, XML-SS and so on. It's meant for extremely fluid sites, where every page is highly dynamic and styling is done through CSS. For example, 'Peers, shows peer CGI scripts: Peers: func [Folder [file!]] [ compose/deep [ div/class "Peers" [( map read Folder function [File [file!]] [Header] [ if all [ %.r = extension? File File != Rebol/script/header/File ] [ Header: first load/header Folder/:File Title: trim/lines any [Header/Purpose ""] compose/deep [ span/class "Peer" [ a/href/title (Folder/:File) (Title) (Header/Title) ] ] ] ] )] ] ] Otherwise, Gabriele's solution: print [ {<input type="text" name="u_menu_title" size="20" value="} b1 {">} ] or Andreas' solution: print rejoin [ {<input type="text" name="u_menu_title" size="20" value="} b1 {">} ] are OK. Andrew J Martin ICQ: 26227169 http://www.rebol.it/Valley/ http://Valley.150m.com/