How to Make Any Link a Module

  Post new topicReply to topicPrintable Version
<< View previous topic View next topic >>
Share: Del.icio.us  Digg  Google  Spurl  Blink  Furl  Y! MyWeb  
#1   How to Make Any Link a Module
JRSweets
CZ Active Member
 Codezwiz Site Donator
JRSweets has been a member for over 20 year's 20 Year Member
usa.gif massachusetts.gif
Age: 43
Gender: Male
Fav. Sports Team: NE Patriots
Website:
Status: Offline
Joined: Apr 07, 2004
0.03 posts per day
Posts: 259
Points: 19,861
  MSN Messenger 
I hope this can help some people out. I was using the CZ Module and wanted to add links to categories other than Quick Links. I found out be searching here that to do this they have to be modules.

To create a module that is basically a link to another page is very simple. First create a folder with a name of your choice. Place inside the folder one file named index.php and use this code:

<?php
if (!eregi("modules.php", $PHP_SELF)) {
  die ("You can't access this file directly...");
}
$index = 1;
require_once("mainfile.php");
header("Location: modules.php?name=Forums&file=statistics");
$module_name = basename(dirname(__FILE__));
get_lang($module_name);
include("header.php");
include("footer.php");
?>


You can replace what follows Location: in this line,
header("Location: modules.php?name=Forums&file=statistics");


with the link to the page you want. Goto the admin panel in PHPNuke, activate the module and give it the category you want.


Back to top Reply with quote
#2   re: How to Make Any Link a Module
skullcramp
CZ Newbie
skullcramp has been a member for over 20 year's 20 Year Member
usa.gif idaho.gif
Occupation: General Manager
Gender: Male
Fav. Sports Team: San Diego Chargers
Website:
Status: Offline
Joined: Apr 28, 2004
0.00 posts per day
Posts: 28
Points: 2,662
   
Is there a way to modify this script so that it takes info from a table and inserts it into the form the link goes to?

I wan't to use my host's webmail, and give my users access to it from my nuke site. But I don't want them to have to log in again. They will log onto my site, click webmail link in modules and automatically be logged on to there webmail with data from a table.

Perhaps there's a mod to the existing webmail module.

Thanks for any help,
Craig



Back to top Reply with quote
#3   
JRSweets
CZ Active Member
 Codezwiz Site Donator
JRSweets has been a member for over 20 year's 20 Year Member
usa.gif massachusetts.gif
Age: 43
Gender: Male
Fav. Sports Team: NE Patriots
Website:
Status: Offline
Joined: Apr 07, 2004
0.03 posts per day
Posts: 259
Points: 19,861
  MSN Messenger 
I have looked for similar things and never found them. I found one for Horde Mail, but the users would have to login in twice. (Once to the site, once to access the mail.)



Back to top Reply with quote
Display posts from previous:      
Add To: Del.icio.us  Digg  Google  Spurl  Blink  Furl  Y! MyWeb  
<< View previous topic View next topic >>
Post new topicReply to topic

Jump to 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum