function printOnIndexBottom()
{
    global $adkportal, $user_info, $options, $current_load;
    //Static level
    static $level = 0;
    //If level > 0.... return false;
    if ($level >= 1) {
        return false;
    }
    echo '
			</td>';
    if (!empty($adkportal['right'])) {
        echo '
			<td id="adk_right_' . $current_load[0] . '_' . $current_load[1] . '" valign="top" style="width:', $adkportal['wright'], ';' . ($user_info['is_guest'] ? !empty($_COOKIE['adk_right_' . $current_load[0] . '_' . $current_load[1]]) : !empty($options['adk_right_' . $current_load[0] . '_' . $current_load[1]]) ? ' display: none;' : '') . '" class="adk_padding_5_l">
				', createColumn('right'), '
			</td>';
    }
    echo '
		</tr>
	</table>';
    $level++;
}
Example #2
0
 function createHomeSheet()
 {
     global $docs, $ids, $names;
     global $table0;
     global $output, $input;
     global $msg, $lang, $template;
     include "export/{$template}/settings-ods-{$lang}.php";
     //First sheet (Criteria)
     $table0 = $output->createElement('table:table');
     $table0->setAttribute("table:name", $tpl_msg['ods_home']);
     $table0->setAttribute("table:style-name", "ta1");
     $table0->setAttribute("table:print", "false");
     $table0->setAttribute("table:protected", "true");
     $protection = $output->createElement('table:table-protection');
     $protection->setAttribute("table:select-protected-cells", "true");
     $protection->setAttribute("table:select-unprotected-cells", "true");
     $table0->appendChild($protection);
     $table0->appendChild(createColumn("co4", "ce1"));
     $table0->appendChild(createColumn("co0", "ce1"));
     $table0->appendChild(createColumn("co0", "ce1"));
     $table0->appendChild(createColumn("co0", "ce1"));
     $table0->appendChild(createColumn("co0", "ce1"));
     //Title
     $table0->appendChild(createTitleRow1());
     $table0->appendChild(createTitleRow2($input->getkey("qsosappfamily")));
     $table0->appendChild(createTitleRow3($tpl_msg['ods_home_subtitle']));
     $table0->appendChild(createSimpleRow());
     $table0->appendChild(createSimpleRow());
     //Text
     $table0->appendChild(createHomeDoubleRow("Version", "1.0"));
     $table0->appendChild(createHomeDoubleRow("Date", date('d/m/Y')));
     $table0->appendChild(createSimpleRow());
     $table0->appendChild(createSimpleRow());
     $table0->appendChild(createHomeUderlineRow($tpl_msg['ods_home_text1']));
     $table0->appendChild(createHomeDoubleRow($tpl_msg['ods_home'], $tpl_msg['ods_home_text2']));
     $table0->appendChild(createHomeDoubleRow($tpl_msg['ods_synthesis'], $tpl_msg['ods_home_text3']));
     $table0->appendChild(createHomeDoubleRow($tpl_msg['ods_criteria'], $tpl_msg['ods_home_text4']));
     $i = 0;
     foreach ($ids as $id) {
         $input = $docs[$i];
         $title = $names[$i];
         $i++;
         $value = $tpl_msg['ods_home_text6'] . $title;
         $table0->appendChild(createHomeDoubleRow($title, $value));
     }
     $table0->appendChild(createSimpleRow());
     $table0->appendChild(createSimpleRow());
     $table0->appendChild(createHomeUderlineRow("NB :"));
     $table0->appendChild(createHomeItalicRow($tpl_msg['ods_home_text5']));
     if ($tpl_msg['ods_home_license']) {
         $table0->appendChild(createSimpleRow());
         $table0->appendChild(createSimpleRow());
         $table0->appendChild(createHomeUderlineRow($tpl_msg['ods_home_license']));
     }
 }
Example #3
0
function addGridToDB($data)
{
    $gridname = $data['grid_step1_name'];
    $description = $data['grid_step1_description'];
    $createdby = $_SESSION['username'];
    $createon = time();
    $criteria = array($gridname, $description, $createdby, $createon);
    $gridId = createGrid($criteria);
    $i = 1;
    $total = sizeof($data) - 3;
    $count = 1;
    for ($count = 1; $count < $total; $count += 3) {
        if (isset($data["grid_step2_column" . $i . "_name"]) && $data["grid_step2_column" . $i . "_name"] != null && strcmp($data["grid_step2_column" . $i . "_name"], "") != 0) {
            $columnname = $data["grid_step2_column" . $i . "_name"];
            $columndatatype = $data["grid_step2_column" . $i . "_datatype"];
            $columndesc = $data["grid_step2_column" . $i . "_description"];
            $criteria = array($gridId, $columnname, $columndesc, $columndatatype);
            $columnid = createColumn($criteria);
            $columndata = $data["grid_step2_column" . $i . "_data"];
            if (strcmp($columndatatype, "text") == 0) {
                $length = $columndata["grid_step2_column" . $i . "_text_size"];
                $allow_empty = $columndata["grid_step2_column" . $i . "_text_allow_empty"];
                if ($allow_empty == "") {
                    $allow_empty = 'N';
                } else {
                    $allow_empty = 'Y';
                }
                $isunique = $columndata["grid_step2_column" . $i . "_text_unique"];
                if ($isunique == "") {
                    $isunique = 'N';
                } else {
                    $isunique = 'Y';
                }
                $criteria = array($columnid, $length, $allow_empty, $isunique);
                createColumnText($criteria);
            } else {
                if (strcmp($columndatatype, "textarea") == 0) {
                    $size = $columndata["grid_step2_column" . $i . "_textarea_size"];
                    $criteria = array($columnid, $size);
                    createColumnTextarea($criteria);
                }
            }
            $insertid = "";
        }
        $i++;
    }
}
function template_home()
{
    //I wanna load the column center only
    createColumn('center');
}