05 July 2012

Changes to the lochours page

Since the information in the chart is used both in the /loc/lochours.php and the Spanish language /loc/index-spi.php, I decided to create text files containing the information under the header rows in three places:
  1. hours for campuses under the header row for days of the week
  2. hours for other services points under the header row titled ( Other ACC Library Services Locations: AND Otros servicios y bibliotecas de ACC:)
  3. phone numbers under the header in that table
Then I used php includes to insert the text in the appropriate place in the file and remove the actual information from the files.  The three include scripts are:
  • ...?php include("http://library.austincc.edu/loc/lochours-top-include.txt"); ?...
  • ...?php include("http://library.austincc.edu/loc/lochours-bot-include.txt"); ?...
  • ...?php include("http://library.austincc.edu/loc/lochours-phone-include.txt"); ?...
Now only the text files need to be edited when hours change.