Bin will be removed on June 1, 2014 in favor of http://gist.github.com. Please save all your pastes before then. So long, and thanks for all the fish!×
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
<?
  //Check to see if admin session is set
  if (($_SESSION['users'] !="admin") && ($_SESSION['users'] !="user"))
    {
      header("Location: http://domains.10thpowermedia.com");
      exit();
        }
 
    $login=$_SESSION['userid'];
    require_once("functionlist.php");
    include_once("userroutines.php");
doconnect();
    $query="SELECT username, name from users where username='" . $_SESSION['userid'] . "'";
    $result = mysql_query($query) or die(mysql_error());
    $row = mysql_fetch_array($result);
    $date=date('m/j/y');
    $page_title=("10th Power Media Corp. - " . $date . " - User:  " . $row['name']);
    mysql_free_result($result);
 
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title><?php echo $page_title ?></title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<link href="css/intranetcss.css" rel="stylesheet" type="text/css" />
<!--[if lte IE 6]>
<link rel="stylesheet" href="css/iestyle.css" type="text/css" />
<![endif]-->
</head>
 
<body>
  <div id="main-wrap">
<div id="header"><?php echo $page_title ?></div>
 
<div class="clearfix"></div>
 
    <div id="left-nav-container">
        <?php include('includes/leftmenu.htm') ?>
        <hr />
<div align="center">
<h3>Search Options</h3>
   
    <p>Please type all or part of a domain name to access its information.</p>
 
    <form method="get" action="<?php $_SERVER['PHP_SELF'] ?>">
        <p><input name="domain" type="text" /></p>
        <p><input type="submit" name="search" value="Search" /></p>
    </form>
    <hr />
       
<table align="center" cellpadding="2" cellspacing="0" border="0" width="165">
  <tr>
    <td><div align="center"><a href="domains.php?alphadomain=a">A</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=b">B</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=c">C</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=d">D</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=e">E</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=f">F</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=g">G</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=h">H</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=i">I</a></div></td>
  </tr>
  <tr>
    <td><div align="center"><a href="domains.php?alphadomain=j">J</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=k">K</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=l">L</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=m">M</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=n">N</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=o">O</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=p">P</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=q">Q</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=r">R</a></div></td>
  </tr>
  <tr>
    <td><div align="center"><a href="domains.php?alphadomain=s">S</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=t">T</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=u">U</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=v">V</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=w">W</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=x">X</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=y">Y</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=z">Z</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=0">0</a></div></td>
  </tr>
  <tr>
    <td><div align="center"><a href="domains.php?alphadomain=1">1</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=2">2</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=3">3</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=4">4</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=5">5</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=6">6</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=7">7</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=8">8</a></div></td>
    <td><div align="center"><a href="domains.php?alphadomain=9">9</a></div></td>
  </tr>
</table>
 
<hr />
 
<p>Select a Category</p>
<form method="get" action="<?php $_SERVER['PHP_SELF'] ?>">
<select name="categories">
 
<?
  echo '<option value="NULL">Choose a Category</option>';
 
  $query="SELECT * FROM maincategories order by name asc";
  $result=mysql_query ($query);
  while ($row=mysql_fetch_array ($result, MYSQL_NUM))
    {
    echo '<option value="'. $row[0]. '">'. stripslashes($row[1]). '</option>';
    }
   
    //Complete the form
   
  echo '</select>';
  echo '<p><input type="submit" name="search2" value="Search" /></p>';
  echo '</form>';
  echo '</div>';
?>
 
    </div>
 
 
<div id="main-content-container">
    <div id="right-nav-container">
    <p style="margin-top:0;background-color:#ffcccc;color:#000000;text-align:center;">Page Options</p>
<?php
    if ($_SESSION['users'] == "admin")
    {
    echo "";
    }
 
?>
    <ul><li><a href="categorylist.php?categories=<?php echo $_GET['categories']; ?>">Category List</a></li></ul>
    </div>
<div id="content">
<?
doconnect();
    if(isset ($_GET['domain']) && isset($_GET['search']))
        {      
            $query="SELECT * from domains where name LIKE '%" . $_GET['domain'] . "%'";
 
            $result=mysql_query($query) or die(mysql_error());
            $row=mysql_fetch_array($result);
            $domain=$_GET['domain'];
                if ($row=mysql_fetch_array($result))
                    {              
                    echo "<table><tr><th style=\"width:200px;\">Domain</th><th style=\"width:150px;\">Status</th>";
                    echo "<th style=\"width:150px;\">Manager</th></tr>";
                   
                    do
                        {
                        $fullname=$row['domain'];
                        printf('<tr><td><a href="#' . $row['domain'] . '">' . $row['domain'] . '</a></td><td>' . $row['status'] . '</td><td>' . $row['manager'] . '<td></tr>');
                        }
                                       
                    while ($row=mysql_fetch_array($result));
                    echo "</table><br/>";
                    }
                    else
                        {
                        echo "<p style=\"color:#ff0000;font-weight:bold;font-size:14px;\">Please type in all or part of a domain name!</p>";
                        }
            }
                mysql_free_result($result);
        ?>
 
 
