skip to main content

{source}<?php
tab Trades Construction Websites: Win More Building Projectsuse Joomla\CMS\Uri\Uri;
tab Trades Construction Websites: Win More Building Projects// Get the current view
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projects$input = $app->input;
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projects$view = $input->get('view');
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projects$layout = $input->get('layout');
tab Trades Construction Websites: Win More Building Projects
tab Trades Construction Websites: Win More Building Projects// Get the page title
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projects$pageTitle = $document->getTitle();
tab Trades Construction Websites: Win More Building Projects
tab Trades Construction Websites: Win More Building Projects// Initialize category title variable
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projects$categoryTitle = '';
tab Trades Construction Websites: Win More Building Projects
tab Trades Construction Websites: Win More Building Projects// Check if the view is an article or a category
tab Trades Construction Websites: Win More Building Projectsif ($view === 'article' && isset($article)) {
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projects// Get the category id from the article object
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projects$categoryId = $article->catid;
tab Trades Construction Websites: Win More Building Projects
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projects// Load the category
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projects$category = \JCategories::getInstance('Content')->get($categoryId);
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projects$categoryTitle = $category->title;
tab Trades Construction Websites: Win More Building Projects} elseif ($view === 'category') {
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projects// Get the category id
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projects$categoryId = $input->getInt('id');
tab Trades Construction Websites: Win More Building Projects
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projects// Load the category
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projects$category = \JCategories::getInstance('Content')->get($categoryId);
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projects$categoryTitle = $category->title;
tab Trades Construction Websites: Win More Building Projects}
tab Trades Construction Websites: Win More Building Projects// 
tab Trades Construction Websites: Win More Building Projects// echo "<pre>";
tab Trades Construction Websites: Win More Building Projects// echo 'View: ' . htmlspecialchars($view) . '<br>';
tab Trades Construction Websites: Win More Building Projects// echo 'Layout: ' . htmlspecialchars($layout) . '<br>';
tab Trades Construction Websites: Win More Building Projects// echo "View later: " . htmlspecialchars($viewLater) . '<br>';
tab Trades Construction Websites: Win More Building Projects 

tab Trades Construction Websites: Win More Building Projects// $currentView = $app->get('current_view_for_sourcer', '');
tab Trades Construction Websites: Win More Building Projects// $bodyClassMenu= $app->get('bodyClassMenu', '');
tab Trades Construction Websites: Win More Building Projects 

tab Trades Construction Websites: Win More Building Projects// echo 'Current View Passed: '.$currentView.'<br>';
tab Trades Construction Websites: Win More Building Projects// echo 'Body Class Passed: '.$bodyClassMenu.'<br>';

tab Trades Construction Websites: Win More Building Projects 

tab Trades Construction Websites: Win More Building Projects// echo
"<br>";
tab Trades Construction Websites: Win More Building Projects// echo "Current view: " . htmlspecialchars($input->get('view'));

tab Trades Construction Websites: Win More Building Projects// echo 'Page Title: <h1>' . htmlspecialchars($pageTitle) . '</h1>';
tab Trades Construction Websites: Win More Building Projects// echo "</pre>";

tab Trades Construction Websites: Win More Building Projects//
tab Trades Construction Websites: Win More Building Projects// Output the titles and view with conditional HTML elements
tab Trades Construction Websites: Win More Building Projects
tab Trades Construction Websites: Win More Building Projectsecho '<div class="container">';
tab Trades Construction Websites: Win More Building Projectsecho '<div class="row">';
tab Trades Construction Websites: Win More Building Projectsecho '<div class="col-xs-12">';
tab Trades Construction Websites: Win More Building Projectsecho '<div class="holder">';
tab Trades Construction Websites: Win More Building Projects
tab Trades Construction Websites: Win More Building Projects//echo "blog/".$article->category_alias;
tab Trades Construction Websites: Win More Building Projects$varURL = Uri::getInstance()->toString();
tab Trades Construction Websites: Win More Building Projects$varURLParts = parse_url($varURL);
tab Trades Construction Websites: Win More Building Projects$varCategoryFlag = null;
tab Trades Construction Websites: Win More Building Projects
tab Trades Construction Websites: Win More Building Projectsforeach ($varURLParts as $component => $value) {
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projectsif ($component === 'path') {
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projects$value = substr($value, 0, strrpos($value, '/'));
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projects}
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projects$arrURLComponents[$component] = ucfirst($component) . ": $value";
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projects$arrURLValue[$component] = $value;
tab Trades Construction Websites: Win More Building Projects};
tab Trades Construction Websites: Win More Building Projects
tab Trades Construction Websites: Win More Building Projects//echo "<pre>";
tab Trades Construction Websites: Win More Building Projects//var_dump ($arrURLValue);
tab Trades Construction Websites: Win More Building Projects//echo "</pre>";
tab Trades Construction Websites: Win More Building Projects
tab Trades Construction Websites: Win More Building Projects//echo '<a href="'.htmlspecialchars($arrURLValue['path']).'">'.htmlspecialchars($arrURLValue['path']).'</a>';
tab Trades Construction Websites: Win More Building Projects
tab Trades Construction Websites: Win More Building Projectsif ($view === 'article') {
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projectsecho '<!--article--><div class="header"><a href="'.htmlspecialchars($arrURLValue['path']).'"> ' . htmlspecialchars($categoryTitle) . '</a></div>';
tab Trades Construction Websites: Win More Building Projects} elseif ($view === 'category') {
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projectsecho '<!--category--><h1 class="header"><a href="'.htmlspecialchars($arrURLValue['path']).'">' . htmlspecialchars($categoryTitle) . '</a></h1>';

tab Trades Construction Websites: Win More Building Projects} 
else {
tab Trades Construction Websites: Win More Building Projectstab Trades Construction Websites: Win More Building Projectsecho '<!--else--><h1 class="header">' . htmlspecialchars($categoryTitle) . '</h1>';
tab Trades Construction Websites: Win More Building Projects};
tab Trades Construction Websites: Win More Building Projects
tab Trades Construction Websites: Win More Building Projectsecho '</div>';
tab Trades Construction Websites: Win More Building Projectsecho '</div>';
tab Trades Construction Websites: Win More Building Projectsecho '</div>';
tab Trades Construction Websites: Win More Building Projectsecho '</div>';
?>
{/source}