Current File : /home/pacjaorg/public_html/kmm/components/com_djclassifieds/layouts/buynowform.php
<?php
/**
 * @package DJ-Classifieds
 * @copyright Copyright (C) DJ-Extensions.com, All rights reserved.
 * @license http://www.gnu.org/licenses GNU/GPL
 * @author url: http://dj-extensions.com
 * @author email contact@dj-extensions.com
 */

defined ('_JEXEC') or die('Restricted access');

$app = JFactory::getApplication();
$user = JFactory::getUser();

$item = $displayData['item'];
$Itemid = !empty($displayData['Itemid']) ? $displayData['Itemid'] : false;
$par = $displayData['par'];

?>

<div class="buynow_outer bn_quantity<?php echo $item->quantity; ?>">
	<div class="buynow_outer_in">
		<?php if($item->quantity>0){ ?>
			<form action="<?php echo JRoute::_('index.php'); ?>" method="post" name="buynowForm" id="buynowForm" class="form-validate" enctype="multipart/form-data">			
				<?php if($item->quantity==1){ ?>
					<input type="hidden" name="quantity" id="buynow_quantity" value="1" />
				<?php }else{ ?>
					<input type="text" class="buynow_quantity required validate-numeric" name="quantity" id="buynow_quantity" value="1" />								
					<label id="buynow_quantity-lbl" for="buynow_quantity">
						<?php echo JText::_('COM_DJCLASSIFIEDS_BUYNOW_FROM'); ?>
						<span id="quantity_limit"><?php echo $item->quantity; ?></span>	
						<?php if($item->unit_name){ ?>
							<span class="unit_name"><?php echo JText::_($item->unit_name); ?></span>
						<?php } ?>
					</label>
				<?php } ?>									
				<button class="button validate" type="submit" id="buynow_submit_b"<?php if($user->id && $user->id == $item->user_id){ echo ' disabled style="cursor: not-allowed"'; } ?>><?php echo JText::_('COM_DJCLASSIFIEDS_BUYNOW'); ?></button>
				<div class="clear_both"></div>
				<input type="hidden" name="item_id" value="<?php echo $item->id; ?>">
				<input type="hidden" name="cid" id="cid" value="<?php echo $item->cat_id; ?>">
				<input type="hidden" name="option" value="com_djclassifieds" />
				<input type="hidden" name="view" value="checkout" />
				<input type="hidden" name="Itemid" value="<?php echo $Itemid ? $Itemid : $app->input->get('Itemid'); ?>" />
			</form>
		<?php }else{ ?>				
			<?php echo JText::_('COM_DJCLASSIFIEDS_0_AVAILABLE').($item->unit_name ? ' '.$item->unit_name : ''); ?>
		<?php } ?> 								
	</div>
</div>
Site is undergoing maintenance

PACJA Events

Maintenance mode is on

Site will be available soon. Thank you for your patience!