Want to take part in these discussions? If you have an account, sign in now.
If you don't have an account, apply for one now.
-
- CommentAuthorhiegl
- CommentTimeNov 21st 2008
Hi Patrick,
I used relative links for the menu bar in superfresh as you proposed and discovered the following:
- when I use "course/category.php?id=1" to link to a course category this works on the frontpage
- if I am on the category page the link is changed to "course/course/category.php?id=1"Is there a way to do it without using absolute links?
Thanks, Bernhard
-
-
CommentAuthorptrkmkl
- CommentTimeNov 21st 2008 edited
Hello Bernhard,
That may have been what I did, but is not what I've "proposed." Nevertheless, I understand how my layout could have confused.
Here's a fix that will keep all of your links relative while maintaining the link structure on any page:
1.) Open menu.php using a basic text editor.
2.) Add
<?php echo $CFG->wwwroot ?>as the base for every link.
3.) Save.
For example:
<a href="<?php echo $CFG->wwwroot ?>/solutions.php">Courses</a> <div> <a href="<?php echo $CFG->wwwroot ?>/course1.php">Course 1</a> <a href="<?php echo $CFG->wwwroot ?>/course2.php">Course 2</a> <a href="<?php echo $CFG->wwwroot ?>/course3.php">Course 3</a> <a href="<?php echo $CFG->wwwroot ?>/course4.php">Course 4</a> </div> -
-
- CommentAuthorhiegl
- CommentTimeNov 22nd 2008
That did it! :-)
1 to 3 of 3

