Jump to content

Samuz

Members
  • Posts

    80
  • Joined

  • Last visited

Everything posted by Samuz

  1. Hi guys, i'm trying to increment a variable / session value whenever 'submit' comes in the POST. I can't seem to get around the logic of this. Code looks like this: $var = 0 if($_POST('submit'){ $_SESSION['var2'] = $var++; } What I want it to do is increment the value of the session index everytime a user clicks 'submit'. But because i've reset $var to 0 everytime, it's always just going to stay at 1. I just can't think of a way to achieve this, does anyone have any clue on how I can?
  2. So I have a specific part of my forums that I want to limit view to a specific group(s). Here's the forum for view: http://www.iron-command.com/forum/index.php I'm trying to hide the list item where that Blue image is contained within or limit it's view to designated user groups. I know how to edit the template and where to find that specific list item. I'm not sure how difficult this would be, but i'm assuming a little if statement will do the job. Something along the lines of.. Does anyone know if this will work? And if so, what the correct code will look like? I know this question should most likely be answered on the IPB customer forums or something, but thought i'd try my luck here first.
  3. The point was to start by communicating in a more professional manner. Although he did state he wasn't fluent in English..
  4. So basically I have a database full of players 'items'. Each player has 2 items. and I need to make a circle with these players with only specific items involved. Each circle can only contain 6 players. The items needed to create this circle are: pigs spice sugar cows aluminium marble iron lumber wheat water random random so 10 resources are literally needed to create this circle but 12 is needed to make it a 'circle' if you get me. I'd like to note that it is possible that any of these players can have a combination of any of resources listed above. I've created a form that allows people to submit players resources into my mysql database. I heard it was possible that I could code some type of filter/sort code to sort out the players resources from my database automatically into a set that will match what is needed (without any repeat of resources) and having a php code to export it into html format for viewing pleasures. I really have no idea how to go about this in mysql or php. But if somebody could help me out i'd be ever so glad. Also to note: this isn't school work or something. It's from a game I play and i'm just trying to make my job in it easier. I was thinking of maybe a php code that will run through all the possible partners in order to create this set like run through 100s of different sets until the required set is obtained. I heard this is just about possible. Can anyone help me? Looking forward to all the great help around here. Thanks Samuz PS: Each item/resource can only appear once in each circle.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.