Jump to content

Recommended Posts

Posted

Any one able to get entry types to work?

Not sure what I am missing but have the config portion here to look at, any where else that needs a change?

 

# $typel["A"] = "A";

# $typel["B"] = "B";

# $typel["C"] = "C";

# $typel["D"] = "D";

$typel["E"] = get_vocab("external");

# $typel["F"] = "F";

# $typel["G"] = "G";

$typel["H"] = get_vocab("holiday"); < -- this is the one I added and will not show on the page

$typel["I"] = get_vocab("internal");

# $typel["J"] = "J";

Posted

Change to

$typel["H"] = "Holiday";

 

However, the letters only link to the CSS. For example.."A" is the colour it links to. If you look in your CSS you'll see this.

 

"H" is just another colour.

  • 1 month later...
Posted

Thanx, got it an hors after my post 8O .

 

New question though, new to PHP. How would I set MRBS to show the login page before anything else? Looked in the index.php and that was not much help.

  • 2 weeks later...
Posted

That is quite an easy one, but off the top of my head I can't tell you the exact code to add and where to add it. There is a function to check what the username of the requester is (they who are accessing various areas of MRBS). All I did was check if this username was null, and if null, exit the script and echo a message telling them to login, thus preventing the rest of the php from loading. Works really well but needs some tweaks in the echo part (or maybe directing to a custom page) to look consistant.

 

I can take a look when school reopens at what I changed and let you know how I did it, if you haven't figured it out by then.

Posted
That would be great! Thank you. Have to admit.. never thought to look there. Will take a look to see if I can figure it out and I look forward to your response.
  • 2 weeks later...
Posted

Don't know if you managed to do this or not, but i've checked what I used on my code and the below seems to be effective for us..

 

$username   = getUserName();
if (!$username) {
include "nologin.php";
exit;
}

 

In the case of including nologin.php, this is a custom page I have created to inform for the user why their request failed (ie: letting them know they are not logged in).

 

I put it below the bit of code which grabs the date, although I would imagine it would still ok putting it strait after the main include lines at the top, so long as it is before the main mrbs code.

 

Dave

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...