home *** CD-ROM | disk | FTP | other *** search
/ CD-ROM Data 2001 April / CD Rom Data Nisan 2001.iso / Internet / data1.cab / Wizards / HTML / Table_Table.wml < prev    next >
Encoding:
Text File  |  2000-11-30  |  3.6 KB  |  132 lines

  1. <WIZSET CellIndent = RepeatString( ' ', 4 )>
  2.  
  3. <WIZSET i = 0>
  4. <WIZLOOP index="item" list="$${HTMLTable}">
  5.     <WIZSET i = i + 1>
  6.     <WIZIF i eq 1>
  7.         <WIZSET ObjectType = item>
  8.         <WIZBREAK>
  9.         <WIZIF ObjectType neq 'Table'>
  10.             <WIZBREAK>
  11.         </WIZIF>
  12.     <WIZELSEIF i eq 2>
  13.         <WIZSET RowCount = item>
  14.     <WIZELSEIF i eq 3>
  15.         <WIZSET ColCount = item>
  16.     <WIZELSEIF i eq 4>
  17.         <WIZSET RowWidths = item>
  18.     <WIZELSEIF i eq 5>
  19.         <WIZSET ColWidths = item>
  20.         <WIZBREAK>
  21.     </WIZIF>
  22. </WIZLOOP>
  23.  
  24.  
  25. <WIZIF ObjectType neq 'Table'>
  26.  
  27. Invalid object type
  28.  
  29. <WIZELSE>
  30.  
  31. <!---- Tag name and attributes ---->
  32.  
  33.  
  34. <WIZSET TableTagName = DefaultCase('TABLE')>
  35.  
  36. <WIZIF Align eq 'center'>
  37.     <WIZSET aAlign = ' ' & DefaultCase('ALIGN') & '="center"'>
  38. <WIZELSEIF Align eq 'right'>
  39.     <WIZSET aAlign = ' ' & DefaultCase('ALIGN') & '="right"'>
  40. <WIZELSE>
  41.     <WIZSET aAlign = ''>
  42. </WIZIF>
  43.  
  44. <WIZIF not ParameterExists('BgColor')>
  45.     <WIZSET aBgColor = ''>
  46. <WIZELSEIF BgColor eq 'Null'>
  47.     <WIZSET aBgColor = ''>
  48. <WIZELSE>
  49.     <WIZSET aBgColor = ' ' & DefaultCase('BGCOLOR') & '="' & BgColor & '"'>
  50. </WIZIF>
  51.  
  52. <WIZIF not ParameterExists('TableWidth')>
  53.     <WIZSET aWidth = ''>
  54. <WIZELSEIF TableWidth eq ''>
  55.     <WIZSET aWidth = ''>
  56. <WIZELSE>
  57.     <WIZSET aWidth = ' ' & DefaultCase('WIDTH') & '="' & TableWidth & '"'>
  58. </WIZIF>
  59.  
  60. <WIZIF not ParameterExists('TableHeight')>
  61.     <WIZSET aHeight = ''>
  62. <WIZELSEIF TableHeight EQ ''>
  63.     <WIZSET aHeight = ''>
  64. <WIZELSE>
  65.     <WIZSET aHeight = ' ' & DefaultCase('HEIGHT') & '="' & TableHeight & '"'>
  66. </WIZIF>
  67.  
  68. <WIZSET aCellSpacing = ' ' & DefaultCase('CELLSPACING') & '="' & CellSpacing & '"'>
  69. <WIZSET aCellPadding = ' ' & DefaultCase('CELLPADDING') & '="' & CellPadding & '"'>
  70.  
  71. <WIZIF Border neq '0'>
  72.     <WIZSET aBorder = ' ' & DefaultCase('BORDER') & '="' & Border & '"'>
  73.  
  74.     <WIZIF Trim(Frame) eq 'Top side only'>
  75.         <WIZSET aFrame = ' ' & DefaultCase('FRAME') & '="above"'>
  76.     <WIZELSEIF Trim(Frame) eq 'Bottom side only'>
  77.         <WIZSET aFrame = ' ' & DefaultCase('FRAME') & '="below"'>
  78.     <WIZELSEIF Trim(Frame) eq 'Top and bottom sides only'>
  79.         <WIZSET aFrame = ' ' & DefaultCase('FRAME') & '="hsides"'>
  80.     <WIZELSEIF Trim(Frame) eq 'Right and left sides only'>
  81.         <WIZSET aFrame = ' ' & DefaultCase('FRAME') & '="vsides"'>
  82.     <WIZELSEIF Trim(Frame) eq 'Left-hand side only'>
  83.         <WIZSET aFrame = ' ' & DefaultCase('FRAME') & '="lhs"'>
  84.     <WIZELSEIF Trim(Frame) eq 'Right-hand side only'>
  85.         <WIZSET aFrame = ' ' & DefaultCase('FRAME') & '="rhs"'>
  86.     <WIZELSEIF Trim(Frame) eq 'All four sides'>
  87.         <WIZSET aFrame = ' ' & DefaultCase('FRAME') & '="box"'>
  88.     <WIZELSE>
  89.         <WIZSET aFrame = ''>
  90.     </WIZIF>
  91.  
  92.     <WIZIF Trim(Rules) eq 'Between row and column groups'>
  93.         <WIZSET aRules = ' ' & DefaultCase('RULES') & '="groups"'>
  94.     <WIZELSEIF Trim(Rules) eq 'Between rows'>
  95.         <WIZSET aRules = ' ' & DefaultCase('RULES') & '="rows"'>
  96.     <WIZELSEIF Trim(Rules) eq 'Between columns'>
  97.         <WIZSET aRules = ' ' & DefaultCase('RULES') & '="cols"'>
  98.     <WIZELSEIF Trim(Rules) eq 'Between all rows and columns'>
  99.         <WIZSET aRules = ' ' & DefaultCase('RULES') & '="all"'>
  100.     <WIZELSE>
  101.         <WIZSET aRules = ''>
  102.     </WIZIF>
  103.  
  104. <WIZELSE>
  105.     <WIZSET aBorder = ' ' & DefaultCase('BORDER') & '="' & Border & '"'>
  106.     <WIZSET aFrame = ''>
  107.     <WIZSET aRules = ''>
  108.  
  109. </WIZIF>
  110.  
  111.  
  112. <$${TableTagName}$${aAlign}$${aBgColor}$${aWidth}$${aHeight}$${aCellSpacing}$${aCellPadding}$${aBorder}$${aFrame}$${aRules}>
  113. <WIZSET i = 0>
  114. <WIZSET CurrentRow = 0>
  115. <WIZLOOP index="item" list="$${HTMLTable}">
  116.  
  117.     <WIZSET i = i + 1>
  118.     <WIZIF i gt 5>
  119.         <WIZSET CurrentRow = CurrentRow + 1>
  120.         <WIZSET Row = item>
  121.         <WIZINCLUDE template="Table_Row.wml">
  122.     </WIZIF>
  123.  
  124. </WIZLOOP>
  125.  
  126. <WIZIF 1>>
  127. </$${TableTagName}>
  128. </WIZIF>
  129.  
  130.  
  131. </WIZIF>
  132.