コード例 #1
0
        case $row->fields['products_options_type'] == PRODUCTS_OPTIONS_TYPE_FILE:
            $the_attributes_type = '(FILE)';
            break;
        case $row->fields['products_options_type'] == PRODUCTS_OPTIONS_TYPE_CHECKBOX:
            $the_attributes_type = '(CHECKBOX)';
            break;
        default:
            $the_attributes_type = '(DROPDOWN)';
            break;
    }
    if ($_GET['lng_id'] != $_SESSION['languages_id']) {
        echo '<td align="center" class="dataTableContent">' . zen_get_language_icon($_SESSION['languages_id']) . '</td>' . "\n";
        echo '<td align="left" class="dataTableContent">' . zen_get_option_name_language($row->fields["products_options_id"], $_SESSION['languages_id']) . '</td>' . "\n";
        echo '<td align="right" class="dataTableContent">' . zen_get_option_name_language_sort_order($row->fields["products_options_id"], $_SESSION['languages_id']) . '&nbsp;&nbsp;</td>' . "\n";
    }
    echo '<td align="center" class="dataTableContent">' . zen_get_language_icon($_GET['lng_id']) . '</td>' . "\n";
    echo '<td align="right" class="dataTableContent">' . $row->fields["products_options_id"] . '</td>' . "\n";
    echo '<td class="dataTableContent" align="center">' . $the_attributes_type . '</td>' . "\n";
    echo '<td class="dataTableContent">' . $row->fields["products_options_name"] . '</td>' . "\n";
    echo '<td class="dataTableContent" align="center">' . "<input type=\"text\" name=\"products_options_sort_order[" . $row->fields['products_options_id'] . "]\" value={$row->fields['products_options_sort_order']} size=\"4\">" . '</td>' . "\n";
    echo '</tr>' . "\n";
    $row->MoveNext();
}
?>
            <tr class="dataTableHeadingRow">
										<td
											colspan="<?php 
echo $_GET['lng_id'] == $_SESSION['languages_id'] ? '1' : '4';
?>
"
											height="50" align="center" valign="middle"
                    break;
                case 'ez-pages':
                    $ez_pages_query = $db->Execute("SELECT * FROM " . TABLE_EZPAGES . " ORDER BY pages_title");
                    $ez_pages_meta = array();
                    while (!$ez_pages_query->EOF) {
                        $ez_pages_meta[] = array('id' => $ez_pages_query->fields['pages_id'], 'name' => $ez_pages_query->fields['pages_title'], 'title' => stripslashes($ez_pages_query->fields['pages_meta_title']), 'keywords' => stripslashes($ez_pages_query->fields['pages_meta_keywords']), 'description' => stripslashes($ez_pages_query->fields['pages_meta_description']), 'language' => zen_get_language_icon((int) $ez_pages_query->fields['languages_id']), 'language_id' => $ez_pages_query->fields['languages_id'], 'removeable' => 'false');
                        $ez_pages_query->MoveNext();
                    }
                    $respond['group'] = $meta_group;
                    $respond['metatags'] = $ez_pages_meta;
                    break;
                default:
                    $other_meta_query = $db->Execute("SELECT * FROM " . TABLE_META_TAGS . " WHERE meta_tag_group='" . $meta_group . "'");
                    $other_meta = array();
                    while (!$other_meta_query->EOF) {
                        $page_name = $other_meta_query->fields['page'];
                        if ($page_name != 'home' && $page_name != 'site_wide') {
                            $removable = 'true';
                        } else {
                            $removable = 'false';
                        }
                        $other_meta[] = array('id' => $other_meta_query->fields['meta_tags_id'], 'name' => $page_name, 'title' => stripslashes($other_meta_query->fields['metatags_title']), 'keywords' => stripslashes($other_meta_query->fields['metatags_keywords']), 'description' => stripslashes($other_meta_query->fields['metatags_description']), 'language' => zen_get_language_icon((int) $other_meta_query->fields['language_id']), 'language_id' => $other_meta_query->fields['language_id'], 'removeable' => $removable);
                        $other_meta_query->MoveNext();
                    }
                    $respond['group'] = $meta_group;
                    $respond['metatags'] = $other_meta;
                    break;
            }
    }
}
echo json_encode($respond);