<?
doconnect();
    if(isset ($_GET['alphadomain']))
        {      
            $query="SELECT * from domains where name LIKE '" . $_GET['alphadomain'] . "%'";
 
            $result=mysql_query($query) or die(mysql_error());
            $row=mysql_fetch_array($result);
            $alphadomain=$_GET['alphadomain'];
 
        if(strlen($alphadomain)>0)
            {
            $result=mysql_query($query) or die(mysql_error());
 
                $num = mysql_num_rows($result);
 
                if ($num==1)
                {
                $row=mysql_fetch_array($result);
 
            echo "<h3>Domain Information</h3>";
            echo "<table>\n";
            echo '<tr><td width=\"300px\"><a href="#' . $row['alphadomain'] . '">' . $row['domain'] . '</a></td></tr>';
            echo "</table>\n";
 
 
                    echo "</form>";
 
                }
   
                else
                {      
            $query="SELECT * from domains where name LIKE '" . $_GET['alphadomain'] . "%'";
 
            $result=mysql_query($query) or die(mysql_error());
 
                if ($row=mysql_fetch_array($result))
                    {              
                    echo "<table><tr><th style=\"width:200px;\">Domain</th><th style=\"width:150px;\">Status</th>";
                    echo "<th style=\"width:150px;\">Manager</th></tr>";
                   
                    do
                        {
                        $fullname=$row['name'];
                        printf('<tr><td><a href="#' . $row['name'] . '">' . $row['name'] . '</a></td><td>' . $row['status'] . '</td><td>' . $row['manager'] . '<td></tr>');
                        }
                                       
                    while ($row=mysql_fetch_array($result));
                    echo "</table><br/>";
                    }
                    else
                        {
                        echo "<p style=\"color:#ff0000;font-weight:bold;font-size:14px;\">Please type in all or part of a domain name!</p>";
                        }
                mysql_free_result($result);
                }
            }
        }
        ?>
       
<?
doconnect();
    if(isset ($_GET['categories']) && isset($_GET['search2']))
        {      
            $query="SELECT * from domains where maincategory LIKE '" . $_GET['categories'] . "'";
 
            $result=mysql_query($query) or die(mysql_error());
            $row=mysql_fetch_array($result);
            $maincategory=$_GET['categories'];
 
        if(strlen($maincategory)>0)
            {
            $result=mysql_query($query) or die(mysql_error());
 
                $num = mysql_num_rows($result);
 
                if ($num==1)
                {
                $row=mysql_fetch_array($result);
 
            echo "<h3>Domain Information</h3>";
            echo "<table>\n";
            echo '<tr><td width=\"300px\"><a href="#' . $row['domain'] . '">' . $row['domain'] . '</a></td></tr>';
            echo "</table>\n";
 
 
                    echo "</form>";
 
                }
   
                else
                {      
            $query="SELECT * from domains where maincategory LIKE '" . $_GET['categories'] . "'";
 
            $result=mysql_query($query) or die(mysql_error());
 
                if ($row=mysql_fetch_array($result))
                    {              
                    echo "<table><tr><th style=\"width:200px;\">Domain</th><th style=\"width:150px;\">Status</th>";
                    echo "<th style=\"width:150px;\">Manager</th></tr>";
                   
                    do
                        {
                        $fullname=$row['name'];
                        printf('<tr><td><a href="#' . $row['name'] . '">' . $row['name'] . '</a></td><td>' . $row['status'] . '</td><td>' . $row['manager'] . '<td></tr>');
                        }
                                       
                    while ($row=mysql_fetch_array($result));
                    echo "</table><br/>";
                    }
                    else
                        {
                        echo "<p style=\"color:#ff0000;font-weight:bold;font-size:14px;\">Please type in all or part of a category name!</p>";
                        }
                mysql_free_result($result);
                }
            }
        }
        ?>
 
 
    </div>
    </div>
    <div class="clearfix"></div>
        <div id="footer"><?php include('includes/footer.htm') ?></span></div>
 
</div>
</body>
</html>