PHP If Else statement for breadcrumb


Posted on 16th Feb 2014 07:03 pm by admin

Hi

I am trying to use a PHP if else statement to display a breadcrumb link on wordpress

Did you know?Explore Trending and Topic pages for more stories like this.
The code

Line number On/Off | Expand/Contract <div class="triple silhouette_break"> <ul> <li><a href="/">HOME</a> &raquo;</li><? $t=$_SERVER['REQUEST_URI']; if ($t == "/blog/")?><li><a href="<?php bloginfo('url'); ?>/" title="<?php bloginfo('name'); ?>" class="current">BLOG</a> &raquo;</li><? else ?> <li><a href="<?php bloginfo('url'); ?>/" title="<?php bloginfo('name'); ?>">BLOG</a> &raquo;</li> <li><a href="<?php $t ?>" class="current"><?php wp_title('&laquo;', true, 'right'); ?></a></li> </ul> </div>

If the user is on "/blog" or "/blog/" folder then I only want to display >> BLOG and if they are on anything else inside that folder I want to display the URL they are on and the crumb
No comments posted yet

Your Answer:

Login to answer
260 Like 10 Dislike
Previous forums Next forums
Other forums

Checking BOM Authorization Group
Hai Friends,

I have developed a mulitilevel BOM display report. End users have been assig

Need help with some php code :)
Hey! I'm quite new to this whole thing, so please don't fire me with shait on this one =D

I'm

C++ Http request?
Code: string Response = "LOGIN_UNSUCCESSFUL"; System.Net.WebRequest request = Sy

ECC6 - Single sign-on
We are in the process of upgrading to ECC 6 which will support single sign on with user passwords al

Remote Database Access
Hey guys!!

OK, i'm used to only working with databases from the CPANEL, accessing phpMyAdmin

need to apply an if/else statement to Tim Thumb script
Not sure how to work this. I essentially want to call a variety of image sizes based on which style

DateTimeZone::listIdentifiers headache
http://php.net/manual/en/datetimezone.listidentifiers.php


So the documentation states tha

Return X values where an ID number doesnt matter
Well as for subject heading, thats the best i could think of.

Currently im having a problem w

have trouble in a if condition
The if below is working ok, it check when indexes, name, zipcode and state are empty.
Code: &

Grabbing Values From an Array for Posting
I have a grid array that I am using with a form that when it hits the currently named test.php it lo

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash