Black Storm

Started by The Domain Shop, July 05, 2011, 08:49:23 AM

Previous topic - Next topic

bmpk5032

Hi there!

On my forums I'm using a custom theme (Black Storm). I'm trying to add in a little bit of text and (what I'm assuming should be) PHP in between the board's header and the navigation bar. I'm going to add the text "Upcoming Performances" manually with html and I then want it to list the upcoming events as they are configured to display in the calendar settings. Basically, I don't want them to have to scroll all the way to the bottom to see the upcoming events listed in the Info Center and nor do I want to just relocate the Info Center to the top; just a string of text with the upcoming events at the top will be perfect!

I followed the advice found on ssi_examples.php by adding in the following code on line 1 of index.template.php:

<?php require("/home/a6561555/public_html/SSI.php"); ?>

I then added the following code to index.template.php right after the header <div> is closed and just before the navigation bar <div> is opened:

<?php ssi_todaysEvents(); ?>

The font "Upcoming Performances:" displays exactly where it should be, but absolutely nothing is showing after the colon where I would expect the upcoming events to display. If anyone could point me to what I'm doing wrong, it'd be greatly appreciated! Many thanks in advance! :)

The Domain Shop

You don't need ssi if your placing the code in the themes template already?

To get upcoming events you need something like this i believe ',$txt['events_upcoming'],'

bmpk5032

Thanks for the reply!

I tried adding that bit of code where I had the "Upcoming Performances:" before, but all it did was replace it with "Upcoming Events:" and didn't list any of them after the colon. As you can probably tell, I'm a bit of a newb when it comes to PHP. I only took a handful of courses in college for various other programming languages, so I know just enough to be able to read my way through and determine minor coding changes to the point of being able to administrate the forums, but doing what bit of code I thought would work has never resulted in it the events being displayed.

With that being said, if you're not going to place it in the themes template, where else would you place it? Basically, when I check out hxxp:myforumaddress.com/ssi_examples.php [nonactive] and look at the bit of code that it gives me for listing "Today's Events", the resulting example that it displays underneath actually lists the events that I have entered into my forum's calendar. I basically just want to take that and plop it right at the top of the forum when users that are capable of seeing that information log in with their user/pass.

Any other thoughts/comments would be greatly appreciated! :)

The Domain Shop

Yep, sorry that's just going to display "Upcoming Events:" my mistake :-[

SSI is generally used to pull information from the software and display it on another page like an index/home page.

Has for moving stuff around like this i would suggest asking in SMF Coding Discussion PhP is not my strong point and i would rather you ask someone else who knows more about PHP and the correct way to doing this.

Thanks

Advertisement: