News:

Wondering if this will always be free?  See why free is better.

Main Menu

My Package Server is now working...

Started by Grudge, March 28, 2004, 10:13:05 AM

Previous topic - Next topic

Grudge

Hey,

This thread is used to keep people updated with what is on my package server. I want to first stress that The Packager Manager is still being developed - and is NOT done!. As such you may have problems getting MOD's to install etc. If this is the case please feed back your problems in this thread and don't start others about it. Also - before attempting to install a MOD from the package server please read the guidelines at the bottom of this post for "setting up" your forum to stand the best chance of installing successfully.

New Mods added to my package server recently:
Buddy List - Allows you to add members as "buddies", showing them online easily and making it easy to PM them.
Gender based membergroups - allow you to specify male AND female versions of each membergroup
Redirection boards - allowing you to make a board redirect to any url when clicked
Post Moderation - Moderate either ALL posts or on a member by member basis before they appear (BETA!)

Existing Mods on the package server
Topic Solved
Shoutbox (You'll need to edit your template manually for it to appear)
Custom Message Icons (Including adding icons, making radio selectable, adding to quick reply)
Visual Warning Mod Including Post Moderation
Pie Chart options on polls
Coloured Jumpbox
Redirection Boards.

Please try these out and let me know how you get on. I love to hear both good and bad experiences. Try to keep all comments in this thread as I check it regularly. Also let me know of any bugs or problems as these are easily fixed. Also - before posting about a problem read the posts in this thread incase I have already answered it!



Now onto setting up the packager manager!
As mentioned above the package manager is still in development so things won't necessarily go smoothly first time. Recent additions to the package manager have meant that on some servers chmod'ing directories may be a thing of the past - however - it is safer to do so anyway. Basically, before the package manager is used you should CHMOD certain files and directories to have permissions 777 (read, write and execute for all). This can be done with any FTP client - usually by right clicking on the files you wish to change permissions to. Below is a list of files I believe you should chmod to 777. If you wish you only need to chmod the Packages directory and any file being changed by a certain package - however, you can't go far wrong by doing them all at once!

CHMOD these directories:
index.php
SSI.php
/Packages - directory and all files inside it
/Sources - directory and all files inside it
/Themes - directory and ALL sub directories
/Themes/default - directory and ALL files inside
/Themes/default/languages - directory and ALL files inside
/Themes/default/images - directory and ALL directories inside

If you do these you should be ready to go!

What do I do when I upgrade?
When you upgrade to the next version of SMF you will most likely lose all the MODs you have installed - note you DON'T lose the data the MOD's stored. When upgrading if you desperatly need a MOD I would wait until I have updated the MOD to the next version (normally within a few days of release) before upgrading. If it is a security fix then that takes priority! Before doing an upgrade I recommend you uninstall all the MOD's you had installed previously and then reinstall new versions afterwards.

What if things go wrong?
If the worst comes to the worst and a MOD breaks your forum. The worst you will have to do is reload files from the original distribution. If this happens reload the entire contents of the Sources and Themes directory - except style.css and any templates you have manually changed (normally index.template.php)

Hopefully this will help everyone use this great feature of SMF. I'll reitterate that this isn't a completed feature so don't get too worked up if it doesn't work for you - be patient! The MOD site will be up shortly so anyone who cannot use the package manager yet will soon be able to get the MOD's via the MOD site.

Cheers,
Grudge
I'm only a half geek really...

Tomer

Quote from: Grudge on March 28, 2004, 10:13:05 AM
They are now completly uninstallable so removing them is easy.

I think you meant isint easy

I tried them, only the warning thingy worked at first glance, the topic checked thingy didnt work or maybe I checked in the wrong area...

But good job...

Winters

Quote from: Grudge on March 28, 2004, 10:13:05 AM
All the changes are always made to the default template, and all my mods are english only although I would happily add other language support if I had translations!

I'm not yet familiar with the template system, so my question may be dumb: Does this mean, the mod will not work with the converted template?

Zippo

I failed to chmod sources/Subs_Package.php and recieved a chmod error.  After chmoding it to 777 I now recieve this error:

Fatal error: Cannot redeclare smfshout() in /home/sites/site99/web/body/Sources/Subs.php on line 1724

Any ideas?

Grudge

Winters, the mod should work fine on a converted template. Basically, if someone made a massive theme changing all the templates then it would likely cause trouble, but just changes in index.template.php should be fine.

Zippo, open up Subs.php, skip to the VERY botton and you'll most likely see two functions called smfshout(). Delete one of them :)

Lamper, there's no reason why it shouldn't work assuming you have beta 4.1 and have chmod'd the files that it changes. chmod is VERY important, and needs to be done on uninstall too :)
I'm only a half geek really...

Winters

Thanks. Uhm, is it normal that I only see "yabbse"-Links in my package manager?

Grudge

What do you mean? I don't see why you would see YaBB SE stuff. Do you mean in the list of servers? If you upgraded maybe the new server list isn't there. If not you can add my server as:
http://www.mymods.co.uk/Packages
I'm only a half geek really...

Zippo

Quote from: Grudge on March 28, 2004, 11:56:20 AM

Zippo, open up Subs.php, skip to the VERY botton and you'll most likely see two functions called smfshout(). Delete one of them :)


There was two, deleted one and recieve this:

Parse error: parse error in /home/sites/site99/web/body/Sources/Subs.php on line 1496

Warning: Cannot send session cookie - headers already sent by (output started at /home/sites/site99/web/body/Sources/Subs.php:1496) in /home/sites/site99/web/body/index.php on line 89

Warning: Cannot send session cache limiter - headers already sent (output started at /home/sites/site99/web/body/Sources/Subs.php:1496) in /home/sites/site99/web/body/index.php on line 89

Fatal error: Call to undefined function: template_header() in /home/sites/site99/web/body/Sources/Subs.php on line 1186

de3jeh

Quote from: Grudge on March 28, 2004, 10:13:05 AM
Hey,

Didn't really know where to post this but anyway... as people will know there is a package server option in the admin center. If you go there and select my package server you'll see a list of MOD's for SMF that I have done, namely:
Topic Solved
Shoutbox (You'll need to edit your template manually for it to appear)
Custom Message Icons (Including adding icons, making radio selectable, adding to quick reply)
Visual Warning Mod Including Post Moderation
Pie Chart options on polls
Coloured Jumpbox
and a *real* beta version of an instant message centre mod. (Most likely buggy).

I'd appreciate it if people would try these out. They are now completly uninstallable so removing them is easy. Obviously they are still beta mod's but they should work but I take no responsibility if they don't. We will have a mod site up soonish but until then if you want to post any problems here I'll try answer them.

Now - if you have any problems using the package manager it is most likely due to the fact that files need chmod'ing to 777, so see how it goes. All the changes are always made to the default template, and all my mods are english only although I would happily add other language support if I had translations!

Thanks a lot,
Grudge

Note to moderators: If this isn't the place for this feel free to move it elsewhere!
it is not working i get error's  :'(
Hello all i am here to help u all ;)

Grudge

Zippo,

Can you post line 1490-1500 so I can see what the problem is. You didn't delete the ?> at the end of the file did you?

de3jeh,

You need to elaborate! Are you using a UNMODIFIED beta 4.1 at the moment?
I'm only a half geek really...

de3jeh

Quote from: Grudge on March 28, 2004, 01:04:15 PM
de3jeh,

You need to elaborate! Are you using a UNMODIFIED beta 4.1 at the moment?

yes i am using a UNMODIFIED beta 4.1

what do i have to change to make it work ?

thanx in advance
Hello all i am here to help u all ;)

Grudge

I can't help you if you do not tell me what the error is!! I saw your post in another thread and replied to it about some errors you got trying to install one of the mods. Have you chmod'd the files correctly? You need to chmod your directories (Sources, Theme/default, images and languages) and any files that will be modified to 777.
I'm only a half geek really...

de3jeh

I can dowload it that is not a problem

but if i want to install it it depend's on whitch mod then i get an error like this

Warning: copy(/home/internet/public_html/Themes/default/MsgIcon.template.php): failed to open stream: Permission denied in /home/internet/public_html/Sources/Subs-Package.php on line 491
Warning: copy(/home/internet/public_html/Themes/default/images/arrow_down.gif): failed to open stream: Permission denied in /home/internet/public_html/Sources/Subs-Package.php on line 491
Warning: copy(/home/internet/public_html/Themes/default/images/arrow_up.gif): failed to open stream: Permission denied in /home/internet/public_html/Sources/Subs-Package.php on line 491
Warning: copy(Themes/default/languages/Admin.english.php~): failed to open stream: Permission denied in /home/internet/public_html/Sources/Subs-Package.php on line 668
Warning: fopen(Themes/default/languages/Admin.english.php): failed to open stream: Permission denied in /home/internet/public_html/Sources/Subs-Package.php on line 670
Warning: fputs(): supplied argument is not a valid stream resource in /home/internet/public_html/Sources/Subs-Package.php on line 671
Warning: fclose(): supplied argument is not a valid stream resource in /home/internet/public_html/Sources/Subs-Package.php on line 672
Warning: copy(Themes/default/languages/Admin.english.php~): failed to open stream: Permission denied in /home/internet/public_html/Sources/Subs-Package.php on line 668
Warning: fopen(Themes/default/languages/Admin.english.php): failed to open stream: Permission denied in /home/internet/public_html/Sources/Subs-Package.php on line 670
Warning: fputs(): supplied argument is not a valid stream resource in /home/internet/public_html/Sources/Subs-Package.php on line 671
Warning: fclose(): supplied argument is not a valid stream resource in /home/internet/public_html/Sources/Subs-Package.php on line 672
Warning: copy(index.php~): failed to open stream: Permission denied in /home/internet/public_html/Sources/Subs-Package.php on line 668
Warning: copy(index.php~): failed to open stream: Permission denied in /home/internet/public_html/Sources/Subs-Package.php on line 668
Warning: copy(index.php~): failed to open stream: Permission denied in /home/internet/public_html/Sources/Subs-Package.php on line 668
Warning: copy(index.php~): failed to open stream: Permission denied in /home/internet/public_html/Sources/Subs-Package.php on line 802
Warning: fopen(/home/internet/public_html/Packages/installed.list): failed to open stream: Permission denied in /home/internet/public_html/Sources/Subs-Package.php on line 311
Warning: fputs(): supplied argument is not a valid stream resource in /home/internet/public_html/Sources/Subs-Package.php on line 318
Warning: fclose(): supplied argument is not a valid stream resource in /home/internet/public_html/Sources/Subs-Package.php on line 320


Like this i put every Chmod to 777

and this is on the mod : Message Icon Manager;)
Hello all i am here to help u all ;)

Zippo

#13
No the ? is still there :)

{
// Get the host to pester...
preg_match('~^\w+://(.+?)/(.*)$~', $url, $match);

// Can't figure it out, just try the image size.
if ($url == '' || $url == 'http://' || $url == 'https://')
return false;
elseif (!isset($match[1]))
return @getimagesize($url);

// Try to connect to the server...
$temp = 0;
$fp = fsockopen($match[1], 80, $temp, $temp, 1);

// Successful?  Continue...
if ($fp !== false)
{
// Send the HEAD request.
fwrite($fp, 'HEAD /' . $match[2] . ' HTTP/1.1' . "\r\n" . 'Host: ' . $match[1] . "\r\n\r\n");
// Read in the HTTP/1.1 or whatever.
$test = substr(fgets($fp, 11), -1);
fclose($fp);

// See if it returned a 404/403 or something.
if ($test != '4')
return @getimagesize($url);
}

// Didn't work.
return false;
}

function determineTopicClass(&$topic_context)
{
// Set topic class depending on locked status and number of replies.
if ($topic_context['is_locked'])
{
if ($topic_context['is_poll'])
$topic_context['class'] = 'locked_poll';
elseif ($topic_context['is_sticky'])
$topic_context['class'] = 'locked_sticky';
else
$topic_context['class'] = 'locked';
}
elseif ($topic_context['is_sticky'])
{
if ($topic_context['is_poll'])
$topic_context['class'] = 'sticky_poll';
else
$topic_context['class'] = 'sticky';
}
elseif ($topic_context['is_poll'])
$topic_context['class'] = 'poll';
elseif ($topic_context['is_very_hot'])
$topic_context['class'] = 'veryhottopic';
elseif ($topic_context['is_hot'])
$topic_context['class'] = 'hottopic';
else
$topic_context['class'] = 'topic';

if ($topic_context['is_very_hot'])
$topic_context['extended_class'] = 'veryhot';
elseif ($topic_context['is_hot'])
$topic_context['extended_class'] = 'hot';
else
$topic_context['extended_class'] = 'normal';

if ($topic_context['is_poll'])
$topic_context['extended_class'] .= '_poll';
else
$topic_context['extended_class'] .= '_post';
if ($topic_context['is_locked'])
$topic_context['extended_class'] .= '_locked';
if ($topic_context['is_sticky'])
$topic_context['extended_class'] .= '_sticky';
}

// Sets up the basic theme context stuff.
function setupThemeContext()
{
global $modSettings, $user_info, $scripturl, $context, $settings, $maintenance;

// Get some news...
$context['news_lines'] = explode("\n", str_replace("\r", '', trim(addslashes($modSettings['news']))));
$context['fader_news_lines'] = array();
for ($i = 0; $i < count($context['news_lines']); $i++)
{
if (trim($context['news_lines'][$i]) == '')
continue;

// Clean it up for presentation ;).
$context['news_lines'][$i] = doUBBC(stripslashes(trim($context['news_lines'][$i])));

// Gotta be special for the javascript.
$context['fader_news_lines'][$i] = strtr(addslashes($context['news_lines'][$i]), array('/' => '\/', '<a href=' => '<a hre" + "f='));
}
$context['random_news_line'] ']']']= $context['news_lines'][rand(0, count($context['news_lines']) - 1)];

if (!$user_info['is_guest'])
{

de3jeh

Hello all i am here to help u all ;)

Grudge

Zippo,

Is this before or after adding the smfshout function into the template? If it is before then maybe somehow Subs.php got messed up. Get a fresh Subs.php from the SMF package and manually add:


function smfshout() {

global $sourcedir;
include_once("$sourcedir/shout.php");
$shouts = shout_reader();
$shouts .= shout_form();
print $shouts;
}


to the bottom of it (assuming you have no others mods installed).

If this is AFTER adding it to the template please show me how you added it.

Cheers,
Grudge
I'm only a half geek really...

de3jeh

Hello all i am here to help u all ;)

Grudge

de3jeh, the reason I didn't annswer you is I'm not sure. Hopefully Unknown will see this and help me out. It's not a problem with the MOD it still looks like a chmod problem but if have taken every file to 777 I can't see what the problem would be. Hopefully you'll get an answer soon!
I'm only a half geek really...

de3jeh

Hello all i am here to help u all ;)

[Unknown]

The package manager really isn't ready for use yet.

De3jeh, the following are not 777:
/home/internet/public_html/Themes/default
/home/internet/public_html/Themes/default/images
/home/internet/public_html/Themes/default/languages/
/home/internet/public_html
/home/internet/public_html/Packages/installed.list

Please chmod them so that they are writable.

-[Unknown]

Advertisement: