quaker wrote:

sound like he has added his extra code out side of that div or table
so it will produce it next to it instead below it..

check where your menu ends and where the profile menu ends..

why not just add it to the profile menu when u click on military control it produces the right menu in the block

Q

I don't quite understand you, but yes I looked at my code and fixed it, so its all good now

Smartys wrote:

The left nav bar is entirely HTML from what I see there, what would be doing that?

I don't know, but heres some pics

WITH LEFT BAR
http://i100.photobucket.com/albums/m12/arthurvandelay_2006/with.jpg

WITHOUT LEFT BAR
http://i100.photobucket.com/albums/m12/arthurvandelay_2006/without.jpg

http://wiki.punres.org/Miniportal#Step_ … e_main.tpl

I have found what is making it do that, it is when I add in a left nav bar into my tpl, which I got from the wiki tutorial,  Can I edit it so the left nav bar doest show for the profile.php page? like copy and rename the tpl, and use that one when the page is profile.php?

Ill re upload a clean copy of it, can't remember if I had edited it at all, then all say if it still happens
-edit I went and re downloaded punbb, uploaded profile.php and it still does it, would any other files be affecting it?

6

(0 replies, posted in Programming)

has anybody read this tutorial on making a minimap with php and gd, I have tried it out and cant get a result
http://www.static-chaos.net/viewtutoria … _-_Minimap

well for some reason all my profiles what ever your login name is what shows up for all the fields, heres some sceenys
http://i100.photobucket.com/albums/m12/arthurvandelay_2006/3.png
http://i100.photobucket.com/albums/m12/arthurvandelay_2006/2.png
http://i100.photobucket.com/albums/m12/arthurvandelay_2006/1.png
and if you change it, such as changing your signature it will change when you view it in viewtopic.php but not in your profile

8

(9 replies, posted in Programming)

I was justing making a game, and making a page for updating your stuff and buying troops, just wanted to use punbb framework for it

9

(9 replies, posted in Programming)

MattF wrote:

That script above is only part of an overall setup. As it is above, it wouldn't work within PunBB as is.

ok, I have been searching a lot, what do I have to add, the actual connection part or is that defined in a page already?

10

(9 replies, posted in Programming)

I tried this but I just keeping getting error, unable to fetch user data...

I finally got a right side nav working, but for the view topic theirs a huge space, here you can see what I mean
http://wartime-time.freehostia.com/viewforum.php?id=1

-edit heres my main.tpl

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html dir="<pun_content_direction>">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=<pun_char_encoding>" />
<pun_head>
<style type="text/css">

#left     {float:left; width: 160px;}

#right     {float:right; width:160px;}

#main {margin-left:170px; margin-right:170px;}

</style>
</head>
<body>

<div id="punwrap">
<div id="pun<pun_page>" class="pun">

<div id="brdheader" class="block">
    <div id=brdbox class="box">
        <div id="brdtitle" class="inbox">
            <pun_title>
            <pun_desc>
        </div>
        <pun_navlinks>
        <pun_status>
    </div>
</div>

<div id=left>

    <div class="block">
        <h2 class="block2"><span>More Links</span></h2>
        <div class="box">
            <div class="inbox">
                <ul>
                    <li><a href="index.php">Link 1</a></li>
                    <li><a href="index.php">Link 2</a></li>
                    <li><a href="index.php">Link 3</a></li>
                    <li><a href="index.php">Link 4</a></li>
                </ul>        
            </div>
        </div>
    </div>


</div>

<div id=right>

    <div class="block">
        <h2 class="block2"><span>More Links</span></h2>
        <div class="box">
            <div class="inbox">
                <ul>
                    <li><a href="index.php">Link 1</a></li>
                    <li><a href="index.php">Link 2</a></li>
                    <li><a href="index.php">Link 3</a></li>
                    <li><a href="index.php">Link 4</a></li>
                </ul>        
            </div>
        </div>
    </div>


</div>

<div id=main>
    <pun_announcement>
    <pun_main>
</div>
<pun_footer>


</div>
</div>
Smartys wrote:

