#=================================================================== # # COMPAT.TXT -- Make Caucus 4.0 interface compatible with 4.1 engine. # # After installing Caucus 4.1, add the contents of this file to # the end of CML/SP40/Local/macros.i. # #--------------------------------------------------------------------- # "Built-in" macros. These are special macros that *must* be defined, # because calls to these macros are generated by 'C' code in the # swebs CML interpreter. #---%_new_target_window(newx, newy) (nee "%target" in 4.0) # Opens a new window to be used as a target for some URL. # If possible, the new window size is newx by newy pixels. # # Typically used in an tag to put the target URL in # a new window, as in: # #eval $mac_define (_new_target_window TARGET="_blank") eval $mac_define (_new_target_window \$char(32)onClick="\ win = window.open ('', 'fromcau', 'width=@1,height=@2,\ resizable=1,toolbar=1,scrollbars=1,menubar=1,location=1,status=1'); \ $(winfocus) return true;" TARGET="fromcau" ) #---%_caucus_url(cnum inum rnum) (nee "%special" in 4.0) # Translate 'http:/caucus/...' so-called "special" URLs into # URLs that reference the appropriate CML pages. # # Thus, http:/caucus -> (goes to) the Caucus Center # http:/caucus/conf -> conference home page of 'conf' # http:/caucus/conf/item -> conference 'conf', item # 'item' # http:/caucus/conf/item:r -> 'conf' item 'item', response 'r'. eval $mac_define (_caucus_url \ \$ifthen (\$empty(@1) \$(href)/center.cml?\$(nch)+\$(nxt)+x+x+x+x+x+x)\ \$ifthen (\$and (\$not_empty(@1) \$empty(@2)) \ \$(href)/confhome.cml?\$(nch)+\$(nxt)+@1+x+x+x+x+x)\ \$ifthen (\$and (\$not_empty(@1) \$not_empty(@2)) \ \$(href)/viewitem.cml?\$(nch)+\$(nxt)+@1+@2+@3+x+x+x#here)\ ) #===================================================================