26

(3 replies, posted in Archive)

man kan ju översätta genom att gå igenom admin_xxx.php - scripten och ändra texten i dom, men d e jobbigt smile

cant you use the do_smilies() function on the topic title and announcement texts before you output it on the site? and include parser.php as well...

something like (in header.php line 196)

<table class="punmain" cellspacing="1" cellpadding="4">
    <tr class="punhead">
        <td class="punhead"><?php echo $lang_common['Announcement'] ?></td>
    </tr>
    <tr>
        <td class="puncon2">
            <?php 
                           include($pun_root.'include/parser.php');
                           echo do_smilies($pun_config['o_announcement_message']) 
                        ?><br><br>
        </td>
    </tr>
</table>

and in viewforum.php: (line 155)

if ($pun_config['o_censoring'] == '1')
    $cur_topic['subject'] = censor_words($cur_topic['subject']);

include($pun_root.'include/parser.php');
$cur_topic['subject'] = do_smilies($cur_topic['subject']);

i have not tested this myself since these are functions i would not like to have, but do they work? im not familiar enough with this forum to know if you have disabled this in some way rickard wink

28

(11 replies, posted in General discussion)

my absolute nr one: Mulholland Drive

cant get much better... leaves you stunned smile

simkin wrote:

Hi! have you seen this?

http://puncms.dizmedia.com/

Ô_o?

It was nice.. finish developing it and it will rock big_smile

30

(1 replies, posted in PunBB 1.2 show off)

post a link so we can see it?

WHOHOOO made it work.. i put
<img src="http://domain/path/mimetex.exe?$1" border="0" alt="LaTeX Image">

before i did not have perl installed.. smile

so everyone with windows:
download the exe from: http://www.forkosh.com/mimetex.html

replace the rows in parser.php with

    $replace = array('<strong>$1</strong>',
                     '<em>$1</em>',
                     '<u>$1</u>',
                     'truncate_url(\'$1\')',
                     'truncate_url(\'$1\', \'$2\')',
                     '<a href="mailto:$1">$1</a>',
                     '<a href="mailto:$1">$2</a>',
                     '<span style="color: $1">$2</span>',
                     '<img src="http://adress/cgi-bin/mimetex.exe?$1" border="0" alt="LaTeX Image">');

tried that before.. i always experiment  big_smile

didnt work sad

can check the support forum.. too bad its so hard getting thios to work

i ran it.. wont pop.. smile

if you run the .exe in a command prompt you can display ascii versions of the images...

ill try downloading perl to see what happeneds...

can i use it on my windows server? i have followed the instructions but i get no image, only the alt= (LaTeX Image)...

do i have to do something with my server to enable cgi usage? (i use apache)

i also tried to download the windows compiled .exe-file from
http://www.forkosh.com/mimetex.html

but i dont know what to do with it afterwards..

please help smile

35

(72 replies, posted in General discussion)

Ive made a blog for my page now.. self coded and not quite finished yet... but still.. check the "blog" link on the left menu below the image:
www.erikhome.info

36

(72 replies, posted in General discussion)

hehe cyberdiary.. without the locks on it.. EXCELLENT! big_smile

37

(72 replies, posted in General discussion)

Could someone explain to me... what do you need a blog for? Its just a simple page where you can post small texts containing anything you like or what?

Then hope for someone to find them interesting enough to read... smile

If that´s the case, then i actually have setup something similar on my page, without even knowing it =P I´ve got an admin system allowing me to create pages with different kinds of content, it also allows me to create "underpages" to the ones im doing... check here:
www.erikhome.info ... In the menu to the left right under the picture you have 2 links at the top.. one saying "mörk materia" and one sayng "jag".. both created with the system... (sorry my page is in swedish smile)

The "underpages" function is displayed if you check "mörk materie". You will find a new little menu appearing on top of the content containing related pages...

i wanted a link in every news item that said "edit" if you were logged in as admin so i included the following lines in externnews.php:

            If ($cur_user['status'] == PUN_ADMIN)
                $edit = '<td align="right"><a href='.$pun_root.'edit.php?id='.$cur_post['id'].'">Redigera nyheten</a></td>';
            else
                $edit = '';

then i made the script echo the $edit variable after every news-item, but it did not work.. i dont get the link to show... sad why!!! =P

39

(27 replies, posted in PunBB 1.2 troubleshooting)

nice smile

40

(27 replies, posted in PunBB 1.2 troubleshooting)

I coded around a bit and made a little mod smile
make a file called "style.php" put the code below in it and put it on your forum root.

