Jump to content

Recommended Posts

I need help figuring this out.

 

I have a site that on the main page events are listed in order by dates...when people upload an event the put in the month...day...year.  I have them seperated in mysql database as $month $day $year.

 

I want to create a link on my side nav bar for each month

ex

 

January

February

March...etc

 

Is there a way when you click on January that it will pull all the tournaments from jan.

 

The site is set up with an index page that includes maincontacts.inc page that the events display on.

 

Thanks

 

 

 

Link to comment
https://forums.phpfreaks.com/topic/85377-solved-need-help-with-links/
Share on other sites

the link URL will have to use $_GET data that a .php script will then grab and use to run a database query.

 

<a href="www.mypage.com/getMonthData.php?month=January>January</a>

 

<?php //getMonthData.php

$month = $_GET['month'];
//query database
//select * from event where month= '{$month}'
//something like that
?>

 

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.