Running into problems making my own 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   Running into problems making my own module.
wolf
CZ Active Member
usa.gif indiana.gif
Occupation: Student; Flash, HTML, PHP developer
Age: 34
Gender: Male
Status: Offline
Joined: Jul 25, 2003
0.02 posts per day
Posts: 168
Points: 10,417
AIM Address Yahoo Messenger MSN Messenger 
Ok, I want to keep this module on the low, so I'm not going to describe what all it's going to do. It is my first module...and have run into several errors that I have fixed.

My question is, Telli posted that "modules.php?name=DIRECTORY&file=FILENAME" should be used when making modules. Well, my problem is I don't want all my files inside the directory "Albums", so I made several sub directors, such as Users, Images, Languages...That stuff.

My question now is, lol, using "modules.php?name=DIRECTORY&file=FILENAME" how can i make it point to a file in Albums/Users? I tried modules.php?name=Albums/Users&file=Wolfster.php where is didnt work.

Thanks, Wolf.




_________________
[ Register or login to view links on this board.]
Back to top Reply with quote
#2   
Telli
Site Admin
Occupation: Self Employed
Age: 46
Gender: Male
Fav. Sports Team: Detroit Red Wings
Website:
Status: Offline
Joined: May 26, 2003
1.03 posts per day
Posts: 8089
Points: 494,475
   
You can't use it that way. Make a file called users.php and in that place the users functions or whetever then you would call it with that

modules.php?name=Albums&file=users&user=wolfster




_________________
The path of the righteous man is beset on all sides by the inequities of the selfish and the tyranny of evil men. Blessed is he, who in the name of charity and good will, shepherds the weak through the valley of darkness, for he is truly his brother's keeper and the finder of lost children. And I will strike down upon thee with great vengeance and furious anger those who would attempt to poison and destroy my brothers. And you will know my name is the Lord when I lay my vengeance upon thee. Ezekiel 25:17
Back to top Reply with quote
#3   re: Running into problems making my own module.
wolf
CZ Active Member
usa.gif indiana.gif
Occupation: Student; Flash, HTML, PHP developer
Age: 34
Gender: Male
Status: Offline
Joined: Jul 25, 2003
0.02 posts per day
Posts: 168
Points: 10,417
AIM Address Yahoo Messenger MSN Messenger 
Ok, I'm not quite understanding Telli... Are you saying to make a users.php file in Albums then make wolfster.php under it???




_________________
[ Register or login to view links on this board.]
Back to top Reply with quote
#4   
Telli
Site Admin
Occupation: Self Employed
Age: 46
Gender: Male
Fav. Sports Team: Detroit Red Wings
Website:
Status: Offline
Joined: May 26, 2003
1.03 posts per day
Posts: 8089
Points: 494,475
   
You would make a function in the users file something like this

