$seo__url_dname = ''; $results = mysql_query("select * from product_category where id = '" . $_GET['id'] . "' and site = '" . SITE . "' limit 1", $dbh); if (mysql_num_rows($results)) { $category = mysql_fetch_assoc($results); $name = $category['name']; $seo__page_title = $category['page_title']; $seo__meta_kws = $category['meta_keywords']; $seo__meta_desc = $category['meta_description']; $seo__url_fname = $category['url_filename']; $seo__url_dname = $category['url_foldername']; } else { header($_SERVER['SERVER_PROTOCOL'] . " 404 Not Found"); include "404.php"; exit; } $newURL = DOCUMENT_BASE . '/' . SEO_format_url($_GET['id'], 'product', $name, $seo__url_fname, $seo__url_dname); $SEO_self_URL = (DOCUMENT_BASE == '' ? 'http://www.print-forms.com' : 'http://www.databusinesssystems.com') . $newURL; if (strpos($_SERVER['REQUEST_URI'], $newURL) === FALSE) { header($_SERVER['SERVER_PROTOCOL'] . ' 301 Moved Permanently'); header('Location: ' . $SEO_self_URL); // Output Standard HTML note of redirect. print '<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">' . "\n"; print '<html><head>' . "\n"; print '<title>301 Moved Permanently</title>' . "\n"; print '</head><body>' . "\n"; print '<h1>Moved Permanently</h1>' . "\n"; print '<p>The document has moved <a href="' . $SEO_self_URL . '">here</a></p>' . "\n"; print '</body></html>'; exit; } unset($newURL);
<?php require "inc/config.inc"; require "../inc/affiliate_process.inc"; if (isset($name)) { $newURL = DOCUMENT_BASE . '/' . SEO_format_url($aff_id, 'affiliate', $name, $seo__url_fname, $seo__url_dname); //Redirect to new URL $newURL = (DOCUMENT_BASE == '' ? 'http://www.print-4cp.com' : 'http://www.databusinesssystems.com') . $newURL; header($_SERVER['SERVER_PROTOCOL'] . ' 301 Moved Permanently'); header('Location: ' . $newURL); // Output Standard HTML note of redirect. print '<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">' . "\n"; print '<html><head>' . "\n"; print '<title>301 Moved Permanently</title>' . "\n"; print '</head><body>' . "\n"; print '<h1>Moved Permanently</h1>' . "\n"; print '<p>The document has moved <a href="' . $newURL . '">here</a></p>' . "\n"; print '</body></html>'; exit; } ?> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <title><?php if (isset($name)) { print $name; } else { print "Affiliate"; }
<title><?php echo $link['name']; ?> - Print-4cp</title> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <link rel="stylesheet" type="text/css" href="<?php echo DOCUMENT_BASE; ?> /style.css"> </head> <body onLoad="P7_TMopen()"> <?php include "inc/header.inc"; ?> <br> <div align="center"><iframe width="95%" height="400" src="<?php echo $link['url']; ?> " name="extlink" class="iframe" frameborder="1"></iframe></div> <?php include "inc/footer.inc"; if (SITE_NAME == 'Print-Forms') { print '<center><a href="' . DOCUMENT_BASE . '/' . SEO_format_url($_GET['id'], 'link', $name, $seo__url_fname, $seo__url_dname) . '" title="' . str_replace('"', '"', $name) . '" style="text-decoration:none;font-weight:normal;">'; print $name; print '</a></center>'; } ?> </body> </html>
} ?> .htm</td></tr> <tr><td class="field_title">URL Foldername</td><td><input type="text" name="url_foldername" size="40" value='<?php if (isset($error)) { print htmlspecialchars($_POST['url_foldername']); } elseif (isset($moddb)) { print htmlspecialchars($moddb->result('url_foldername')); } ?> '></td></tr> <tr><td class="field_title">Current URL</td><td><?php if (!isset($moddb)) { print 'N/A'; } else { print '/' . SEO_format_url($moddb->result('id'), 'sample', $moddb->result('name'), $moddb->result('url_filename'), $moddb->result('url_foldername')); } ?> </td></tr> <tr bgcolor="#990000"><td colspan="2" align="center"><input type="submit" value="Update"></td></tr> </table> </form> <?php } } if (!isset($add) && !isset($mod) || isset($success)) { if (isset($delete)) { $deldb = new dbi(); $deldb->query("select * from sample_category where site = '" . SITE . "' and type = 'sample' and type_id = '{$delete}'"); if ($deldb->numrows()) { print "<div align=\"center\" class=\"error\">Sample Category attached to Menu! Please remove from Menu first.</div><br>";
} ?> .htm</td></tr> <tr><td class="field_title">URL Foldername</td><td><input type="text" name="url_foldername" size="40" value='<?php if (isset($error)) { print htmlspecialchars($_POST['url_foldername']); } elseif (isset($mdb)) { print htmlspecialchars($mdb['url_foldername']); } ?> '></td></tr> <tr><td class="field_title">Current URL</td><td><?php if (!isset($mdb)) { print 'N/A'; } else { print '/' . SEO_format_url($mdb['id'], 'product', $mdb['name'], $mdb['url_filename'], $mdb['url_foldername']); } ?> </td></tr> <tr bgcolor="#990000"><td colspan="2" align="center"><input type="submit" value="Update"></td></tr> </table> </form> <?php } } if (!isset($_GET['add']) && !isset($_GET['mod']) || isset($success)) { if (isset($_GET['delete'])) { $results = mysql_query("select * from menu where site = '" . SITE . "' and type = 'product' and type_id = '" . $_GET['delete'] . "'"); if (mysql_num_rows($results)) { print "<div align=\"center\" class=\"error\">Product Category attached to menu! Can not delete!</div><br>"; } else {