Search Results

Search found 4341 results on 174 pages for 'zend navigation'.

Page 52/174 | < Previous Page | 48 49 50 51 52 53 54 55 56 57 58 59  | Next Page >

  • Multiple View application and Navigation Bar

    - by byronh
    Hi. I'm working in a iphone view-based application. The application works this way: First view is a welcome view with buttons for load other views. Second view is a map that shows the location using gps. Third view is a search engine that loads some information to show on the map and on a list (This has two button to load map or table). Fourth view is a table view that shows the results and then loads the detail on another view and load a web site on another view. My problem is with this view, because i don't know how can implement a navigation bar in this view that loads the detail and the web view. Thanks for your help. Byron H.

    Read the article

  • Drupal Navigation Conundrum

    - by Vecta
    I'm attempting to set up navigation withing a Drupal site and am having a bit of trouble. I'm trying to have a series of pages that each have a set number of sub-pages. These pages will need to link to one another. All pages will contain similar content. For instance: Page 1 will have sub-pages a, b, c, d, e, and f all with content related to the topic of page 1 Page 2 will have sub-pages a, b, c, d, e, and f with content related to the topic of page 2 I'd like these links to appear in a horizontal nav bar on each page. Is it possible to accomplish this using the book module? I've also read some information about the taxonomy menu module that sounds promising, but I'm not really sure how that would work. What route should I look into? Thanks for any input!

    Read the article

  • How do I link a Navigation Menu to an already existing Sitemap

    - by JMK
    I am just beginning my journey into web development and I have a very basic question, but I am none the less stumped. I have setup a new ASP.NET Empty Web Application. In this application, I have created a few *.aspx pages and a sitemap called 'Web.sitemap'. I have placed a SiteMapPath control onto my Master page and, with no further configuration, this detected my Web.sitemap and displays the location of the page on any *.aspx page which derives from the master page. However, whenever I add a Navigation Menu, this doesn't happen. When I bring up the Menu Tasks dialogue box, I can't select this from the Choose Data Source dropdown, my only option is to choose <New data source...> which brings up the Data Source Configuration Wizard, and from this I can create a new Site Map, however I want to use the already existing one. How do I go about this? Thanks

    Read the article

  • Navigation properties not set when using ADO.NET Mocking Context Generator

    - by olenak
    I am using ADO.NET Mocking Context Generator plugin for my Entity Framework model. I have not started on using mocks yet, just trying to fix generated entity and context classes to make application run as before without exceptions. I've already fixed T4 template to support SaveChanges method. Now I've got another problem: when I try to access any navigation property it is set to null. All the primitive fields inherited from DB table are set and correct. So what I am doing is the following using (var context = MyContext()) { var order = context.Orders.Where(p => p.Id == 7); var product = order.Products; } in this case product is set to null. But that was not a case while using default code generator, it used to return real product object. Thanks ahead for any suggestions!

    Read the article

  • Design advices for quick navigation between view

    - by Thomas Joulin
    Usually, when a View requires a lot of bindings, or some UI Elements like a Bing Map, it takes a "while" to load (like between half a second and a second). I don't want a delay between a "tap" action (like tapping an element on a ListBox) and the navigation action (displaying a new page). I don't mind displaying the page progressively. For example, for a Bing Map, I don't mind displaying a black page with only a title, and a second later, having the Map appear. What are the best practices ? It could post a sample if i'm not clear enough

    Read the article

  • jQuery changing css on navigation when div # scrolls into view

    - by Jonny Wood
    I'm looking to recreate the effect used on this site: http://www.brizk.com/ The site uses one large page that scrolls down. As you scroll down and pass different sections the menu navigation on the left changes css class to "current" as the corresponding div comes into view. I presume this can be done with jQuery using $(window).height(); I'm fairly new to jQuery and what I want to write is something like this (in laymans terms): Get height of browser window – if div#content1 is 100px from top and/or 200px from bottom change menu a#link1 to '.current' – else remove .current from all menu a links ... and repeat for 4 different content divs. Can anyone point me in the right direction..? Thanks.

    Read the article

  • UINavigationController doesn't fully push view and only changes the Navigation toolbar to the next v

    - by user284757
    So I have an iPhone application that utilizes a UINavigationController for setting up the views. When the application first starts, it presents the user with a UITableViewController and the user can select an item and it will push another view. Now I have it set so that my app remembers the user's last selection and automatically selects it and loads the correct view controller. The only problem is that I am experiencing a really weird glitch when I load the next view automatically.. When the view is pushed, the navigation toolbar will change so that a back button directed to the previous view is showing but it won't display the next view. It will instead keep showing the table view and I can interact with it as well. I can press the back button and it will change the toolbar back and the tableview is still shown. Then when I select an item it loads the view just fine. Thanks for the help.

    Read the article

  • Problem in building a tab bar inside navigation controller

    - by Heba
    Hello Everyone! I am really frustrated and I rally hope that you will help me to solve this problem! I'm trying to build a tab bar inside a navigation controller. I used this template provided by WiredBob. My problem is that I want to add more bar items to the tab bar, but I keep getting crash! From the log: 2010-05-24 00:15:43.469 NavTab[9315:207] * Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: '-[UITableViewController loadView] loaded the "AnnView" nib but didn't get a UITableView.' Also, I tried to fix the size of the a view in IB to fit in with the tab bar, but I couldn't! It was unchangeable. Thanks in advance :-)

    Read the article

  • php help hiding navigation with cookie

    - by user342391
    I have these tabs on my navigation: <li<?php if ($thisPage=="Customers") echo " class=\"current\""; ?>><a href="/customers/">Customers</a></li> <li<?php if ($thisPage=="Trunks") echo " class=\"current\""; ?>><a href="/trunks/">Trunks</a></li> <li<?php if ($thisPage=="Settings") echo " class=\"current\""; ?>><a href="/settings/">Settings</a></li> and I only want to show them when admin is logged in: if ($_COOKIE['custid'] == "admin") { echo "Customers"; echo "Trunks"; echo "Settings"; } How can I combine the two of these scripts???

    Read the article

  • Gmail 3-legged OAuth access -- Zend_Mail_Protocol_Exception

    - by tchaymore
    I'm trying to access Gmail by using three-legged Oauth PHP code provided by Google ('google-mail-xoauth-tools') here: http://code.google.com/apis/gmail/oauth/code.html. I have my domain registered and everything seems to go fine with OAuth, but after I authorize access I get this error: Fatal error: Uncaught exception 'Zend_Mail_Protocol_Exception' with message 'cannot connect to host; error = Connection refused (errno = 111 )' in /home/tchaymor/public_html/gmail/Zend/Mail/Protocol/Imap.php:100 Stack trace: #0 /home/tchaymor/public_html/gmail/Zend/Mail/Protocol/Imap.php(61): Zend_Mail_Protocol_Imap->connect('imap.gmail.com', '993', true) #1 /home/tchaymor/public_html/gmail/three-legged.php(170): Zend_Mail_Protocol_Imap->__construct('imap.gmail.com', '993', true) #2 {main} thrown in /home/tchaymor/public_html/gmail/Zend/Mail/Protocol/Imap.php on line 100 This is my first time using OAuth with any Google products, so it could be something totally brainless I'm missing. Any suggestions would be most welcome (as suggestions for easier alternatives). I'm more on the designer rather than coder end, so the simpler the better.

    Read the article

  • Module autoloader in ZF

    - by ChrisRamakers
    The manual on Zend_Application_Module_Autoloader states the following: When using module bootstraps with Zend_Application, an instance of Zend_Application_Module_Autoloader will be created by default for each discrete module, allowing you to autoload module resources. Source: http://framework.zend.com/manual/zh/zend.loader.autoloader-resource.html#zend.loader.autoloader-resource.module This requires me to create an empty bootstrap class for each of my modules or else resource autoloading per module won't work with the build-in autoloader. Now I have two questions What is a discrete module? Is there a way to have this resource autoloader registered by default for each module without the need to create a bootstrap file for each module? I want it available in each module and creating so many empty bootstrap classes is something i'd rather prevent.

    Read the article

  • Jqgrid: navigation based on the selected row

    - by bsreekanth
    Hello, I was trying to enable navigation based on a selected row. So, the user select a row from jQgrid, and when press the show (is there a show button for the grid, I saw edit, add etc), it needs to go to a new page based on the url (part of the row). $(document).ready(function () { function getLink() { // var rowid = $("#customer_list").jqGrid('getGridParam', 'selrow'); var rowid = $("#customer_list").getGridParam('selrow'); var MyCellData = $("#customer_list").jqGrid('getCell', rowid, 'dataUrl'); return MyCellData; } $("#customer_list").jqGrid({ url:'mytestList', editurl:'jq_edit_test', datatype: "json", colNames:['Call Id','Title','dataUrl'], colModel:[ {name:'callId', width:80, search:false }, {name:'title', width:200, sortable:false }, {name:'dataUrl',hidden:true} ], rowNum:10, sortname:'lastUpdated', sortorder: 'desc', pager:'#customer_list_pager', viewrecords: true, gridview: true }).navGrid('#customer_list_pager', {add:true,edit:true,del:false,search:true,refresh:true}, {closeAfterEdit:true, afterSubmit:afterSubmitEvent }, // edit options {addCaption:'Create New something', afterSubmit:afterSubmitEvent, savekey:[true,13]}, // add options {afterSubmit:afterSubmitEvent} // delete options ); $("#customer_list").jqGrid('filterToolbar'); }); so, the url is passed for each row as dataUrl. I'm trying to read it and set to the button. Whn debug through firebug, the rowid was 223 (there were only 12 rows in the grid), and the cell value is empty. Currently the button is kept outside the grid, but it may better to be it part of the vavGrid thanks.

    Read the article

  • Adding a navigation bar to a web view in a tab bar app

    - by Henrik Erlandsson
    I've built the tab bar application in IB, with three tabs. The third tab happily displays a UIWebview where you can browse. The only thing missing is a back button, as not all web pages supply such a link. I need a navigation bar hooked up properly to the correct classes. I'm still a bit unsure about exactly how the hierarchy should look in interface builder and how to hook it up properly. Currently, the third tab is hooked up to a referencing outlet called 'webnews' in the class 'thirdviewcontroller', and the UIWebView (under a normal IUView in the hierarchy, which in turn is under the third tab bar controller) is connected to the webnews outlet. How do I make the navbar control the webview, and do I add code to the thirdviewcontroller.m that lets the navbar on the view control the webview 'back' function? What do I hook up as the delegate for it? Currently I have an app delegate, but that's hooked up to the tab bar. I'm not really after specific code as much as a general 'how it works' clue :) (Unless I can just add the navbar dynamically to the functioning app... but I don't think addSubView on viewWillAppear {} in thirdviewcontroller.m will create the proper functionality?) If I were to guess at the simplest solution, I'd guess create a navbarcontroller.h/.m, slap a navbar on the view in IB, connect the third tab to navbarcontroller, connect the navbar to the webview (?) and move the webnews outlet to navbarcontroller.h, and connect the webview to it. But I don't quite have the nerve to try, better to ask advice first.

    Read the article

  • Wordpress dynamic navigation function for highlighting single post tabs

    - by user269959
    I am trying to write a function that i can reuse in my wordpress themes that will allow me to build robust dynamic navigation menus. Here is what i have so far: function tab_maker($page_name, $href, $tabname) { //opens <li> tag to allow active class to be inserted if tab is on proper page echo "<li"; //checks that we are on current page and highlights tab as active if so if(is_page($page_name)){ echo " class='current_page_item'>"; } //closes <li> tab if not active else { echo ">"; } //inserts the link as $href and the name of the tab to appear as $tabname then closes <li> echo "<a href=$href>$tabname</a>"; echo "</li>"; } This code works as expected except i cant enable it to highlight for a single blog post as the page names are dynamic. I know about the wordpress function is_single() which ive used to implement this feature in previous nav menus but i cant find a way to integrate it into this function. appreciate any help!

    Read the article

  • label as dynamic navigation

    - by KareemSaad
    I Made label to had value from database and linked it . but the problem was it had only one value and i want it keep value when navigation thought site as. xyz.... this is my code < if (Request.QueryString["Category_Id"] != null) { Banar.ImageUrl = "Handlers/Banner.ashx?Category_Id=" + Request.QueryString["Category_Id"] + ""; using (SqlConnection conn = Connection.GetConnection()) { SqlCommand cmd = new SqlCommand(); cmd.Connection = conn; cmd.CommandType = CommandType.StoredProcedure; cmd.CommandText = "Navcategory"; cmd.Parameters.Add(Parameter.NewInt("@Category_Id", Request.QueryString["Category_Id"])); SqlDataReader dr = cmd.ExecuteReader(); if (dr.Read()) { LblNavigaton.Visible = true; LblNavigaton.Text = dr[i].ToString(); NavHref.HRef = "ListView.aspx?Category_Id=" + Request.QueryString["Category_Id"] + ""; } } } else if (Request.QueryString["ProductCategory_Id"] != null) { Banar.ImageUrl = "Handlers/ProCatBanner.ashx?ProductCategory_Id=" + Request.QueryString["ProductCategory_Id"] + ""; using (SqlConnection conn = Connection.GetConnection()) { SqlCommand cmd = new SqlCommand(); cmd.Connection = conn; cmd.CommandType = CommandType.StoredProcedure; cmd.CommandText = "NavProductcategory"; cmd.Parameters.Add(Parameter.NewInt("@ProductCategory_Id", Request.QueryString["ProductCategory_Id"])); SqlDataReader dr = cmd.ExecuteReader(); if (dr.Read()) { LblNavigaton.Visible = true; LblNavigaton.Text = dr["Name"].ToString(); NavHref.HRef = "ListView.aspx?ProductCategory_Id=" + Request.QueryString["ProductCategory_Id"] + ""; } else { LblNavigaton.Visible = true; LblNavigaton.Text = Page.Title; } }

    Read the article

  • Custom UIView using CALayers disappears after 180º rotation or navigation controller pop

    - by Steve Madsen
    I have a created a custom UIView subclass that is exhibiting some strange behavior. It is a spinning wheel selector, and for performance reasons it is drawn entirely into two CALayer instances. The bottom layer is the wheel itself, which is rotated using setAffineTransform: according to touches. The top layer is eye candy. drawRect: is fairly simple. If the control hasn't been drawn yet (or it's been invalidated), it calls a method that creates the images and assigns them to the layer contents property. - (void) drawRect:(CGRect)rect { if (imageLayer == nil) { [self drawIntoImageLayer]; } [self updateWheelRotation]; } When the view controller using this view first appears, everything is fine. There are two instances where the view completely disappears, however: If the device is rotated a full 180°. After a view controller is popped off the navigation stack and the view becomes visible again. drawRect: is not called either time. Interestingly enough, it IS called after a 90° orientation change, and that causes the view to re-appear. How can I ensure that a custom view using CALayers is redrawn properly in these situations?

    Read the article

  • Wizard style navigation, dismissing a view and showing another one

    - by Robin Jamieson
    I'm making a set of screens similar to a wizard and I'd like to know how to make a view dismiss itself and its parent view and immediately show a 'DoneScreen' without worrying about resource leaks. My views look like the following: Base -> Level1 -> DoneScreen -> Level2 -> DoneScreen The Level1 controller is a navigation controller created with a view.xib and shown with [self presentModalViewController ...] by the Base controller. The Level1 controller is also responsible for creating the 'DoneScreen' which may be shown instead of the Level2 Screen based on a certain criteria. When the user taps a button on the screen, the Level1 controller instantiates the the Level2 controller and it displays it via [self.navigationController pushViewController ..] and Level2 controller's view has a 'Next' button. When the use hits the 'Next' button in the Level2 screen, I need to dismiss the current Level2's view as well as the Level1's view and display the 'DoneScreen', which would have been created and passed in to the Level2 controller from Level1. (partly to reduce code duplication, and partly to separate responsibilities among the controllers) In the Level2 controller, if I show the 'DoneScreen' first and dismiss itself with [self.navigationController popViewControllerAnimated:YES]; then the Level1 controller's modal view is still present above the 'Base' but under the Done screen. What's a good way to clear out all of these views except the Base and then show the 'DoneScreen'? Any good suggestions on how to get this done in a simple but elegant manner?

    Read the article

  • Problem pushing multiple view controllers onto navigation controller stack

    - by Jim
    Hi, I am trying to push three view controllers onto the navigation controller. [self.navigationController pushViewController:one animated:YES]; [self.navigationController pushViewController:two animated:YES]; [self.navigationController pushViewController:three animated:YES]; The desired behavior is that view three will show, and when the back button is pressed it will go to view two and then to view one... What actually happens is that view one is visible and pressing back goes to view two and then back again it goes to view one. Which is to say that view one is shown instead of view three. Very strangely, looking at the viewController array of the navigationController after the calls above show the right entries, and looking at the visibleViewController property shows that it has view three in it... even though view one is visible. If i navigate to a sub view from the visible view one (that shows in the place of view three) and press back from that sub view... it goes to view three. It looks like it is showing view one, but knows it is on view three... I am completely confused... any ideas? Jim

    Read the article

  • Sencha touch 2/ app workflow with navigation view

    - by eplatonov
    I am trying to understand how can I implement the same functionality which provides navigation view in sencha touch 2, but .... Each item of the 'Ext.NavigationView' component should have it's own unique set of 'navigationBar' elements. I mean set of buttons, for example. I know that I can do something like this: this.getMain().getNavigationBar().rightBox.removeAll(); this.getMain().getNavigationBar().rightBox.add(this.getSettingButton()); //where 'getSettingButton' predefined by me a button And do this action each time when 'push' event happens (clear 'navigationBar' and add appropriate set of buttons) Of course, I even can implement 'Ext.Panel' with 'layout: card' and set of 'Ext.panel' elements in the 'items' property, each of which will be have unique 'toolbar'. To control the behavior I can use 'setActiveItem' method. But, I think each of these approaches is a bit weird, isn't it? I expected that would be much more natural approach to implement it. Most likely I don't know what I need. Confirm my doubts. What is the best way to do it.

    Read the article

  • Top navigation link in Magento that I can't get rid of

    - by Chris Baily
    I'm working on a new theme for an existing Magento installation, and I've got a rogue link. The last guy apparently decided to hard code a link to the AW Blog extension he was using in the top navigation. See here: derm2go.com - link is "articles". I'm getting rid of AW Blog in favor of an integrated wordpress install, but when I uninstall AW Blog, the site breaks (everything after the nav dissapears) and I get this error in my logs: 2011-11-19T08:56:19+00:00 ERR (3): Warning: include() [function.include]: Failed opening 'Mage/Blog/Helper/Data.php' for inclusion (include_path='/chroot/home/dermtwog/derm2go.com/html/app/code/local:/chroot/home/dermtwog/derm2go.com/html/app/code/community:/chroot/home/dermtwog/derm2go.com/html/app/code/core:/chroot/home/dermtwog/derm2go.com/html/lib:.:/usr/share/pear') in /chroot/home/dermtwog/derm2go.com/html/lib/Varien/Autoload.php on line 93 I've searched everywhere, I can think of that might effect the nav menu, and I don't know where the link is coming from - it's not in the CMS/static blocks, its not in any of the default template files on the server (I deleted and reinstalled all of them) and it's showing up even when I change templates, so it's probably not in on the sub themes. Does anyone out there know of other files it could be hiding in? I'm assuming the last guy did a quick and dirty hack somehow - and maybe messed with core files? Would really rather not have to do a full reinstall.

    Read the article

  • Assign click event to addon icon on navigation bar

    - by Charsee
    We have created a chrome extension for our app. Where we call a METHOD from a "js file" on CLICK event of the "extension icon" placed on the navigation bar. For this we use message passing between the app.js (file containing the METHOD to be called on icon click) and background.html (using a js file included in this html). The script used to pass message is:(from background.html) chrome.browserAction.onClicked.addListener(function (tab) { chrome.tabs.sendMessage(tab.id, "showPopup"); }); and to listen the message :(in app.js) chrome.extension.onMessage.addListener(function(request) { if (request === "showPopup") { showPopup(); } }); The click event works as expected. But now we want to do same thing in mozilla extension. and we can't pass message to app.js on the click of the icon,so that it can execute the containing methods. We have also added the app.js using pageMod, something like this exports.main = function(options, callbacks) { pageMod.PageMod({ include: ["*"], contentScriptWhen: 'start', contentScriptFile: [data.url('jquery-1.7.1.min.js'),data.url('app.js')] }); createAndAddNavBarButton(); }; function createAndAddNavBarButton() { var navBar = document.getElementById('nav-bar');//assume document has been defined if (!navBar){return;}; var nbBtn = document.createElement('navbaricon'); nbBtn.setAttribute('id', 'navButton'); nbBtn.setAttribute('image', data.url('icon_16.png')); nbBtn.onclick = function(){ showPopup(); return true; } navBar.appendChild(btn); } But the click event does nothing and showPopup() is undefined. When a new page loads event associated with it in the app.js executes without any error but the click event doesn't work. Is there a method from where we can assign click event directly to this icon, as we have done in the case of chrome extension.

    Read the article

  • create dynamic navigation from xml file in flash cs3

    - by mjr
    action script newbie here :-) What I want to do is this, hand an xml file to a swf and have the swf generate a dynamic text box and button for each of the links in the xml file a rudimentary navigation here's the xml <?xml version="1.0" encoding="UTF-8"?> <page> <page name="Page Name 1" url="/page-1/" /> <page name="Page Name 2" url="/page-2/" /> <page name="Page Name 3" url="/page-3/" /> <page name="Page Name 4" url="/page-4/" /> </page> and in my fla I have a button in my library named 'nav_button' there's a layer named actions and in frame 1 I have this var xml:XML; var xmlList:XMLList; var xmlLoader:URLLoader = new URLLoader(); var button:Button = new Button(); xmlLoader.load(new URLRequest("links.xml")); xmlLoader.addEventListener(Event.COMPLETE, xmlLoaded); function xmlLoaded(event:Event):void { xml = XML(event.target.data); xmlList = xml.children(); trace(xml.length()); for(var i:int = 0; i < xmlList.length(); i++) { button = new Button(); button.x = 25; button.y = i * 50 +25; addChild(button); } } the xml imports fine, but when it comes to the for loop and adding the buttons and text boxes to the stage, I'm toast

    Read the article

  • Dynamically resizing navigation div to main content

    - by theZod
    Greetings and Hello I am trying to put together a wordpress site, now because the content in the main div is going to be a different height with every page I need the navigation sidebar to stretch to the same height. So with a little javascript tom-foolery I can get the sidebar to be the same height with the following code function adjust(){ hgt=document.getElementById('content').offsetHeight; document.getElementById('sidebar').style.height=hgt+'px'; } window.onload=adjust; window.onresize=adjust; Now that's all good for a long page but if the content is smaller then the sidebar stuff gets all messy. So I have tried an if statement like so function adjust() { if (document.getElementById('content').style.height < document.getElementById('sidebar').style.height){ hgt=document.getElementById('content').offsetHeight; document.getElementById('sidebar').style.height=hgt+'px'; else hgt=document.getElementById('sidebar').offsetHeight; document.getElementById('content').style.height=hgt+'px'; } } window.onload=adjust; window.onresize=adjust; But that just doesn't do anything, so any ideas whats going on?

    Read the article

  • Black Corners On Grouped UITableViewCells Only After Navigation Pops

    - by coneybeare
    I am not graphics expert but I somehow managed to make some good looking custom grouped UITableViewCells by setting the background view to a backgroundView with some CG code. In all SDK's up to 3.1.3 (maybe 3.2... I haven't tested on the iPad) this was working great, but I think a more recent SDK has introduced a change in the way graphics are cached offscreen. Upon first render, everything is great: The drawing is fine and the corners are transparent. If I push a couple of view controllers on the navigation stack and come back, there are now black corners that appear in the views: BEFORE && AFTER I have tons of code, most of which is written up here. I have tried tweaking to the best of my ability, looking at the docs for applicable changes, but after at least 8 hours in I still cannot find what might cause this. I have tried setting every view I can think of to be backgroundColor=clearColor and opaque=NO What else am I missing? Any debugging tips? UPDATE: I have some debug code in viewDidAppear that prints the backgroundColor and class description of all the subviews. - (void)debugView:(UIView *)view { DebugLog(@"%@ - %@", view.backgroundColor, [[view class] description]); for (UIView* child in view.subviews) { [self debugView:child]; } } - (void)viewDidAppear:(BOOL)animated { [super viewDidAppear:animated]; [DownloadController.networkQueue setSuspended:NO]; for (TTTableViewCell *cell in [self.tableView visibleCells]) { [cell debugView:cell]; } } With this code, I inspect the backgroundColor settings of the cell views on first load, when it is fine, and then again after coming back. There are some differences, but all the colors are still set to be clear. This leads me to believe the issue is underneath the UITableViewCell. UPDATE 2: I have created a simple sample application to highlight the problem here

    Read the article

  • PHP Multiple navigation highlights

    - by Blackbird
    I'm using this piece of code below to highlight the "active" menu item on my global navigation. <?php $path = $_SERVER['PHP_SELF']; $page = basename($path); $page = basename($path, '.php'); ?> <ul id="nav"> <li class="home"><a href="index.php">Home</a></li> <li <?php if ($page == 'search') { ?>class="active"<?php } ?>><a href="#">Search</a></li> <li <?php if ($page == 'help') { ?>class="active"<?php } ?>><a href="help.php">Help</a></li> </ul> All works great but, on a couple of pages, I have a second sub menu (sidebar menu) within a global page. I basically need to add a OR type statement into the php somehow, but I haven't a clue a how. Example of what i mean: <li <?php if ($page == 'help') OR ($page == 'help-overview') OR ($page == 'help-cat-1') { ?>class="active"<?php } ?>><a href="#">Search</a></li> Thanks!

    Read the article

< Previous Page | 48 49 50 51 52 53 54 55 56 57 58 59  | Next Page >