function showuser($username) {
include("modules/Albums/users/$username.php
}

Then user there name as that variable to pass it to that function.



_________________
The path of the righteous man is beset on all sides by the inequities of the selfish and the tyranny of evil men. Blessed is he, who in the name of charity and good will, shepherds the weak through the valley of darkness, for he is truly his brother's keeper and the finder of lost children. And I will strike down upon thee with great vengeance and furious anger those who would attempt to poison and destroy my brothers. And you will know my name is the Lord when I lay my vengeance upon thee. Ezekiel 25:17
Back to top Reply with quote
#5   re: Running into problems making my own module.
wolf
CZ Active Member
usa.gif indiana.gif
Occupation: Student; Flash, HTML, PHP developer
Age: 34
Gender: Male
Status: Offline
Joined: Jul 25, 2003
0.02 posts per day
Posts: 168
Points: 10,417
AIM Address Yahoo Messenger MSN Messenger 
Ok, I get ya, I'll try it after school. Thanks.




_________________
[ Register or login to view links on this board.]
Back to top Reply with quote
#6   re: Running into problems making my own module.
ShadowZ
CZ Newbie
ShadowZ has been a member for over 20 year's 20 Year Member
canada.gif
Gender: Male
Status: Offline
Joined: Jul 20, 2004
0.00 posts per day
Posts: 4
Points: 2,294
   
I figured this was about the closest forum 2 post in, lol short of checking all 45 pages.
OK q iz, all i'm tryin 2 do is combine 2 blox into 1


$my_domain = "ShadowZ";
$text_color = "0011ff";
$results_bg = "000000";
$header_bg = "000000";
$border = "0011ff";
$logo_height = "50";
$logo_width = "410";
$my_logo = "http://shadowz.ca/pix/shadowz5.gif";
$my_logo_link = "http://shadowz.ca"; 
$visited_link = "663399";
$title_color = "0011FF";
$url_color = "0011ff";
$faint_color = "0000FF";

if (eregi("block-searchs.php", $_SERVER['PHP_SELF'])) {
    Header("Location: index.php");
    die();
}


$content .= "<!-- SiteSearch Google -->
<FORM method=GET action='http://www.google.com/custom'>
<center><A HREF='http://www.google.com/'><IMG SRC=' http://firstquadrantphilippines.com/Nuke/modules/GoogleApiSearch/google.gif '
border='0' ALT='Google'></A><br>
<input type=hidden name=domains value='".$my_domain."'><INPUT TYPE=text name=q size=60 maxlength=255 value=''><br>
<INPUT type=submit name=sa VALUE='Search Google'></center>
<center><font size=-1><input type=radio name=sitesearch value=''checked> Web
<input type=radio name=sitesearch value='".$my_domain."' >Site search</center></font>


<input type=hidden name=client value='pub-1601423420867613'>
<input type=hidden name=forid value='1'>
<input type=hidden name=ie value='ISO-8859-1'>
<input type=hidden name=oe value='ISO-8859-1'>
<input type=hidden name=cof value='GALT:#".$url_color.";GL:1;DIV:#".$border.";VLC:".$visited_link.";AH:center;BGC:".$results_bg.";LBGC:".$header_bg.";ALC:".$title_color.";LC:".$title_color.";T:".$text_color.";GFNT:".$faint_color.";GIMP:".$faint_color.";LH:".$logo_height.";LW:".$logo_width.";L:".$my_logo.";S:".$my_logo_link.";FORID:1;'>
<input type=hidden name=hl value='en'>

</FORM>
<!-- Sitesearch  Google -->
";

/***** Search Domain Script *****/
/* http://xp1.de                                                   */



$content = "<FORM method=\"POST\" action=\"http://www.domaindiscount24.com/cgi-bin/domshopping.cgi\" target=\"_blank\">";
$content .= "<TABLE bgcolor=\"#000000\" width=\"100%\">";
$content .= "<tr>";
$content .= "<td align=\"center\">";
$content .= "<font color=blue>Check here 2c if </A><br>";
$content .= "your Domain Name</A><br>";
$content .= "iz Available</A><br>";
$content .= "<INPUT TYPE=\"text\" name=\"domain\" size=\"20\" maxlength=\"255\" value=\"\">";
$content .= "<INPUT TYPE=\"hidden\" name=\"affiliateID\" value=\"00366098\"><br>";
$content .= "<INPUT TYPE=\"hidden\" name=\"language\" value=\"\">";
$content .= "<INPUT type=\"submit\" name=\"search\" VALUE=\"Search\"></td></tr></TABLE></FORM>";

Now when i run this only the domain search shows.
yup u guessed it, I'm new 2 php. Any help would b appreciative!


Back to top Reply with quote
#7   
Telli
Site Admin
Occupation: Self Employed
Age: 46
Gender: Male
Fav. Sports Team: Detroit Red Wings
Website:
Status: Offline
Joined: May 26, 2003
1.03 posts per day
Posts: 8089
Points: 494,475
   
Looks good just change this line :

$content = "<FORM method=\"POST\" action=\"http://www.domaindiscount24.com/cgi-bin/domshopping.cgi\" target=\"_blank\">";


To

$content .= "<FORM method=\"POST\" action=\"http://www.domaindiscount24.com/cgi-bin/domshopping.cgi\" target=\"_blank\">";




_________________
The path of the righteous man is beset on all sides by the inequities of the selfish and the tyranny of evil men. Blessed is he, who in the name of charity and good will, shepherds the weak through the valley of darkness, for he is truly his brother's keeper and the finder of lost children. And I will strike down upon thee with great vengeance and furious anger those who would attempt to poison and destroy my brothers. And you will know my name is the Lord when I lay my vengeance upon thee. Ezekiel 25:17
Back to top Reply with quote
#8   re: Running into problems making my own module.
ShadowZ
CZ Newbie
ShadowZ has been a member for over 20 year's 20 Year Member
canada.gif
Gender: Male
Status: Offline
Joined: Jul 20, 2004
0.00 posts per day
Posts: 4
Points: 2,294
   
lol I figured it was sumthin stupid thx for the help .... worx like a charm icon_biggrin.gif



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