Show Needed | v1.1 | etcgfm v1.0.1 | up 5.17.14

  1. ‹ Older
  2. 5 years ago

    If I remember correctly, the quotes are needed to ensure what the string is (as strings can have commas, so it wouldn't know where to begin and end).
    The fact that it doesn't have any decks or anything means it's probably not grabbing the category (which it probably wouldn't with this error), so that should fix it. If it doesn't, let me know, and I'll make sure I didn't mis-copy something in the code.

  3. Edited to overwrite

    I feel so stupid right now as i have just realised instead of putting the category name in which is 'keepingnext' i inputted in the name i gave the name i orriginally had for the page those decks are on.

    sorry for wasting your time looking at this, I can only assume that as i call each collecting deck up to get my layout as is then this affects those decks showing up or that it's not possible to show these decks.

    Thanks to all of you for looking at this for me, i just can't believe it was a stupid mistake.

    <?php } elseif ($_SERVER['QUERY_STRING'] == "collecting") { ?>
    
    <?php define('VALID_INC', TRUE); include 'func.php';
    include('header.php'); ?>
    
    <p><center><h1>Chemistry</h1> <br><b>  
    <a href="http://randomflowers.co.uk/chemistry.php">Main</a> .. 
    <a href="http://randomflowers.co.uk/chemistry.php?collecting">Collecting</a> ..  <a href="http://randomflowers.co.uk/chemistry.php?future">Future Collecting</a> ..
    <a href="http://randomflowers.co.uk/chemistry.php?keeping">Keeping</a> .. 
    <a href="http://randomflowers.co.uk/chemistry.php?mc">Member Cards</a> .. 
    <a href="http://randomflowers.co.uk/chemistry.php?soulmate">Soulmates</a> .. 
    <a href="http://randomflowers.co.uk/chemistry.php?trading">Trading & Doubles</a> .. 
    <a href="http://randomflowers.co.uk/chemistry.php?pending">Pending</a> .. 
    <a href="http://randomflowers.co.uk/chemistry.php?mastered">Mastered</a> .. </center></b>
    
    <p>
    
    <a name="collecting"><h1>Collecting</a></h1></a>
    <center>
    
    <table>
    <tr>
    <td valign="top"><?php show_collecting('chemistry','','anas-dimitrianya'); ?></td>
    <td valign="top"><?php show_collecting('chemistry','','angel-gunnfred'); ?></td>
    <td valign="top"><?php show_collecting('chemistry','','batb-lumierecogsworth'); ?></td>
    </tr>
    
    <tr>
    <td valign="top"><?php show_collecting('chemistry','','bbt-pennyamy'); ?></td>
    <td valign="top"><?php show_collecting('chemistry','','gg-lukelorelai'); ?></td>
    <td valign="top"><?php show_collecting('chemistry','','ggirl-danserena'); ?></td>
    </tr>
    
    <tr>
    <td valign="top"><?php show_collecting('chemistry','','herc-herculesmeg'); ?></td>
    <td valign="top"><?php show_collecting('chemistry','','poto-phantomchristine'); ?></td>
    <td valign="top"><?php show_collecting('chemistry','','sat-zacklaney'); ?></td>
    </tr>
    
    <tr>
    <td valign="top"><?php show_collecting('chemistry','','woo-dorothytoto'); ?></td>
    <td valign="top"><?php show_collecting('chemistry','','sd-rebekah'); ?></td>
    </tr>
    </table>
    
    </center>
    <?php include('footer.php'); ?>
  4. "Rebekah" I feel so stupid right now as i have just realised instead of putting the category name in which is 'keepingnext' i inputted in the name i gave the name i orriginally had for the page those decks are on.

    sorry for wasting your time looking at this, I can only assume that as i call each collecting deck up to get my layout as is then this affects those decks showing up or that it's not possible to show these decks.

    I might be misunderstanding this, but do you mean the collecting decks not showing up in the show_needed list?
    If so, it's because it pulls a category, and there's no "Collecting" category. The code was made mainly for keeping decks. If you'd like to be able to see which cards you need for your collecting deck without accidentally putting the wrong number, I can tell you how to add the title to the filler cards in your collecting deck (so that when you hover over a filler, it tells you that missing card).

  5. thanks for the help and explanation Dite, i think its me misunderstanding the mod, its fine though i don't need to show those for the collecting decks now :) thanks for spending the time to look at this though.

  6. Just a note to let everyone know I took some time and added everything I planned to, as well as making it usable for Collecting decks.

  7. 4 years ago

    Maybe I'm missing it, but I can't seem to find the pending function any where. Is it not available anymore? I have the previous version of this mod working, but I can't get this version working because I don't have that function.

  8. @Drakmin Maybe I'm missing it, but I can't seem to find the pending function any where. Is it not available anymore? I have the previous version of this mod working, but I can't get this version working because I don't have that function.

    I've been looking for this as well but can't seem to find it anywhere.

  9. Hi Dite, really looking forward to using this mod but I'm coming up with an error: "Fatal error: Call to undefined function pending() in /home/carbonb/public_html/flashlight/func.php on line 469"

    line 469: $pending = pending($tcg, $check.$might);
    page I'm trying to use it on: link
    code on page: <?php show_needed( 'Small Screen', 'collecting', 20, $pend=0, $low=0); ?>
    and attached is my func.php

    let me know if you need to see any of my other code

  10. It's because this version of the show_needed function requires another function called pending. The pending function is not included in this one. It's completely separate from the show_needed function. A few of us are looking around to find it. If I find it before there's a reply, I'll let you guys know where it is.

  11. Oooooh okay I see, thanks.

  12. Crap. Sorry guys. I've been forgetting to check this.

    And, I didn't realize I didn't have a pending function (sometimes, when I have a function for a while, I use it and don't think about it. XP)
    Add this function before it and see if it works:

    function pending($tcg, $card){
    	$database = new Database;
    	$sanitize = new Sanitize;
    	$tcg = $sanitize->for_db($tcg);
    	
    	$tcginfo = $database->get_assoc("SELECT * FROM `tcgs` WHERE `name`='$tcg' LIMIT 1");
    	$tcgid = $tcginfo['id'];
    	$pending = $database->num_rows("SELECT * FROM `trades` WHERE `tcg`='$tcgid' AND `receiving` LIKE '%$card%'");
    	return $pending;
    }
  13. Okay so I added that snippet, and I'm still getting an error, this time "Fatal error: Call to undefined function get_category() in /home/carbonb/public_html/flashlight/func.php on line 450"
    Attaching my func.php again in case it's needed

  14. That mod is here .
    It's a mod I've started using a lot (it's a function to get the list of cards in a category, so it cuts down on the coding of other mods, especially if I need to grab multiple categories.

  15. Alright so it's working great for my keeping category, but I'm getting ": 01/02/03/05/07/08/09/10/11/12/13/14/15/16/17/18/19/20" for my collecting.

  16. I'll get that fixed soon. After noticing some of my older mod coding isn't as good as it is now (and not all of it is updated for the new version), I'm going to revamp some of my mods.

  17. Edited 4 years ago by Danielle

    Sounds good! Keep me updated :D

  18. @Danielle Alright so it's working great for my keeping category, but I'm getting ": 01/02/03/05/07/08/09/10/11/12/13/14/15/16/17/18/19/20" for my collecting.

    You are using the worth for the count, right?

    The only issue I have is that it still shows the deck name once you have all the cards for it...but I can live with it since it reminds me that I need to move it to the mastered section.

  19. @Cami You are using the worth for the count, right?

    The only issue I have is that it still shows the deck name once you have all the cards for it...but I can live with it since it reminds me that I need to move it to the mastered section.

    Pfffffft I totally know how to read....
    But actually that was it and I never re-read the execution of the function until now.
    Thanks a million!

  20. 10 months ago

    I know this is old, but my new host is forcing me to use 1.1.0 and I was wondering if the reason I can't get this to work is because of that, and if so, is there a way for me to get it to work with 1.1.0. I don't really know php well enough to try and fix this on my own (though I understand the idea enough to tweak code), if the version is the issue.

    I honestly need this to function and can't imagine being a good lil trade bot without it haha.

  21. @Kriss I know this is old, but my new host is forcing me to use 1.1.0 and I was wondering if the reason I can't get this to work is because of that, and if so, is there a way for me to get it to work with 1.1.0. I don't really know php well enough to try and fix this on my own (though I understand the idea enough to tweak code), if the version is the issue.

    I honestly need this to function and can't imagine being a good lil trade bot without it haha.

    It shouldn't be an issue with the version as it's working fine on my own post.

or Sign Up to reply!