Try this:

//START CUSTOM INSERT
$strSQL = 'INSERT INTO '.$db->prefix.'Cities (username, cityname, leader) VALUES("'.$db->escape($username).'", "'.$db->escape($cityname).'", "'.$db->escape($leader).'")';
$db->query($strSQL ) or error('Unable to add games ('.$strSQL.')', __FILE__, __LINE__, $db->error());
//END CUSTOM INSERT

That should fix several issues with your code.

oh man how can I thank you any more smile , I so was so confused with the '\' in all the $db escape stuff

Smartys wrote:

You'll need to provide actual code or we can't help you wink

ok, now I can tell if I am close or way off

//START CUSTOM INSERT
$strSQL = ' INSERT INTO '.$db->prefix.'Cities (username, cityname, leader) VALUES(\''.$db->escape($username).'\', \''.$db->escape($cityname).'\, \''.$db->escape($leader).'\'')
    $db->query($strSQL ) or error('Unable to add games ('.$strSQL.')', __FILE__, __LINE__, $db->error());
//END CUSTOM INSERT

ive had really hosting with ecwhost.com , based out of england, really cheap too like 2 pounds a month or around 4$

15

(11 replies, posted in PunBB 1.2 troubleshooting)

my guess is that it was a 1 time thing

16

(11 replies, posted in PunBB 1.2 troubleshooting)

yeah it just sat there saying it was redirecting but did nothing

17

(11 replies, posted in PunBB 1.2 troubleshooting)

I am not sure, i tried going into my admin control panel and changing it, and I tried it left for a bit came back and it still sat there doing nothing

18

(11 replies, posted in PunBB 1.2 troubleshooting)

I tried the new mega pun 2 days ago from here and the redirection didnt work, so I just scrapped it and went back to my old settings

arg I suck at trying to get the bd string escape to work, I am not quite sure how to fit it in for the query

//START CUSTOM INSERT
    $strSQL = ' INSERT INTO '.$db->prefix.'**TABLE*** (**CAT***, **CAT***) VALUES(**VALUE***, **VALUE***);';
    $db->query($strSQL ) or error('Unable to add games ('.$strSQL.')', __FILE__, __LINE__, $db->error());
//END CUSTOM INSERT

for the value, I can get the first one in for username, and I try to add the next value and bam! I get errors

ok thank, yeah ill just create a seperate query

matt1298 wrote:

it will work if you have done the correct SELECT code..

so you are saying just create my own select quary for that table?

matt1298 wrote:

that will get the id of the current user.. or what ever is in the [''].. that what you mean?

well I have a table called buildings, and I want to be able to put in

$pun_user['b.buildingname']

so I can  use the different fields of that table
edit- do you see what I am trying to get at?

yes that worked, another quick question does any1 know where I would find where all the user sessions are stored like

$pun_user['g.id']

is found so I can add in new ones for my table

matt1298 wrote:

open register.php and:

after line 200 =

    // Add the user
    $db->query('INSERT INTO '.$db->prefix.'users (username, group_id, password, email, email_setting, save_pass, timezone, language, style, registered, registration_ip, last_visit) VALUES(\''.$db->escape($username).'\', '.$intial_group_id.', \''.$password_hash.'\', \''.$email1.'\', '.$email_setting.', '.$save_pass.', '.$timezone.' , \''.$db->escape($language).'\', \''.$pun_config['o_default_style'].'\', '.$now.', \''.get_remote_address().'\', '.$now.')') or error('Unable to create user', __FILE__, __LINE__, $db->error());
    $new_uid = $db->insert_id();

add

//START CUSTOM INSERT
    $strSQL = ' INSERT INTO '.$db->prefix.'**TABLE*** (**CAT***, **CAT***) VALUES(**VALUE***, **VALUE***);';
    $db->query($strSQL ) or error('Unable to add games ('.$strSQL.')', __FILE__, __LINE__, $db->error());
//END CUSTOM INSERT

and just edit the query to your needs

thank, that what I was looking for

anybody? I still can't edit the registration code to insert another db query to insert values into another field