Linking Files In PHP

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
dj1mitch
Forum Newbie
Posts: 1
Joined: Thu Jun 11, 2009 2:14 pm

Linking Files In PHP

Post by dj1mitch »

I have a list of Past Exhibits on an Art site. I want to link to the Past Exihibits using PHP from individual artist pages.

Right now I am able to generate the text dynamically on each artist page with the following code:

Code: Select all

if(!empty ($exhibit)){
        print ('<br /><div class="submenu1">exhibit</div><!-- end submenu1 -->');
        
        foreach($exhibit as $exhibitkey => $exhibitname) {
          $exhibitname = substr_replace($exhibitname, '', -4); 
          $exhibitkey =(($exhibitkey)+1);
 
          if ($_GET['exhibit'] == $exhibitkey) {
          print ('<div class="submenu2">'.$exhibitname.'</div><!-- end submenu 2 -->');
          } else {
 
          print ('<a href="artists.php?artist='.$artistfolder.'&exhibit='.$exhibitkey.'">'.$exhibitname.'</a><br />');
          
          
          }
        }
 
    }
Is there away to code php to link from the Artist Page to that particular Artist Past Exhibition.
Last edited by Benjamin on Thu Jun 11, 2009 7:14 pm, edited 1 time in total.
Reason: Changed code type from text to php.
User avatar
Popcorn
Forum Commoner
Posts: 55
Joined: Fri Feb 21, 2003 5:19 am

Re: Linking Files In PHP

Post by Popcorn »

your question isn't so clear to me coz i'd say it looks like you are doing that on line 12... :S
Post Reply