/** * Contributors should be able to browse other users' private exhibits. */ public function testCanBrowseOtherUsersPrivateExhibits() { $this->dispatch('neatline'); $this->assertNotAction('forbidden'); // Should list other user's private exhibit. $this->assertXpath('//a[@class="neatline"][@href="' . public_url('neatline/show/slug1') . '"]'); }
public function getRecordUrl($action = 'show') { if ('show' == $action) { return public_url($this->slug); } return array('module' => 'catalog-search', 'controller' => 'index', 'action' => $action, 'id' => $this->id); }
public static function link_to($args, $attributes) { $text = isset($args[1]) ? $args[1] : $args[0]; $app_key = \Hook\Application\Context::getKey(); $public_url = public_url($args[0]) . '?X-App-Id=' . $app_key->app_id . '&X-App-Key=' . $app_key->key; return array('<a href="' . $public_url . '"' . html_attributes($attributes) . '>' . $text . '</a>', 'raw'); }
/** * Anonymous users should be able to browse public exhibits. */ public function testCanBrowsePublicExhibits() { $this->dispatch('neatline'); $this->assertNotAction('login'); // Should list public exhibit. $this->assertXpath('//a[@class="neatline"][@href="' . public_url('neatline/show/slug') . '"]'); }
/** * The simple search form should point to the Solr Search interceptor. */ public function testOverrideSearchFormAction() { $this->dispatch(''); // Get the interceptor URL. $url = public_url('solr-search/results/interceptor'); // Should override the default search action. $this->assertXpath("//form[@id='search-form'][@action='{$url}']"); }
/** * When the number of results exceeds the page length, the maximum number * of results and the pagination should be displayed. */ public function testPagination() { // Set public page length to 2. set_option('per_page_public', 2); $item1 = $this->_item(true, 'Item 1'); $item2 = $this->_item(true, 'Item 2'); $item3 = $this->_item(true, 'Item 3'); $item4 = $this->_item(true, 'Item 4'); $item5 = $this->_item(true, 'Item 5'); $item6 = $this->_item(true, 'Item 6'); // -------------------------------------------------------------------- // Page 1. $this->dispatch('solr-search'); // Should just list items 1-2. $this->assertXpath('//a[@href="' . record_url($item1) . '"]'); $this->assertXpath('//a[@href="' . record_url($item2) . '"]'); $this->assertNotXpath('//a[@href="' . record_url($item3) . '"]'); $this->assertNotXpath('//a[@href="' . record_url($item4) . '"]'); $this->assertNotXpath('//a[@href="' . record_url($item5) . '"]'); $this->assertNotXpath('//a[@href="' . record_url($item6) . '"]'); // Should link to page 2. $next = public_url('solr-search?page=2'); $this->assertXpath('//a[@href="' . $next . '"]'); $this->resetResponse(); $this->resetRequest(); // -------------------------------------------------------------------- // Page 2. $_GET['page'] = '2'; $this->dispatch('solr-search'); // Should just list items 3-4. $this->assertNotXpath('//a[@href="' . record_url($item1) . '"]'); $this->assertNotXpath('//a[@href="' . record_url($item2) . '"]'); $this->assertXpath('//a[@href="' . record_url($item3) . '"]'); $this->assertXpath('//a[@href="' . record_url($item4) . '"]'); $this->assertNotXpath('//a[@href="' . record_url($item5) . '"]'); $this->assertNotXpath('//a[@href="' . record_url($item6) . '"]'); // Should link to page 3. $next = public_url('solr-search?page=3'); $this->assertXpath('//a[@href="' . $next . '"]'); $this->resetResponse(); $this->resetRequest(); // -------------------------------------------------------------------- // Page 3. $_GET['page'] = '3'; $this->dispatch('solr-search'); // Should just list items 5-6. $this->assertNotXpath('//a[@href="' . record_url($item1) . '"]'); $this->assertNotXpath('//a[@href="' . record_url($item2) . '"]'); $this->assertNotXpath('//a[@href="' . record_url($item3) . '"]'); $this->assertNotXpath('//a[@href="' . record_url($item4) . '"]'); $this->assertXpath('//a[@href="' . record_url($item5) . '"]'); $this->assertXpath('//a[@href="' . record_url($item6) . '"]'); // Should link back to page 2. $prev = public_url('solr-search?page=2'); $this->assertXpath('//a[@href="' . $prev . '"]'); // -------------------------------------------------------------------- }
/** * Returns a link to a Neatline exhibit. * * @param NeatlineExhibit|null $exhibit The exhibit record. * @param string $action The action for the link. * @return string The URL. */ function nl_getExhibitUrl($exhibit, $action, $public = true) { $exhibit = $exhibit ? $exhibit : nl_getExhibit(); if (in_array($action, array('show', 'fullscreen'))) { $identifier = $exhibit->slug; } else { $identifier = $exhibit->id; } $route = 'neatline/' . $action . '/' . $identifier; $href = $public ? public_url($route) : url($route); return $href; }
public function store($filename, $data, $options = array()) { $storage_dir = storage_dir(true); $public_dir = storage_dir(false); // create directory if it doesn't exists if (!is_dir($storage_dir)) { mkdir($storage_dir, 0777, true); } if (file_put_contents($storage_dir . $filename, $data)) { return public_url($public_dir . $filename); } }
public function setUp() { parent::setUp(); $this->helper = new ExhibitBuilder_IntegrationHelper(); $this->helper->setUpPlugin(); $this->exhibit = $this->helper->createNewExhibit(true, false, 'Exhibit Title', 'Exhibit Description', 'Exhibit Credits', 'exhibit'); $this->assertTrue($this->exhibit->exists()); $maxPageCount = 3; $parentPage = null; for ($i = 1; $i <= $maxPageCount; $i++) { $exhibitPage = $this->helper->createNewExhibitPage($this->exhibit, $parentPage, 'Exhibit Page Title ' . $i, 'page' . $i, 1, 'text'); $this->assertTrue($exhibitPage->exists()); $parentPage = $exhibitPage; } $this->dispatch('exhibits/show/exhibit/page1/page2/page3'); $this->basePageUrl = public_url('exhibits/show/exhibit'); }
/** * Returns a link to a Neatline exhibit. * * @param NeatlineExhibit|null $exhibit The exhibit record. * @param string $action The action for the link. * @param string $text The link text. * @param array $props Array of properties for the element. * @return string The HTML link. */ function nl_getExhibitLink($exhibit, $action, $text, $props = array(), $public = true) { // Get exhibit and link text. $exhibit = $exhibit ? $exhibit : nl_getExhibit(); $text = $text ? $text : nl_getExhibitField('title'); // Get the exhibit identifier (`id` or `slug`). if (in_array($action, array('show', 'fullscreen'))) { $identifier = $exhibit->slug; } else { $identifier = $exhibit->id; } // Construct the exhibit route. $route = 'neatline/' . $action . '/' . $identifier; $props['href'] = $public ? public_url($route) : url($route); // Return the anchor tag. return '<a ' . tag_attributes($props) . '>' . $text . '</a>'; }
/** * Return a URI to an exhibit. * * @param Exhibit $exhibit If null, it uses the current exhibit. * @param ExhibitPage $exhibitPage A specific page to link to * @return string */ function exhibit_builder_exhibit_uri($exhibit = null, $exhibitPage = null) { if (!$exhibit) { $exhibit = get_current_record('exhibit'); } $exhibitSlug = $exhibit instanceof Exhibit ? $exhibit->slug : $exhibit; //If there is no page slug available, we want to build a URL for the summary page if (!$exhibitPage) { $uri = public_url(array('slug' => $exhibitSlug), 'exhibitSimple'); } else { $pagesTrail = $exhibitPage->getAncestors(); $pagesTrail[] = $exhibitPage; $options = array(); $options['slug'] = $exhibitSlug; foreach ($pagesTrail as $index => $page) { $adjustedIndex = $index + 1; $options["page_slug_{$adjustedIndex}"] = $page->slug; } $uri = public_url($options, 'exhibitShow', array(), true); } return $uri; }
private function _update_robots() { $serverUrlHelper = new Zend_View_Helper_ServerUrl(); $serverUrl = $serverUrlHelper->serverUrl(); $sitemap_uri = $serverUrl . public_url('sitemap.xml'); //update the site robots.txt file so it lists the sitemap // options for robots file $mapdef = "\n#START XML-SITEMAP-PLUGIN\n"; $mapdef .= "Sitemap: " . $sitemap_uri . "\n"; $mapdef .= "#END XML-SITEMAP-PLUGIN\n"; // open file $robotspath = BASE_DIR . "/robots.txt"; if (is_writeable($robotspath)) { $robotsfile = fopen($robotspath, 'a'); //write to file fwrite($robotsfile, $mapdef); //close file fclose($robotsfile); } else { echo "Robots.txt file is not writeable"; } }
public function testGetPageLinksForPublishedPages() { $pages = $this->db->getTable('SimplePagesPage')->findAll(); $this->assertEquals(1, count($pages)); $aboutPage = $pages[0]; $testPage1 = $this->_addTestPage('Test Title 1', 'testslug1', 'testtext1'); $testPage1->parent_id = $aboutPage->id; $testPage1->order = 1; $testPage1->is_published = 1; $testPage1->save(); $testPage2 = $this->_addTestPage('Test Title 2', 'testslug2', 'testtext2'); $testPage2->parent_id = $aboutPage->id; $testPage2->order = 2; $testPage2->is_published = 1; $testPage2->save(); $testPage3 = $this->_addTestPage('Test Title 3', 'testslug3', 'testtext3'); $testPage3->parent_id = $aboutPage->id; $testPage3->order = 3; $testPage3->is_published = 0; $testPage3->save(); $testPage4 = $this->_addTestPage('Test Title 4', 'testslug4', 'testtext4'); $testPage4->parent_id = $testPage2->id; $testPage4->order = 1; $testPage4->is_published = 0; $testPage4->save(); $testPage5 = $this->_addTestPage('Test Title 5', 'testslug5', 'testtext5'); $testPage5->parent_id = $testPage2->id; $testPage5->order = 2; $testPage5->is_published = 1; $testPage5->save(); $this->dispatch('/'); $actualNavLinks = simple_pages_get_links_for_children_pages($aboutPage->id, 'order', true); $this->assertEquals(2, count($actualNavLinks)); $expectedNavLinks = array(); $expectedNavLinks[] = array('label' => 'Test Title 1', 'uri' => public_url('testslug1')); $expectedNavLinks[] = array('label' => 'Test Title 2', 'uri' => public_url('testslug2'), 'pages' => array(array('label' => 'Test Title 5', 'uri' => public_url('testslug5')))); $this->assertEquals($expectedNavLinks, $actualNavLinks); }
public function generate($products) { $tpl = ''; if (!$products) { return $tpl; } $tpl .= '<ul>'; foreach ($products as $row) { $tpl .= '<li>'; if (isset($row['thumbnail']) && $row['thumbnail']) { $tpl .= '<a href="/i/' . $row['url'] . '" class="item">'; $tpl .= '<img class="item-img" src="' . public_url() . '/products/' . $row['thumbnail'] . '" alt="" />'; } else { $tpl .= '<a href="/i/' . $row['url'] . '" class="item none">'; } $tpl .= '</a>'; $tpl .= '<span class="item-price abs">' . $row['price'] . '<em>AED</em></span>'; $tpl .= '<a class="btn-lg abs addcart-btn" data-addcart-id="' . $row['id'] . '" data-addcart-img="' . public_url() . '/products/' . (isset($row['thumbnail']) && $row['thumbnail'] ? $row['thumbnail'] : 'default.png') . '"><span class="glyphicon glyphicon-shopping-cart"></span></a>'; $tpl .= '<p class="item-caption">' . $row['name'] . '</p>'; $tpl .= '</li>'; } $tpl .= '</ul>'; return $tpl; }
echo head(array('title' => $itemTitle, 'bodyclass' => 'items edit')); include 'form-tabs.php'; echo flash(); ?> <form method="post" enctype="multipart/form-data" id="item-form" action=""> <?php include 'form.php'; ?> <section class="three columns omega"> <div id="save" class="panel"> <?php echo $this->formSubmit('submit', __('Save Changes'), array('id' => 'save-changes', 'class' => 'submit big green button')); ?> <a href="<?php echo html_escape(public_url('items/show/' . metadata('item', 'id'))); ?> " class="big blue button" target="_blank"><?php echo __('View Public Page'); ?> </a> <?php echo link_to_item(__('Delete'), array('class' => 'delete-confirm big red button'), 'delete-confirm'); ?> <?php fire_plugin_hook("admin_items_panel_buttons", array('view' => $this, 'record' => $item)); ?> <div id="public-featured"> <?php
echo flash(); ?> <form method="post"> <?php include 'form.php'; ?> <section class="three columns omega"> <div id="save" class="panel"> <input type="submit" name="submit" class="big green button" id="save-changes" value="<?php echo __('Save Changes'); ?> " /> <a href="<?php echo html_escape(public_url('collections/show/' . metadata('collection', 'id'))); ?> " class="big blue button" target="_blank"><?php echo __('View Public Page'); ?> </a> <?php echo link_to_collection(__('Delete'), array('class' => 'big red button delete-confirm'), 'delete-confirm'); ?> <?php fire_plugin_hook("admin_collections_panel_buttons", array('view' => $this, 'record' => $collection, 'collection' => $collection)); ?> <div id="public-featured"> <div class="public">
<span class="item-caption abs">Jackets</span> </a> </li> <li> <a href="/c/test" class="item rel"> <img class="item-img abs" src="<?php echo public_url(); ?> /images/category/shorts.jpg" alt="" /> <span class="item-caption abs">Shorts</span> </a> </li> <li> <a href="/c/dresses" class="item rel"> <img class="item-img abs" src="<?php echo public_url(); ?> /images/category/dresses.jpg" alt="" /> <span class="item-caption abs">Dresses</span> </a> </li> </ul> <div class="clearfix"></div> </div> <div class="product-list float-li"> <h2 class="product-list-caption">Great offers</h2> <?php if (isset($offers_tpl) && $offers_tpl) { ?> <?php
</div> <div> <div> <h3> Metered Previews </h3> </div> <div class="element-intro font-small"> <p> Introduce new users to your content by setting a number of free views. </p> </div> </div> </div> <div class="features-body-two-element col-xs-12 col-sm-12 col-md-4 col-lg-4"> <div> <img src="<?php echo public_url() . "imgs/feature9.png"; ?> "> </div> <div> <div> <h3> Branding </h3> </div> <div class="element-intro font-small"> <p> Upload your logo to have it appear in the subscription prompt. </p> </div> </div> </div> </div> <!--Body 2 Row 3-->
/** * Get the path to the OpenLayers theme. * * @return string The theme path. */ function nl_getOpenLayersThemeDir() { return public_url('plugins/Neatline/views/shared/images/dark/'); }
<!-- Webmaster_howdy Body Page --> <section class="upper-body"> <div class="wmsign-upper-body upper-body"> <!-- Fixed navbar --> <div class="navbar navbar-default" role="navigation"> <div class="container nav-container"> <div class="navbar-header"> <span class="logo text-right"><a class="navbar-brand" href="<?php echo base_url(); ?> "><img src="<?php echo public_url() . "imgs/logo_white.png"; ?> " class="nav-logo"></a></span> </div> </div> </div> <div class="headline"> <div class="container"> <div class="headline-main-title"> <h1>Webmaster</h1> </div> <div class="headline-sub-title"> <h3>Only one step left</h3> </div> </div> </div> </div> </section>
echo public_url() . "js/jquery.leanModal.min.js"; ?> "></script> <script type="text/javascript" src="<?php echo public_url() . "js/vp_functions.js"; ?> "></script> <script> $(document).ready(function(){ }); </script> <link rel="stylesheet" href="http://netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.min.css" /> <link type="text/css" rel="stylesheet" href="<?php echo public_url() . "css/bootstrap.css"; ?> "/> <link type="text/css" rel="stylesheet" href="<?php echo public_url() . "css/viewpal.css"; ?> "/> <link type="text/css" rel="stylesheet" href="<?php echo public_url() . "css/popup-style.css"; ?> "/> </head> <body> <div class="container">
" class="btn home-btn btn-home-try">Try ViewPal Risk Free</a> <a href="<?php echo base_url() . "features"; ?> " class="btn home-btn btn-home-tour">Take a Tour</a> </span> </div> <div class="home-happy-girl"> <img src="<?php echo public_url() . "imgs/happy_girl.png"; ?> " class="happygirl-img-home" data-uk-scrollspy="{cls:'uk-animation-slide-bottom'}"> </div> <div class="home-img-container"> <img src="<?php echo public_url() . "imgs/home-graph.png"; ?> " class="graph-img-home" unselectable="on"> </div> </div> </div> <div class="home-section home-footer text-center"> <ul class="home-footer"> <li><a href="<?php echo base_url() . "features"; ?> ">Features</a></li> <li><a href="<?php echo base_url() . "whyviewpal"; ?> ">Why ViewPal</a></li>
/** * storage_url * @return string */ function storage_url() { return public_url(storage_dir(false)); }
} for ($i = 0, $n = sizeof($pricing); $i < $n; $i++) { $class = ''; if ($i % 2 == 0) { $class = 'style="background:#E7E7E8"'; } ?> <tr <?php echo $class; ?> > <td <?php echo $style; ?> ><a href="<?php echo public_url('reports/market/' . $pricing[$i]['marketplace'] . '/' . $prodId . '/' . date('Y-m-d', $pricing[$i]['dt']) . '/' . $url_modifier); ?> " target="_blank"><?php echo ucfirst($pricing[$i]['marketplace']); ?> </a></td> <td <?php echo $style; ?> ><?php echo date('m/d/Y', $pricing[$i]['dt']); ?> </td> <td <?php echo $style; ?>
<?php $pageTitle = __('Search Items'); echo head(array('title' => $pageTitle, 'bodyclass' => 'items advanced-search')); ?> <div class="container single-item"> <div class="content-block"> <a href="<?php echo public_url('/'); ?> ">← Return to homepage</a> <h1><?php echo $pageTitle; ?> </h1> <?php echo $this->partial('items/search-form.php', array('formAttributes' => array('id' => 'advanced-search-form'))); ?> </div> </div> <?php echo foot();
public function generatesExternalReport($id = -1) { /* * Loading libraries and helpers */ $this->load->library(array('rb', 'fpdf_gen')); $this->load->helper(array('date', 'utility')); /* * The request id is not set */ if ($id == -1) { echo "Parece que não foi especificado qual o id da Solicitação."; exit; } /* * Loading request */ $request = R::findOne('request', 'id=?', array($id)); /* * Request exists */ if ($request == null) { echo 'Parece que a solicitação não existe.'; exit; } /* * Creating PDF */ $pdf = new FPDI(); $pdf->addPage('L'); /* ********************************************************* * BEGIN - HEADER ********************************************************* */ $pdf->image(public_url('img/' . $this->config->item('system_report_logo')), 140, 5); $pdf->ln(14); $pdf->SetFont('Courier', 'B', 9); $pdf->Cell(0, 0, utf8_decode($this->config->item('system_name')), 0, 0, 'C'); $pdf->Ln(5); $pdf->SetFont('Courier', '', 9); $pdf->Cell(0, 0, utf8_decode("SOLICITAÇÃO DE INFORMAÇÃO"), 0, 0, 'C'); /* ********************************************************* * END - HEADER ********************************************************* */ $pdf->Ln(10); $pdf->SetFont('Courier', 'B', 9); $pdf->SetDrawColor(217, 217, 217); $pdf->SetFillColor(217, 217, 217); $pdf->Cell(0, 10, utf8_decode(' DADOS DA SOLICITAÇÃO'), 'LRTB', 0, 'L', true); $pdf->Ln(10); $pdf->Cell(24, 10, utf8_decode(' PROTOCOLO: '), 'LTB', 0, 'L', false); $pdf->SetFont('Courier', '', 9); $pdf->Cell(110, 10, utf8_decode($request->protocol), 'TBR', 0, 'L', false); $pdf->SetFont('Courier', 'B', 9); $pdf->Cell(32, 10, utf8_decode(' SOLICITADA EM: '), 'TB', 0, 'L', false); $pdf->SetFont('Courier', '', 9); $pdf->Cell(111, 10, utf8_decode(mdate('%d/%m/%Y', strtotime($request->createdAt))), 'TBR', 0, 'L', false); $pdf->Ln(10); $pdf->SetFont('Courier', 'B', 9); $pdf->Cell(24, 10, utf8_decode(' SITUAÇÃO: '), 'LB', 0, 'L', false); $pdf->SetFont('Courier', '', 9); $pdf->Cell(253, 10, utf8_decode(status_text($request->status)), 'TBR', 0, 'L', false); $pdf->Ln(10); $pdf->SetFont('Courier', 'B', 9); $pdf->Cell(0, 10, utf8_decode(' SOLICITAÇÃO: '), 'LR', 0, 'L', false); $pdf->Ln(8); $pdf->SetFont('Courier', '', 9); $pdf->MultiCell(0, 5, utf8_decode(' ' . $request->request), 'LR', 'L', false); $pdf->Cell(0, 4, '', 'LR', 0, 'L', false); $pdf->Ln(4); $pdf->SetFont('Courier', 'B', 9); $pdf->Cell(0, 10, utf8_decode(' TRÂMITAÇÃO'), 'LRTB', 0, 'L', true); $pdf->Ln(10); $pdf->SetFont('Courier', '', 9); $statuses = R::find('status', ' request_id = ? ORDER BY created_at ASC ', array($request->id)); if (!count($statuses)) { $pdf->Cell(0, 10, utf8_decode(' Nenhuma trâmitação ainda'), 'LRB', 0, 'L', false); } else { foreach ($statuses as $s) { $pdf->SetFont('Courier', 'B', 9); $pdf->Cell(0, 10, utf8_decode(' ' . status_text($s->type) . ' [' . date('d/m/Y', strtotime($s->createdAt)) . ']'), 'LR', 0, 'L', false); $pdf->Ln(10); $pdf->SetFont('Courier', '', 9); $pdf->MultiCell(0, 5, utf8_decode(' ' . $s->response), 'LRB', 'L', false); } } $pdf->Ln(10); $pdf->Output(); }
/** * Anonymous users should not be able to browse private exhibits. */ public function testCannotBrowsePrivateExhibits() { $this->dispatch('neatline'); // Should not list private exhibit. $this->assertNotXpath('//a[@class="neatline"][@href="' . public_url('neatline/show/slug') . '"]'); }
public function GeolocationConvertOverlayJsonForUse($jsonMapOverlays = false) { if (!$jsonMapOverlays) { $jsonMapOverlays = get_option("geolocation_map_overlays"); } if (!$jsonMapOverlays) { $jsonMapOverlays = "[]"; } $mapOverlays = json_decode($jsonMapOverlays); $result = array(); $regExIdx = "^\\d+\$"; // decimal number of at least one digit $regExLatLng = "^(?:\\+|-)?\\d+(?:.\\d+)?\$"; // (+|-)1234(.1234) as latitude or longitude coordinate $regExProtoUrl = "^[a-z]+(?:s)?://.*\$"; // image URL starts with a protocol, like http://, https:// etc. foreach ($mapOverlays as $mapOverlay) { $idx = $identifier = $imgUrl = $latNorth = $latSouth = $lngEast = $lngWest = $groupTitle = false; foreach (array_keys($mapOverlay) as $key) { $mapOverlay[$key] = trim($mapOverlay[$key]); } if (isset($mapOverlay[0]) and preg_match("({$regExIdx})", $mapOverlay[0])) { // 1st: numerical index $idx = intval($mapOverlay[0]); } else { break; } if (isset($mapOverlay[1]) and $mapOverlay[1]) { $identifier = $mapOverlay[1]; } else { break; } // 2nd element: identifier string if (isset($mapOverlay[2]) and $mapOverlay[2]) { $imgUrl = $mapOverlay[2]; } else { break; } // 3rd element: image URL string if (isset($mapOverlay[3]) and preg_match("({$regExLatLng})", trim($mapOverlay[3]))) { // 4th element: northern latitude $latNorth = trim($mapOverlay[3]); } else { break; } if (isset($mapOverlay[4]) and preg_match("({$regExLatLng})", trim($mapOverlay[4]))) { // 5th element: southern latitude $latSouth = trim($mapOverlay[4]); } else { break; } if (isset($mapOverlay[5]) and preg_match("({$regExLatLng})", trim($mapOverlay[5]))) { // 5th element: eastern longitude $lngEast = trim($mapOverlay[5]); } else { break; } if (isset($mapOverlay[6]) and preg_match("({$regExLatLng})", trim($mapOverlay[6]))) { // 7th element: western longitude $lngWest = trim($mapOverlay[6]); } else { break; } if (isset($mapOverlay[7])) { $groupTitle = trim($mapOverlay[7]); } if (floatval($latNorth) <= floatval($latSouth) or floatval($lngWest) >= floatval($lngEast)) { break; } if (!preg_match("({$regExProtoUrl})", $imgUrl)) { $imgUrl = ltrim($imgUrl, "/"); $imgUrl = public_url("mapoverlays/{$imgUrl}"); $imgUrl = $_SERVER["REQUEST_SCHEME"] . "://" . $_SERVER["HTTP_HOST"] . $imgUrl; } $result[$idx] = array("identifier" => $identifier, "imgUrl" => $imgUrl, "latNorth" => $latNorth, "latSouth" => $latSouth, "lngEast" => $lngEast, "lngWest" => $lngWest, "groupTitle" => $groupTitle); } if ($result) { $result = array("fulldata" => $result, "jsSelect" => array(-1 => __("Select Below")), "jsData" => json_encode($result)); foreach ($result["fulldata"] as $idx => $overlay) { $groupTitle = $overlay["groupTitle"] ? $overlay["groupTitle"] : __("[n/a]"); if (!isset($result["jsSelect"][$groupTitle])) { $result["jsSelect"][$groupTitle] = array(); } $result["jsSelect"][$groupTitle][$idx] = $overlay["identifier"]; } } // echo "<pre>" . print_r($result["jsSelect"],true) . "</pre>"; die(); // echo "<pre>" . print_r($result,true) . "</pre>"; die(); return $result; }
<div class="navbar-header"> <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#primary-navigation"> <span class="sr-only">Menu</span> <span class="icon-bar"></span> <span class="icon-bar"></span> <span class="icon-bar"></span> </button> </div> <div class="collapse navbar-collapse" id="primary-navigation"> <?php echo public_nav_main_bootstrap(); ?> <form class="navbar-form navbar-right" role="search" action="<?php echo public_url(''); ?> search"> <?php echo search_form(array('show_advanced' => false)); ?> </form> </div> </div> </nav> </header> --> <header id="header-main"> <div class="stripe-slope"></div> <div class="container"> <div class="row"> <div class="col-lg-5 col-md-3 col-xs-5">
echo public_url('css/base.admin.min.css'); ?> "> </head> <body> <div class="top-bar"> <div class="container"> <div class="row"> <div class="col-lg-12"> <a href="<?php echo base_url('index.php/dashboard'); ?> "> <img src="<?php echo public_url('img/logofooter.png'); ?> "> <span>ASSEMBLEIA LEGISLATIVA <br> DO RIO GRANDE DO NORTE</span> </a> </div> </div> </div> </div> <!-- END - DIV.TOP-BAR -->