Dre4m Shell
Server IP : 127.0.0.2  /  Your IP : 18.117.229.13
Web Server : Apache/2.4.18 (Ubuntu)
System :
User : www-data ( )
PHP Version : 7.0.33-0ubuntu0.16.04.16
Disable Function : disk_free_space,disk_total_space,diskfreespace,dl,exec,fpaththru,getmyuid,getmypid,highlight_file,ignore_user_abord,leak,listen,link,opcache_get_configuration,opcache_get_status,passthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,php_uname,phpinfo,posix_ctermid,posix_getcwd,posix_getegid,posix_geteuid,posix_getgid,posix_getgrgid,posix_getgrnam,posix_getgroups,posix_getlogin,posix_getpgid,posix_getpgrp,posix_getpid,posix,_getppid,posix_getpwnam,posix_getpwuid,posix_getrlimit,posix_getsid,posix_getuid,posix_isatty,posix_kill,posix_mkfifo,posix_setegid,posix_seteuid,posix_setgid,posix_setpgid,posix_setsid,posix_setuid,posix_times,posix_ttyname,posix_uname,pclose,popen,proc_open,proc_close,proc_get_status,proc_nice,proc_terminate,shell_exec,source,show_source,system,virtual
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /var/www/html/admin/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME SHELL ]     

Current File : /var/www/html/admin/article-details.php
<?php
ob_start();
session_start();
require_once('session-check.php');
require_once('include/db-config.php');

$articleid = "";
if(isset($_POST['articleid']))
{
	$articleid = $_POST['articleid'];
}
else if(isset($_GET['id']))
{
	$articleid = $_GET['id'];
}
?>
<!DOCTYPE html> <HTML>
<HEAD>
<TITLE>Joel Levitt, maintenance management, maintenance management consulting, tpms</TITLE>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<link href="css/style.css" type="text/css" rel="stylesheet">
<style type="text/css">
table { color: #FFFFFF; font-family: Arial, Verdana }
.normal { background-color: #323232 }
.normalActive { background-color:#000000;}
</style>
<script language="javascript">
function viewcategory()
{
	document.forms["myform"].action = "article-details.php";
	document.forms["myform"].submit();
}
function submitform()
{
	document.forms["myform"].action = "article-edit-action2.php";
	document.forms["myform"].submit();
}
</script>

</HEAD>
<BODY BGCOLOR=#FFFFFF LEFTMARGIN=0 TOPMARGIN=0 MARGINWIDTH=0 MARGINHEIGHT=0>
<!-- ImageReady Slices (maintrainer_slice2.jpg) -->
<TABLE WIDTH="100%" BORDER=0 CELLPADDING=0 CELLSPACING=0 align="center">
	<?php include_once('include/include_header.php'); ?>
	<TR>
		<TD width="100%" align="center">
			<table border="0" cellpadding="0" cellspacing="0"  width="1100" align="center" class="body_bg" style="border-color:">
				<tr><td colspan="3" style="height:9px;"></td></tr>
                <tr>
                	<td style="width:9px;"></td>
                	<td class="content_bg" valign="top">
                    	<table border="0" cellpadding="0" cellspacing="0" width="95%" align="center">
							<tr>
								<td style="height:40px;">
									<?php
								   if(isset($_GET['r']))
								   if($_GET['r'] == '1')
								   {	
										echo "<font class='success-text'><b>You have successfully inserted new record.</b></font>";
								   }
								   else if($_GET['r'] == '2')
								   {	
										echo "<font class='success-text'><b>You have successfully updated the details.</b></font>";
								   }
								   else if($_GET['r'] == '0')
								   {	
										echo "<font class='error-text'><b>You have successfully deleted a record.</b></font>";
								   }
								   ?>
								</td>
							</tr>
							<tr>
								<td>
									<table border="0" cellpadding="0" cellspacing="0" width="100%">
										<tr>
											<td class="mainhead" valign="top" align="left" width="50%">SELECT ARTICLE TO VIEW/EDIT CATEGORIES</td>
											<!-- <td align="right" class="other_link" width="50%"><a href="article-mgt.php"><b>View Articles</b></a>&nbsp;&nbsp;|&nbsp;&nbsp;<a href="article-category.php"><b>View Article Category</b></a></a>
                                            </td> -->
										</tr>
										<tr><td height="10"></td></tr>
									</table>
                                    	<table border="0" cellpadding="0" cellspacing="0" width="100%">
                                        <tr>
                                        <td>
                                    	<form name="myform" id="myform" method="post" onSubmit="submitform()">
										<select onChange="viewcategory()" name="articleid" id="articleid">
                                        	<option value="0"></option>
                                            <?php
											$sql="select distinct ID, ArticleTitle from maintrainer_articles order by ArticleTitle";
											$result=mysqli_query($conn,$sql);
											$selected = "";
											
											while($row=mysqli_fetch_array($result))
											{
												if($row['ID'] == $articleid)
													$selected = ' selected ';
												else
													$selected = '';
												$ID = $row['ID'];
												$ArticleTitle = $row['ArticleTitle'];
												
												echo '<option value="'.$ID.'"'.$selected.' >'.$ArticleTitle.'</option>';
											}
											?>
                                            <option                          	
                                            </select>
											                                            
                                            </td>
                                            </tr>
                                            <tr>
                                            	<td>
                                                <?php
                                                $qry="select art_cat_id,category_name,list_order from maintrainer_articles_category where status = 1 order by list_order";
												$res=mysqli_query($conn,$qry);
												if($articleid != "") {
												?>
												<table border="0" cellpadding="0" cellspacing="0" class="normal_text">
                                                	<tr>
                                                    	<?php 
												    $i=0;
													
												    while($rw = mysqli_fetch_array($res))
													{ 
														
											            $art_cat_id = $rw['art_cat_id'];
														$category_name = $rw['category_name'];
														if($i==3)
														{
															echo "</tr>";
															echo '<tr><td style="height:5px;"></td></tr>';
															$i=0;
														}
														$qry1="select art_cat_id from maintrainer_articles_category_relation where article_id = ".$articleid." and art_cat_id = ".$art_cat_id;
														$res1=mysqli_query($conn,$qry1);
														$checked = "";
														if($rw1=mysqli_fetch_array($res1))
													    {
															$checked = "checked";
														}

													?>
                                                    <td style="padding-right:30px;"><input type="checkbox" name="catg[]" <?php echo $checked;?> value="<?php echo $art_cat_id;?>"><?php echo $category_name;?></td>
                                                    
                                                    <?php 
													$i++;}
													?>
                                                    <input type="hidden" name="articleID" id="articleID" value="<?php echo $articleid; ?>">
                                                    <tr>
                                                    	<td colspan="3" style="padding-top:10px;"><input type="submit" value="Update Categories Associated with Article" class="bttn"></td></tr>
                                                    </tr>
                                                    <?php
													 }?>      
                                                    
                                                </table>
</form>
                                                </td>
                                            </tr>
                                            </table>
								</td>
							</tr>
						</table>
                    </td>
                    <td style="width:9px;"></td>
				</tr>	
                <tr><td colspan="3" style="height:9px;"></td></tr>
			</table>
		</TD>
	</TR>
    <?php include_once('include/include_footer.php'); ?>
</TABLE>
<!-- End ImageReady Slices -->
</BODY>
</HTML>

Anon7 - 2022
AnonSec Team