<?php
If (isset($_POST['style_sent']) && $_POST['style_sent'] == 1)
    {
    $pun_root = './';
    include($pun_root.'include/common.php');
    $style = (isset($cur_user)) ? $cur_user['style'] : $pun_config['o_default_style'];
    echo '<link rel="stylesheet" type="text/css" href="'.$pun_root.'style/'.$style.'.css">';

    $id = $cur_user['id'];
    $db->query('UPDATE '.$db->prefix.'users SET    style=\''.addslashes($_POST['style']).'\' WHERE id='.$id) or error('Unable to update style', __FILE__, __LINE__, $db->error());
    redirect($pun_root.'hem.php', 'Sida redigerad, vänta...');
    }
?>

<tr>
    <td><br><b>Style</b>
        <form method="post" action="<?php echo $pun_root; ?>style.php"> 
            <input type="hidden" name="style_sent" value="1">
            <select name="style">
            <?php
            $d = dir($pun_root.'style');
            while (($entry = $d->read()) !== false)
                {
                if (substr($entry, strlen($entry)-4) == '.css')
                    $styles[] = substr($entry, 0, strlen($entry)-4);
                }
                $d->close();

            while (list(, $temp) = @each($styles))
                {
                if ($user['style'] == $temp)
                    echo "\t\t\t\t\t".'<option value="'.$temp.'" selected>'.str_replace('_', ' ', $temp).'</option>'."\n";
                else
                    echo "\t\t\t\t\t".'<option value="'.$temp.'">'.str_replace('_', ' ', $temp).'</option>'."\n";
                }    
            ?>
            </select>&nbsp&nbsp<input type="submit" value="Change">
        </form>
    </td>
</tr>

Then include it wherever you like on your forum using:

<?php include($pun_root.'style.php'); ?>

Most of the code is "borrowed" from profile.php...

41

(27 replies, posted in PunBB 1.2 troubleshooting)

check profile.php for the proper <form>-code that creates that option-box. Then put the code under the "else"-statement

42

(4 replies, posted in PunBB 1.2 troubleshooting)

Check this thread...
http://punbb.org/forums/viewtopic.php?pid=24045#24045

damn doesnt work for me.. i used jchristophm's script and the upload.php.. i just get "No file selected"... WHY! smile

44

(8 replies, posted in PunBB 1.2 discussion)

Thats my page smile i actually had some help from the good people here when i made it... look at this topic:

http://punbb.org/forums/viewtopic.php?id=4348

and check out the file extern.php for forum info output... and this topic for a good news system...

http://punbb.org/forums/viewtopic.php?id=3868

45

(8 replies, posted in PunBB 1.2 bug reports)

Perhaps you should build in some kind of protection against removing yourself as admin or banning/deleteing yourself.. i also accidentally made myself a user instead of admin in the beginning and had to change the DB... You would never really want to change your own status to something lower anyways.. so at least some kind of warning message would be nice... big_smile

46

(6 replies, posted in PunBB 1.2 show off)

i think that you actually can regain ALL of those features by adding mods.. check out www.punres.org

47

(16 replies, posted in General discussion)

there is software for mailserver included in windows... at least in 2000 and 2003 server and xp versions.. just check under ad/remove programs -> add/remove windows components

48

(133 replies, posted in General discussion)

middleground wrote:

But if all the "locals" stood up and helped the Iraqi people (who I don't think are doing the fighting now), then a message would be sent to the extremists. They only exist where permitted to exist. As I noted- no one will stand up and help anyone in that area. Compassionate people??

I dont think we should lay the responsability for making things right in iraq on the locals, since they did not create the situation. A people will never just all of a sudden stand up against someone else.. A good proof of that is the slavery that existed everywhere in the world for a long time without any slave standing up for the others... People are surpressed everywhere without doing anything about it - simply because they most often can´t. The locals are far to supressed by the US soldiers and the extremists to dare something like that.

Compassionate people??

...and they are not more or less compassionate than anyone else in the world. The situation in iraq could come to any other country, given the same circumstances from the beginning

I think we could, but if we use force, people bitch. And if we don't people bitch. And it is a mess, but as with most people on the subject- all the world can do now is focus on that and really don't give a damn about fixing it. After all it would just be the loss of another argument how nasty we are. Best for all the critice to sit back and watch it fail. I wouldn't want to be a neighbor when it does..

The americans has no good solution for the situation they created in Iraq, I agree on that. But since they havn´t - and probably hadn´t from the start - they should never have attacked.

you could blame all other countries for not coming and trying to help cleaning the mess in Iraq, but that still would not help the fact that America started something very unnecessary down there.

First- Japans ports were blocked, no fuel, no industrial capability. I don't think even if they did get madder it would make any difference.
Second- my guess is they didn't (again the context thing). For all most people knew- it was just another bigger bomb.

First: If they were so blocked and could do nothing - why then bother attacking them?
Second: I agree

Not the point- point is context to that time period. Guess that was missed.

whats the difference?

I didn't accuse you of being a natzi, I simply stated that you selectively pick out one instance of US action and repeat it as some type of validation of your beliefs. Without any reference to the context of that time. The fact others did it was not my point. One could probably go through history and selectively make a lot of countried look bad.

We are discussing the US right now so im focusing on the US.. Of cource other countries are just about as worse, but most industrialized countries are not - not nowadays anyway. And im not just picking out ONE instance of US actions - im picking out many.

Far as I know- never used any military force there. As I noted above- I believe the world created that situation 50 years ago, maybe the world should try to resolve it.

How about the fact that the whole idea to give away the country of palestina to the israelites was - at least partly - an american idea? Giving away a country that does not belong to you is not that very kind, is it?

Another fact is that USA supplies the israelites with weapons, thus supporting the continuation of the conflict and forcing the palestinians to give up their country. They are very desperate - the palestinians - all the suicide bombings are a very good example to that.

Not over yet- lets talk in 5 years smile

If it takes 5 years of war to bring the country right - was it really worth the sacrifice then?

49

(133 replies, posted in General discussion)

A nice speach, and a touching ending... Now for my comments:

middleground wrote:

I don't believe I'll ever make a point with you (or anyone else for that matter)...
I guess ruling with such brutality did keep the radicals in check, and have heard various comments that that is the only way to rule Iraq. But I don't really buy it. Perhaps the extremists were held in check, but so were the people. I think the problem there now is that no one wants a free Iraq (except perhaps the average Iraqi). Not one Arab leader has stepped up to say- "Those who don't want a free society, leave the country" or "Stop killing our fellow Arabs". But then again, why should they right... A free Arab society in the middle east is just to much of a threat to them, or they themselves are afraid of being overrun by terrorists.

I think you simplify the situation - Do you really think that the people in iraq would just unite and say "Hey, okej we stop fighting!" just because one arab leader told them to? Do you think the extremists would leave? i don´t think so...

Look- I believed, as I think many americans did, that when Saddam was gone, the people of that nation would standup and build a new country. I never thought every extremist on the continent would flood in and try to take over the country. I also never believed that a nation of proud people, or its arab neighbors, would stand for it.

again simplifying... Of cource someone will try to use the unstable situation created by the war. If America is to take away saddam, they HAVE to be able to maintain a stable situation after he is gone, or else they have just messed up the situation...

Do you have any understanding of WWII??
For one- the next step in the Pacific campaign was to invade mainland Japan. Due to the intensity of the campaigns leading up to this, all leaders knew it would be a bloody fight to the end. This would include massive (some estimates of million+) deaths amongst Japanese, Allied, and unfortunately Japanese civilians. At this point one has to think- millions+ or maybe just 100,000??
So- in the dropping of two bombs, the war in that arena was brought to an end, with overall lo ss of life a tenth on what it could have been.

First: How could america know that the bombs would not just make japan more angry?
Second: How could they know how many people would die compared to a traditional attack? The atomic bomb had never been used before... I´m pretty sure that they knew nothing or very little about the radiation that after the bomb would kill japanese people for over 50 years forward in time.


I don't agree with the way wars are fought, but you have to look at the context of the time period before you go making such remarks. You have to understand that ALL leaders repeatedly bombed population centers for the effectiveness in weakening a government. Germany was close to nuclear weapons and do you think they would have used it?? Hell yea... it is war. Which by comparison- at least 10 times the number of Jews were exterminated by Germany than were killed in the A-bombs- but have you ever spoken up against that?? (probably not) Or the slaughter of thousand by China as they swept through Asia?? (probably not) Or the 100000  people who died during the UK's firebombing of the city of Dresdan?? (probably not)

"Everyone else does it so we can do it to" is not a great argument.. it is a very bad argument actually...

at least 10 times the number of Jews were exterminated by Germany than were killed in the A-bombs- but have you ever spoken up against that?? (probably not)

I dont like being accused for being a nazist since i am no nazist and of cource i would speak against the treatment of the jews anytime and with the entire depth of my heart (oops got carried away smile) if that were the subject of the discussion...


Anyone, name a military situation in which the USA was involved that did not end in peace, with interested parties in better condiition than before we got involved.

Israen/palestina?, Iraq?, Vieatnam?, Cuba?

50

(133 replies, posted in General discussion)

middleground wrote:

Iraq- Oh yeah, and who is killing who know. All I see is the Arab brothers fighting like dogs with each other and trying their best to make any success there not possible. The "war" to remove Saddam was over last spring, this my friend is a fight against extremists fighting the infidels (and each other). You see... please I already spoke my mind on that.

The reason for the chaos in that country is the war to put away saddam I believe... so you dont make much of a point to me... Before USA entered i think the situation was more stable in iraq, dont you agree?

About japan I think that killing a hundred thousand civilians instead of fighting the japanese army is not quite fair... I know that the japanese attacked first and america was right to defend themselves, they just did it in the wrong way...

About vietnam: I dont think the US entry made the situation very much better... The americans had to give up anyway, eventually. Or am I wrong on that?